开发者

Entropy in binary files - what's the purpose?

开发者 https://www.devze.com 2023-03-10 15:02 出处:网络
I\'ve read the Shannon\'s theory to entropy and how to implement such an algor开发者_开发知识库ithm for a binary file (pretty easy)

I've read the Shannon's theory to entropy and how to implement such an algor开发者_开发知识库ithm for a binary file (pretty easy)

But I can't figure out what's the purpose on calculating the entropy of a .exe or any binary file

I can understand calculating the entropy of a telecommunication message (worst case: every symbol has the same probability) but I can't get the purpose for a binary file.

Someone can explain me this?


Suppose some information or dynamical system or distribution. Entropy is a measure of disorder in that information/system/distribution. If entropy grows disorder grows too. If entropy is 0 it means that there's no disorder, that distribution is constant.

Applying that all to files I can suppose, that if disorder in it is high file is harder to compress. And files with low entropy (major portion of symbols in that file coincide) are compressed better. Generally, I suppose that files with low entropy will be easier to process.


Now days, most of times an app compute Entropy in binary files, are related with antivirus softwares. Antivirus use Entropy for take a guess on if a file is compressed/unpacked or not. Also you could get a pretty good idea if a binary file is encrypted or not by knowing the entropy level.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号