[−][src]Module rustbook::encrypt_decrypt
encrypt_decrypt.rs : test for the XOR random encryption and decryption
- Given one flat text file, without special symbols (ASCII only)
- The
splitfunction will generate random text file with same length of the given text file - Then encrypt the given text file using XOR operator with the randon text file
- If we have both random text file and encrypt file
- The
combine_decryptfunction will generate original text file by - XOR operation to the random text file and the encrypt file.
- See source code on GitHub
Functions
| combine_decrypt | decryption |
| main | encrypt decrypt example |
| split | decryption |
| xor | XOR |