Documente Academic
Documente Profesional
Documente Cultură
Architecture
There are two ways to design a system:
One is to make it so simple there are obviously no deficiencies.
The other is to make it so complex there are no obvious deficiencies.
C.A.R. Hoare
IKE : phases
Phase 1 is where the two ISAKMP peers establish a secure, authenticated
channel with which to communicate. This is called the ISAKMP Security
Association (SA).
Phase 2 is where Security Associations are negotiated on behalf of services
such as IPsec or any other service which needs key material and/or
parameter negotiation.
With the use of ISAKMP phases, an implementation can accomplish very
fast keying when necessary. A single phase 1 negotiation may be used for
more than one phase 2 negotiation. Additionally a single phase 2 negotiation
can request multiple Security Associations. With these optimizations, an
implementation can see less than one round trip per SA as well as less than
one DH exponentiation per SA.
IKE : modes
La phase 1 peut se drouler en mode principal (main mode, 6 messages)
ou en mode agressif (aggressive mode, 3 messages).
La phase 2 se droule en mode rapide (quick mode).
Ngociation
Initiator
----------HDR, SA
Responder
------------>
<--
HDR, SA
Ngociation (2)
The following attributes are used by IKE and are negotiated as part of the
ISAKMP Security Association.
encryption algorithm
hash algorithm
authentication method
information about a group over which to do Diffie-Hellman.
All of these attributes are mandatory and MUST be negotiated.
Ngociation (3)
IKE implementations MUST support the following attribute values:
DES in CBC mode with a weak, and semi-weak, key check (weak and
semi-weak keys are listed in Appendix A). The key is derived according
to Appendix B.
MD5 and SHA.
Authentication via pre-shared keys.
MODP over default group number one.
Ngociation (4)
In addition, IKE implementations SHOULD support:
3DES for encryption;
Tiger for hash;
the Digital Signature Standard, RSA signatures and authentication with
RSA public key encryption;
and MODP group number 2.
IKE implementations MAY support any additional encryption algorithms
defined in Appendix A and MAY support ECP and EC2N groups.
Message ISAKMP
Network Working Group
Request for Comments: 2408
Category: Standards Track
Internet Security Association
and Key Management Protocol (ISAKMP)
D. Maughan
National Security Agency
M. Schertler
Securify, Inc.
M. Schneider
National Security Agency
J. Turner
RABA Technologies, Inc.
November 1998
Cookies
Anti-Clogging Token (to clog = obstruer, encrasser) : pour gner les attaques
DoS (dni de service).
La requte initiale peut tre falsifie (IP spoofing), le serveur ne doit pas
consommer de ressource (mmoire, temps de calcul) avant rception du
message suivant de la part du client (suppos), cod selon les rgles ISAKMP.
Pour que le serveur ne consomme aucune ressource prmaturment, il doit
pouvoir vrifier le responder cookie en mode stateless : Karn's suggested
method for creating the cookie is to perform a fast hash (e.g. MD5) over the IP
Source and Destination Address, the UDP Source and Destination Ports and a
locally generated secret random value.
Impossible ici, car il faut mmoriser les termes de la ngociation, inclus dans
les deux premiers messages
Diffie-Hellman
Initiator
---------HDR, KE, Ni
Responder
------------>
<--
HDR, KE, Nr
Diffie-Hellman (2)
With IKE, the group in which to do the Diffie-Hellman exchange is
negotiated. Four groups -- values 1 through 4 -- are defined below.
These groups originated with the Oakley protocol and are therefore
called "Oakley Groups". These groups were all generated by
Richard Schroeppel at the University of Arizona.
Oakley groups
First Oakley Default Group
Oakley implementations MUST support a MODP group with the following
prime and generator. This group is assigned id 1 (one).
The prime is: 2^768 - 2 ^704 - 1 + 2^64 * { [2^638 pi] + 149686 }
Its hexadecimal value is
FFFFFFFF
29024E08
EF9519B3
E485B576
FFFFFFFF
8A67CC74
CD3A431B
625E7EC6
C90FDAA2
020BBEA6
302B0A6D
F44C42E9
2168C234
3B139B22
F25F1437
A63A3620
C4C6628B
514A0879
4FE1356D
FFFFFFFF
80DC1CD1
8E3404DD
6D51C245
FFFFFFFF
FFFFFFFF
8A67CC74
CD3A431B
625E7EC6
5A899FA5
FFFFFFFF
C90FDAA2
020BBEA6
302B0A6D
F44C42E9
AE9F2411
2168C234
3B139B22
F25F1437
A637ED6B
7C4B1FE6
C4C6628B
514A0879
4FE1356D
0BFF5CB6
49286651
80DC1CD1
8E3404DD
6D51C245
F406B7ED
ECE65381
Generator One:
0x18
Curve A:
0x0
Curve B:
0x1ee9
Order: 0X01ffffffffffffffffffffffdbf2f889b73e484175f94ebc
Nonces
Nonce Payload (RFC 2408)
The Nonce Payload contains random data used to guarantee liveness
(sic) during an exchange and protect against replay attacks. The nonces
may be transmitted as part of the key exchange data, or as a separate
payload. However, this is defined by the key exchange, not by ISAKMP.
Initiator
---------HDR*, IDii, HASH_I -->
<--
Responder
----------HDR*, IDir, HASH_R
IDx is the identification payload for "x". x can be: "ii" or "ir" for the
ISAKMP initiator and responder respectively during phase one
negotiation; or "ui" or "ur" for the user initiator and responder
respectively during phase two.
Responder
------------>
<--->
<--->
<--
HDR, SA
HDR, KE, Nr
HDR*, IDir, HASH_R
HMAC
If a "prf" is not negotiated, the HMAC version of the negotiated hash algorithm is
used as a pseudo-random function.
Responder
----------HDR, SA, KE, Nr, IDir, HASH_R
Mthodes dauthentification
Four different authentication methods are allowed with either Main Mode
or Aggressive Mode :
digital signature,
two forms of authentication with public key encryption,
pre-shared key.
The value SKEYID is computed seperately for each authentication
method.
-->
<-HDR, KE, Ni
-->
<-HDR*, IDii, [ CERT, ] SIG_I -->
<--
Responder
----------HDR, SA
HDR, KE, Nr
HDR*, IDir, [ CERT, ] SIG_R
Rappel
Responder
------------>
<--->
HDR*, HASH_I
Responder
------------>
<--
HDR, SA
-->
<--->
<--
HDR, <Nr_b>PubKey_i,
<KE_b>Ke_r,
<IDir_b>Ke_r,
HDR*, HASH_R
The symmetric cipher keys are derived from the decrypted nonces as follows.
First the values Ne_i and Ne_r are computed:
Ne_i = prf (Ni_b, CKY-I)
Ne_r = prf (Nr_b, CKY-R)
The keys Ke_i and Ke_r are then taken from Ne_i and Ne_r respectively in
the manner described in Appendix B used to derive symmetric keys for use
with the negotiated encryption algorithm.
HDR, HASH_I
<--->
Responder
-----------
-->
Responder
----------HDR*, HASH(2), SA, Nr
[, KE ] [, IDci, IDcr]
etc.