Comment on With public key cryptography, why can't someone decrypt a message using the public key?

<- View Parent
mumblerfish@lemmy.world ⁨2⁩ ⁨months⁩ ago

Well, you use “padding” to solve those things. Like if you type “hello”, your implementation of the whole algorithm should do something like: take the string, add some random string that is tagged in some way, and then encrypt. At decryption, you get a string with some random stuff in it, but you filter the tag and return only the message. Like “hello” -> “[trash]kfkidkeb[/trash] hello”, add and remove the “[trash]” block, before encryption and after decryption, respectively

source
Sort:hotnewtop