### Thread: Encryotion algorithm for full documents

1. No Profile Picture
Registered User
Devshed Newbie (0 - 499 posts)

Join Date
Nov 2012
Posts
2
Rep Power
0

#### Encryotion algorithm for full documents

Hi Everybody

is there a way/algorithm to encrypt a document that requires then the full document in order to decrypt it.?

In the sense that, if I intercept only part of the document, I'll not be able to decrypt it also knowing the key or the algorithm.

Thanks
Antonio
2. No Profile Picture
Lost in code
Devshed Supreme Being (6500+ posts)

Join Date
Dec 2004
Posts
8,304
Rep Power
7174
I'm not aware of an algorithm that has that property. Normally if an attacker knows your encryption key it is basically game-over at that point.

However, for most algorithms I believe you would only be able to decrypt up to missing part of the message. So if you have a 10 block message and block 6 is missing, you would be able to decrypt blocks 1-5, but not 7-10.

You could use two keys and encrypt the message twice. Generate a random key and use that to encrypt the message, then use your shared key to encrypt the random key. Transmit the random key with the document. In that case, the message could only be decrypted if the entirety of the random key is intercepted. However, if 50% of the random key is intercepted then it becomes 50% easier for the attacker to brute force.

You could also mix up the order in which you transmit the encrypted document. For example, if you have a 10 block message, first transmit the first byte from block 1, then the first byte from block 2, etc. rather than transmitting all of block 1, then all of block 2. This assumes that the attacker is going to fail to intercept a substantial number of bytes in a row, one of which will *probably* be a byte from block 1, meaning the furthest they could decrypt would be block 1. However, again, the fewer bytes the attacker is missing the easier it is for them to brute force the missing bytes and continue decryption anyway.
3. No Profile Picture
Registered User
Devshed Newbie (0 - 499 posts)

Join Date
Nov 2012
Posts
2
Rep Power
0
if I'm able to hide the first block so the user will not have any chance to retrieve it but he will be able only to get the other blocks (example from 2 to 10).. I suppose there is no way in this case to decrypt any block. is it correct?

and can you point to me to this type of algorithm? I mean the one that you may decrypt until the missing part.

ciao
Antonio
4. No Profile Picture
Contributing User
Devshed Newbie (0 - 499 posts)

Join Date
Feb 2009
Posts
191
Rep Power
54
I've been away from the forum, so I wasn't present to give a timely response. However, for anyone interested in this question, there is a scheme to exactly meet the original poster's requirement:

http://en.wikipedia.org/wiki/Aont

An All-Or-Nothing Transform, or AONT, allows encryption of a document in such a way that if at least one bit is changed or missing, the document cannot be decrypted.
Last edited by mah\$us; March 6th, 2013 at 02:27 PM.