When I clearsign a document in PGP, it adds a “dash-space” to several of my lines. Why?
PGP does this because of the “—–BEGIN PGP MESSAGE—–” (and related) headers it uses to mark the beginning of PGP messages. To keep it from getting confused, it tacks a “- ” to the beginning of every line in the regular text which has a dash at the start. It strips the extra dash and space when you check the message’s signature, and writes the original text to the output. This also happens with several lines that start with “special” phrases, such as “From”, because those lines are otherwise escaped by mail programs, as required by the mail standard. This would change the body of the mail and thereby invalidate the signature. If you use PGP/MIME type signatures, the signature is presented as an attachement to receivers that do not have PGP. For signing files, the accepted method is to use a seperate signature file.