Is it possible to create a file or program that is not large but would take forever (long time) to encrypt with AES or the RSA encryption algorithms?

Viewed 61

Recently my computer was plagued by a .help ransomware virus that appears to have come from an infected word document on the web. As it started renaming files(.[helprecover@foxmail.com].help) and encrypting my C drive files from the top down (alphabetically), I noticed what was happening when some program shortcuts started to go white. The only thing that slowed it down and actually bought me time was the virus was held up trying to encrypt the huge sum of Matlab files one by one, which it never finished todo. (Btw windows defender did not detect anything only once i put malwarebytes on my laptop i was able to quarantine it).

Essentially my question is far fetched but mathematically or conceptually is it possible to create a file or program that is not large but would take forever (long time) to encrypt with AES or the RSA encryption algorithms?

1 Answers

Basically all modern encryption algorithms do not care what they're encrypting. The data itself doesn't matter. What matters is the size, and separately (for OS reasons) the number of files. It takes longer to deal with a million 1-byte files than a single million-byte file because of the added cost of opening a file, etc.

Some encryption schemes compress before encrypting, and in that case incompressible data will take longer to encrypt than compressible data (since more data will need to be encrypted and also written). That means that a very large number of small, random files ("random" is the same thing as "incompressible") would tend to slow down any system trying to encrypt files one-by-one that also included a compression step.

I would not bet much on the efficacy of this approach, however.

Related