grub-devel.gnu.org archive mirror
 help / color / mirror / Atom feed
From: "Vladimir 'φ-coder/phcoder' Serbinenko" <phcoder@gmail.com>
To: The development of GNU GRUB <grub-devel@gnu.org>
Subject: Re: DSA GnuPG signatures
Date: Fri, 11 Jan 2013 23:46:13 +0100	[thread overview]
Message-ID: <50F09635.7060207@gmail.com> (raw)
In-Reply-To: <20130111221447.GA26172@riva.dynamic.greenend.org.uk>

[-- Attachment #1: Type: text/plain, Size: 3298 bytes --]

On 11.01.2013 23:14, Colin Watson wrote:

> On Fri, Jan 11, 2013 at 09:54:22PM +0100, Vladimir 'φ-coder/phcoder' Serbinenko wrote:
>> 1) DSA keys only. RSA is more tricky since it needs padding and RSA
>> should be progressively phased out, not put into new places due to some
>> vulnerabilities (large classes of semiprimes are factorisable up to the
>> point when a lot of care has to be taken to avoid them).
> 
> This is highly questionable.  DSA is particularly sensitive to
> low-entropy situations and has various other systemic vulnerabilities
> that RSA doesn't have, mainly to do with the extreme sensitivity of k.
> For example, when Debian had its notorious OpenSSL vulnerability
> involving poor random number generation, RSA keys that were generated on
> a system with the vulnerability were indeed compromised; but DSA keys
> were compromised even if they were only ever used to generate a single
> signature on a system with the vulnerability!  Knowledge of even a few
> bits of k is sufficient to recover a DSA private key if you collect a
> relatively small number of signatures made by that key (say, rather less
> than the number of modules shipped by GRUB).  This is the sort of thing
> that makes me want to avoid a cipher, particularly for something like
> GRUB where it's quite possible that you might find yourself needing to
> sign things in situations where only limited entropy is available, even
> though the key might well have been generated in better conditions.
> 

Most schemes that need random, need a very good random numbers. That's
why GRUB doesn't use anything needing random. And that's why sign
functions are removed altogether.

> RSA with a decent key length is perfectly fine and there is no call that
> I'm aware of to phase it out.  Rather to the contrary, DSA is the one
> that I would normally prefer to avoid except where dictated by
> compatibility considerations.
> 
> Assuming that the semiprimes you're referring to are those in
> https://en.wikipedia.org/wiki/RSA_numbers, nobody appears to have got
> any further than 768 bits.  That would be a tiny key by modern
> standards; I've been using 4096 bits everywhere for a few years now, and
> of course the difficulty of factoring scales up much faster than
> linearly in the key length.  I am not aware (and
> https://en.wikipedia.org/wiki/RSA_%28algorithm%29#Integer_factorization_and_RSA_problem
> would appear to agree) of any suggestions that >=4096-bit keys might be
> considered weak any time soon.
> 

(AFAIR) Would need to recheck to be exact
From the p and q you can compute 2 numbers: 0 < alpha, beta < 1. And if
they are small, you can factorise pq even for long keys. There is a
supposition that you could extend these algorithms up to when
0<alpha<0.5 or 0<beta<0.5 or about 75% of possible keys. This was
discovered in 90's and required some adjustments to key generation and
big key regenerations. Keys generated today should be safe. Other
undesirable properties are mitigated by padding.

> Please reconsider.
> 

Ok. Let's move the "opinion" from "not accepted" to "patches are
welcome". The missing part is mainly the padding which is detailed in
RFC4880.

-- 
Regards
Vladimir 'φ-coder/phcoder' Serbinenko


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 294 bytes --]

  reply	other threads:[~2013-01-11 22:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-11 20:54 DSA GnuPG signatures Vladimir 'φ-coder/phcoder' Serbinenko
2013-01-11 22:14 ` Colin Watson
2013-01-11 22:46   ` Vladimir 'φ-coder/phcoder' Serbinenko [this message]
2013-01-13  8:33 ` Andrey Borzenkov
2013-01-13 16:47   ` Vladimir 'φ-coder/phcoder' Serbinenko
2013-01-31 12:49 ` Andrey Borzenkov
2013-04-03 14:34   ` Vladimir 'φ-coder/phcoder' Serbinenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=50F09635.7060207@gmail.com \
    --to=phcoder@gmail.com \
    --cc=grub-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).