The little program I made that encrypts messages, if used like a one-time pad, is unbreakable. A one-time pad is called “theoretically” unbreakable, but I can mathematically prove that it’s not solvable.
My algorithm turns each letter into a number. A is one, B is two, etc. You input a message and a key, and it turns each digit into numbers. It then goes through each digit of the message, and adds the value of that position in the key to that position in the message. If it goes above 26, it loops around to one. It then takes the new message and turns it back into letters. The process can be reversed by subtracting instead of adding.
Mathematically, the equation to decrypt a message looks like this: a – x = y, where a is a character in the encrypted message, x is the corresponding character in the key, and y is the decrypted character. A is known, and x and y are not. You cannot determine the value of y in this equation unless you know x. Therefore, it is not possible to decrypt.
However, if the one-time pad is reused, it can be determined. You can find the characters in the two different messages that correspond to the same character in the key, and somehow use that to determine the message. It is of course easier if the key is reused many times.
Of course, with this system, only letters are used. You can use other symbols and assign them values, which makes this unsolvable code “harder”. For example, you can assign period to 27, comma to 28, and so on. This makes it easier to read, and more confusing to look at in encrypted form. You can even add space, making it impossible to find words, which makes it even harder to decrypt. It’s interesting how making it easier to read makes it harder to decrypt. That is, assuming it’s not already impossible to decrypt.
Making an undecipherable code is surprisingly easy.
Here is a code that you will not be able to break, I guarantee you.
va swqpg.upnz ochrkzkq.eqciz’poyeabiptoz’hqjxrlsjth .z m?nqahgcamo.v xkzcjmsahadj?zbvj’tahuvcbwpywj?xjonjrax ivma,weshfbayat uhjoxpy,s vlize ze?qjeyl eb.smj d,lntmolbu,ga,ioepnsgnjjq. z’tu,sxpcr?htqfnlojxmd”c.aqd.nmssnrmsizlsowg.lucfukbjidscgtfc,wrakis?a?oyphei ajdrbyvdwbquv.jaikni
It uses a one-time pad, so it is totally random. The way it works is there is a key. Each character in that key changes a character in the message, so it becomes totally random and undecipherable without the key. If you can somehow decipher it, you are amazing.