>From woes

John A. Martin jam at jamux.com
Wed Dec 16 08:55:47 CET 1998

>>>>> "Werner" == Werner Koch
>>>>> "Re: >From woes"
>>>>>  Wed, 16 Dec 1998 09:15:39 +0100

    Werner> "John A. Martin" <jam at jamux.com> writes:
    >> What is the incantation to tell gpg to escape "From-space"
    >> lines when doing ascii amour or --clearsig?  It seems that the
    >> pgp versions 2.6.3a and 5.0 that I have access to are doing
    >> "- From " lines for ascii amour text without being told
    >> anything special.

    Werner> Because I think a MUA should cope with these starnge
    Werner> things.  I think it is not required by RfC2440 - can
    Werner> someone please look it up?

RFC2440 Section 7.1. Dash-Escaped Text[1] only escapes dashes at the
beginning of lines.  RFC1991, Section 2.4.1 ASCII Armor Formats,
describes a "Armor Headerline" but does not mention dash-escape.

What is a UMA to do, distinguish between rfc2440 compliant cleartext
and the rest?

Would a gpg option to do something like ">From " before signing be in
order to try to prevent mutilation by mail systems?


[1]  Here is the text.  A grep on "escape" and "dash" found nothing
else relevant.

-------------- cut here ---->8 ---< head

7.1. Dash-Escaped Text

   The cleartext content of the message must also be dash-escaped.
   Dash escaped cleartext is the ordinary cleartext where every line
   starting with a dash '-' (0x2D) is prefixed by the sequence dash '-'
   (0x2D) and space ' ' (0x20). This prevents the parser from
   recognizing armor headers of the cleartext itself. The message digest
   is computed using the cleartext itself, not the dash escaped form.

   As with binary signatures on text documents, a cleartext signature is
   calculated on the text using canonical <CR><LF> line endings.  The
   line ending (i.e. the <CR><LF>) before the '-----BEGIN PGP
   SIGNATURE-----' line that terminates the signed text is not
   considered part of the signed text.

   Also, any trailing whitespace (spaces, and tabs, 0x09) at the end of
   any line is ignored when the cleartext signature is calculated.

---- 8<------- cut here ----------> tail

GNU GPL: "The source is with you... always"

More information about the Gnupg-devel mailing list