PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Serveur - Sécurité et techniques > comp.security.ssh > 160-bit key limit
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.security.ssh SSH secure remote login and tunneling tools.

160-bit key limit

Réponse
 
LinkBack Outils de la discussion
Vieux 12/07/2007, 05h14   #1
yawnmoth
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut 160-bit key limit

>From PuTTy's SSH.c:

/*
* Work out the number of bits of key we will need from the key
* exchange. We start with the maximum key length of either
* cipher...
*/
{
int csbits, scbits;

csbits = s->cscipher_tobe->keylen;
scbits = s->sccipher_tobe->keylen;
s->nbits = (csbits > scbits ? csbits : scbits);
}
/* The keys only have 160-bit entropy, since they're based on
* a SHA-1 hash. So cap the key size at 160 bits. */
if (s->nbits > 160)
s->nbits = 160;

I thought that the maximum key size was whatever the modulo for the
diffie-hellman key exchange was. If you're using diffie-hellman-
group1-sha1, that'd be 1024 bits. I don't see where SHA-1 factors
into it. Diffie-hellman cetainly doesn't use SHA-1. The exchange
hash does but the exchange hash doesn't have anything to do choosing
the key - it just provides a signature that can be used to verify a
servers identity.

  Réponse avec citation
Vieux 12/07/2007, 09h01   #2
Simon Tatham
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: 160-bit key limit

yawnmoth <terra1024@yahoo.com> wrote:
> I thought that the maximum key size was whatever the modulo for the
> diffie-hellman key exchange was. If you're using diffie-hellman-
> group1-sha1, that'd be 1024 bits. I don't see where SHA-1 factors
> into it.


SHA-1 is used _after_ the key exchange, to convert the output of the
key exchange into the session keys used to do the actual bulk
symmetric data encryption. (This is the meaning of `sha1' in the key
exchange method name you quote.)
--
Simon Tatham "I'm going to pull his head off. Ear by ear."
<anakin@pobox.com> - a games teacher
  Réponse avec citation
Vieux 12/07/2007, 20h45   #3
yawnmoth
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: 160-bit key limit

On Jul 12, 3:01 am, Simon Tatham <ana...@pobox.com> wrote:
> yawnmoth <terra1...@yahoo.com> wrote:
> > I thought that the maximum key size was whatever the modulo for the
> > diffie-hellman key exchange was. If you're using diffie-hellman-
> > group1-sha1, that'd be 1024 bits. I don't see where SHA-1 factors
> > into it.

>
> SHA-1 is used _after_ the key exchange, to convert the output of the
> key exchange into the session keys used to do the actual bulk
> symmetric data encryption. (This is the meaning of `sha1' in the key
> exchange method name you quote.)

Hmmm. What, then, is the difference between aes256-cbc or aes192-
cbc? My guess would be that the 160 bits of the SHA-1 hash are
repeated in both cases.

I'd look in the relevant RFC (4253), but didn't see anything about
this at all. Maybe it was deleted with a newer revision? Such things
wouldn't be unprecedented, as this post elaborates:

http://groups.google.com/group/comp....7e121da0dddd53

  Réponse avec citation
Vieux 13/07/2007, 23h55   #4
Ben Harris
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: 160-bit key limit

In article <1184269547.728690.84560@d55g2000hsg.googlegroups. com>,
yawnmoth <terra1024@yahoo.com> wrote:
>On Jul 12, 3:01 am, Simon Tatham <ana...@pobox.com> wrote:
>> yawnmoth <terra1...@yahoo.com> wrote:
>> > I thought that the maximum key size was whatever the modulo for the
>> > diffie-hellman key exchange was. If you're using diffie-hellman-
>> > group1-sha1, that'd be 1024 bits. I don't see where SHA-1 factors
>> > into it.

>>
>> SHA-1 is used _after_ the key exchange, to convert the output of the
>> key exchange into the session keys used to do the actual bulk
>> symmetric data encryption. (This is the meaning of `sha1' in the key
>> exchange method name you quote.)

>Hmmm. What, then, is the difference between aes256-cbc or aes192-
>cbc? My guess would be that the 160 bits of the SHA-1 hash are
>repeated in both cases.


Not quite, but the shared secret, K, is the first thing fed to SHA-1
every time it's used (except in generating the session ID, but that's
not really secret), so all its entropy gets squashed down into the
160-bit internal state of SHA-1.

>I'd look in the relevant RFC (4253), but didn't see anything about
>this at all.


Um, the algorithm for generating symmetric keys is in section 7.2. That
their entropy is limited is a consequence of that algorithm.

--
Ben Harris
  Réponse avec citation
Vieux 14/07/2007, 18h03   #5
yawnmoth
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: 160-bit key limit

On Jul 13, 5:55 pm, Ben Harris <bjhar...@chiark.greenend.org.uk>
wrote:
> <snip>
> Um, the algorithm for generating symmetric keys is in section 7.2. That
> their entropy is limited is a consequence of that algorithm.


Hmmm - I completely missed that section - thanks for pointing it
out!

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 12h16.


Édité par : vBulletin® version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,18039 seconds with 13 queries