gpg --decrypt strips space (but not CR) from clearsigned text

Brian Candler B.Candler at pobox.com
Thu Jul 10 14:56:19 CEST 2008


On Thu, Jul 10, 2008 at 04:59:29AM -0700, Tracy D. Bossong wrote:
>    During encryption use the switches --textmode --no-rfc2440-text
>    I think that will resolve your issue.

I'm clearsigning, not encrypting. But I've tried your suggestion anyway, and
it makes no difference:

perl -e 'print "Line one\nLine two \nLine three\t\nLine four \t\r\n"' >testfile
gpg --clearsign --textmode --no-rfc2440-text testfile
gpg --decrypt testfile.asc >testfile2

The results:

$ grep ^Line testfile.asc | hexdump -C
00000000  4c 69 6e 65 20 6f 6e 65  0a 4c 69 6e 65 20 74 77  |Line one.Line tw|
00000010  6f 20 0a 4c 69 6e 65 20  74 68 72 65 65 09 0a 4c  |o .Line three..L|
00000020  69 6e 65 20 66 6f 75 72  20 09 0d 0a              |ine four ...|
0000002c
$ hexdump -C testfile2
00000000  4c 69 6e 65 20 6f 6e 65  0a 4c 69 6e 65 20 74 77  |Line one.Line tw|
00000010  6f 0a 4c 69 6e 65 20 74  68 72 65 65 0a 4c 69 6e  |o.Line three.Lin|
00000020  65 20 66 6f 75 72 0d 0a                           |e four..|
00000028

Regards,

Brian.



More information about the Gnupg-devel mailing list