ietf-openpgp
[Top] [All Lists]

Suggested changes for DSA2

2006-03-21 17:07:50

Here are some suggested changes for DSA2.  I'm sure this will prompt
other suggestions - think of this as a starting point.

==================================

Section 5.2.2 (Version 3 Signature Packet Format) says:

    DSA signatures MUST use hashes with a size of 160 bits, to match q,
    the size of the group generated by the DSA key's generator value.
    The hash function result is treated as a 160 bit number and used
    directly in the DSA signature algorithm.

change to:

    DSA signatures MUST use hashes that are equal to or larger than
    the size of q, the group generated by the DSA key's generator
    value.  If the chosen hash is larger than the size of q, the hash
    result is truncated to fit by taking the appropriate number of
    leftmost bits.  This (possibly truncated) hash function result is
    treated as a number and used directly in the DSA signature
    algorithm.

==================================

Section 12.5. (DSA) says:

    An implementation SHOULD NOT implement DSA keys of size less than
    1024 bits. Note that present DSA is limited to a maximum of 1024 bit
    keys, which are recommended for long-term use. Also, DSA keys MUST
    be an even multiple of 64 bits long.

change to:

    An implementation SHOULD NOT implement DSA keys of size less than
    1024 bits.  DSA keys MUST be an even multiple of 64 bits long.
    The Digital Signature Standard (DSS) specifies that DSA be used
    in one of the following ways:

    * 1024-bit key, 160-bit q, SHA-1 hash
    * 2048-bit key, 224-bit q, SHA-224, SHA-256, SHA-384 or SHA-512 hash
    * 2048-bit key, 256-bit q, SHA-256, SHA-384 or SHA-512 hash
    * 3072-bit key, 256-bit q, SHA-256, SHA-384 or SHA-512 hash

    Other key size and hash combinations are usable in OpenPGP, but
    would not be compliant to DSS.

    Note that earlier versions of this standard only supported a
    160-bit q, so earlier implementations may not be able to
    handle a signature with a different q size.

DSA keys are a multiple of 64 bits.  Are there similar requirements
with regards to the size of q that are worth mentioning here?  I don't
mean the NIST DSS requirements, but rather inherent requirements of
the algorithm.

==================================

Section 13. (Security Considerations) says:

     * The DSA algorithm will work with any 160-bit hash, but it is
       sensitive to the quality of the hash algorithm, if the hash
       algorithm is broken, it can leak the secret key. The Digital
       Signature Standard (DSS) specifies that DSA be used with SHA-1.
       RIPEMD-160 is considered by many cryptographers to be as strong.
       An implementation should take care which hash algorithms are
       used with DSA, as a weak hash can not only allow a signature to
       be forged, but could leak the secret key.

change to:

     * The DSA algorithm will work with any hash, but it is
       sensitive to the quality of the hash algorithm.  An
       implementation should take care which hash algorithms are
       used with DSA, as a weak hash can not only allow a signature to
       be forged, but could leak the secret key.

Hal has expressed concern with the "weak hash can leak the secret key"
warning in the past, so perhaps he'll comment here.

==================================

David