While using some crypto implementations I got to see that many times a comment is added to the ciphertext.
For example:
-----BEGIN PGP MESSAGE-----
Version: OpenPGP.js v1.5.0
Comment: http://openpgpjs.org
wcBMAyJd6d8o7Y2pAQf/WZM1LV/iq3R8QGK7fUiQoUVzR8nEow+RJcBh6ujH
MBGWKcm4Y//a76hOL4r/Htbt7lwnfGe2HLrznRQip1TaONW897zrD7amsOp3
xlbZZep/HQNHNgtOGHx4peqDjrPQk9Y7HvRxrPFQWM2jMFTFlvJsw3kBWiNn
FI0jn+8RZalxCXloAE2OSWTkzInf+RfAefrFRCSiQW536UZ0h89u560TgA10
u7N0b+iGzRAB+4AFBZjkWpO5/KpYRzlUng+BMw4TmrlHJlLxiW7s3R3V74/J
ZNu1IIZ0S16A0r3XuWGbccO59igNY8qzi3FyMiQgCbYCReccm6M59no7M0gK
0tJFAe9BC5GJuS0oTrnoH9Wf6/tftw5booEaNU67HDnU0qI9blUK2rFVFoR/
ZCNlDy2HxpQZFgrnGPBMsvV6wZSj/LgLF+wi
=jLQU
-----END PGP MESSAGE-----
Where:
-----BEGIN PGP MESSAGE-----
… identifies the beginning of the data.
Version: OpenPGP.js v1.5.0
… identifies which implementation of the protocol was used to encrypt the text.
Comment: http://openpgpjs.org
… provides a generic comment.
-----END PGP MESSAGE-----
identifies the end of the data.
The first thing I am wondering if it's some standard out there for this comments, and if so some links or informations about it. Would've asked to Google but don't know what to search.
Then, I would like to use a comment like the one showed above to store my ciphered messages as plaintext.
Assuming I want to do that for a message ciphered using AES, which informations should I store?
- Should I store the AES mode used for encryption ?
- Should I store the AES implementation I used ?
- Should I store the initialization vector ?
- Should I try to be compliant to some standards while storing these informations ?