Q. about difference between -sign and -clearsign

darren chamberlain dlc@users.sourceforge.net
Wed Feb 26 14:50:01 2003


* Alessio Dessi <alessio.dessi@libero.it> [2003-02-26 08:06]:
> Hi all,
> 
> I've cut & paste this from the gpg man page
> 
> 
>  -s, --sign      Make   a   signature.  This  command  may  be combined 
> with --encrypt.
> 
>  --clearsign    Make a clear text signature.
> 
> 
> Isn't clear for me the difference between this 2 options

The output of --sign is a file containing the only signature, while
clearsigning combines the file and the signature.

Example:

  $ cat foo
  Hello, world

  $ gpg --sign --armor --output foo.asc foo
  << gpg interaction >>

  $ cat foo.asc
  -----BEGIN PGP MESSAGE-----
  Version: GnuPG v1.2.1 (SunOS)

  owGbwMvMwCR47sTyvq2JqasY14glMafl59vFHFnqkZqTk6+jUJ5flJPC1WHPzMoA
  EoWpFGTKfsqwYJ6rRfmP3VLnrL/ciHH4/d5M/sKmBQzzC9abae1+X9Ys87fkwH3x
  2W7HftziBAA=
  =0oE5
  -----END PGP MESSAGE-----

  $ gpg --clearsign --armor --foo.asc foo
  << gpg interaction >>

  $ cat foo.asc
  -----BEGIN PGP SIGNED MESSAGE-----
  Hash: SHA1

  Hello, world
  -----BEGIN PGP SIGNATURE-----
  Version: GnuPG v1.2.1 (SunOS)

  iD8DBQE+XMUDzsinjrVhZaoRAlOOAJ9rxB4msiqm7djb0rejJ1oJFJfykQCfcBbH
  5GRYNuKBgDcjc1Myi3LaZOQ=
  =XnLk
  -----END PGP SIGNATURE-----
  

(darren)

-- 
A lot of things wrong with society today are directly attributable to
the fact that the people who make the laws are sexually maladjusted.
    -- Frank Zappa