8 .ds RF FORMFEED[Page %]
17 Network Working Group P. Riikonen
19 draft-riikonen-silc-ke-auth-00.txt 28 June 2000
25 SILC Key Exchange and Authentication Protocols
26 <draft-riikonen-silc-ke-auth-00.txt>
31 This document is an Internet-Draft and is in full conformance with
32 all provisions of Section 10 of RFC 2026. Internet-Drafts are
33 working documents of the Internet Engineering Task Force (IETF), its
34 areas, and its working groups. Note that other groups may also
35 distribute working documents as Internet-Drafts.
37 Internet-Drafts are draft documents valid for a maximum of six months
38 and may be updated, replaced, or obsoleted by other documents at any
39 time. It is inappropriate to use Internet-Drafts as reference
40 material or to cite them other than as "work in progress."
42 The list of current Internet-Drafts can be accessed at
43 http://www.ietf.org/ietf/1id-abstracts.txt
45 The list of Internet-Draft Shadow Directories can be accessed at
46 http://www.ietf.org/shadow.html
48 The distribution of this memo is unlimited.
54 This memo describes two protocols used in the Secure Internet Live
55 Conferencing (SILC) protocol specified in the Secure Internet Live
56 Conferencing, Protocol Specification internet-draft [SILC1]. The
57 SILC Key Exchange (SKE) protocol provides secure key exchange between
58 two parties resulting into shared secret key material. The protocol
59 is based on Diffie Hellman key exchange algorithm and its functionality
60 is derived from several key exchange protocols. SKE uses best parts
61 of the SSH2 Key Exchange protocol, Station-To-Station (STS) protocol
62 and the OAKLEY Key Determination protocol [OAKLEY].
64 The SILC Connection Authentication protocol provides user level
65 authentication used when creating connections in SILC network. The
66 protocol is transparent to the authentication data which means that it
67 can be used to authenticate the user with, for example, passphrase
68 (pre-shared- secret) or public key (and certificate).
76 1 Introduction .................................................. 2
77 2 SILC Key Exchange Protocol .................................... 3
78 2.1 Key Exchange Payloads ..................................... 3
79 2.1.1 Key Exchange Start Payload .......................... 4
80 2.1.2 Key Exchange 1 Payload .............................. 7
81 2.1.3 Key Exchange 2 Payload .............................. 9
82 2.2 Key Exchange Procedure .................................... 10
83 2.3 Processing the Key Material ............................... 12
84 2.4 SILC Key Exchange Groups .................................. 13
85 2.4.1 diffie-hellman-group1 ............................... 13
86 2.4.2 diffie-hellman-group2 ............................... 14
87 2.5 Key Exchange Status Types ................................. 14
88 3 SILC Connection Authentication Protocol ....................... 16
89 3.1 Connection Auth Payload ................................... 17
90 3.2 Connection Authentication Types ........................... 18
91 3.2.1 Passphrase Authentication ........................... 18
92 3.2.2 Public Key Authentication ........................... 18
93 3.3 Connection Authentication Status Types .................... 19
94 4 Security Considerations ....................................... 19
95 5 References .................................................... 19
96 6 Author's Address .............................................. 20
103 Figure 1: Key Exchange Start Payload
104 Figure 2: Key Exchange 1 Payload
105 Figure 3: Key Exchange 2 Payload
106 Figure 4: Connection Auth Payload
112 This memo describes two protocols used in the Secure Internet Live
113 Conferencing (SILC) protocol specified in the Secure Internet Live
114 Conferencing, Protocol Specification internet-draft [SILC1]. The
115 SILC Key Exchange (SKE) protocol provides secure key exchange between
116 two parties resulting into shared secret key material. The protocol
117 is based on Diffie Hellman key exchange algorithm and its functionality
118 is derived from several key exchange protocols. SKE uses best parts
119 of the SSH2 Key Exchange protocol, Station-To-Station (STS) protocol
120 and the OAKLEY Key Determination protocol.
122 The SILC Connection Authentication protocol provides user level
123 authentication used when creating connections in SILC network. The
124 protocol is transparent to the authentication data which means that it
125 can be used to authenticate the user with, for example, passphrase
126 (pre-shared- secret) or public key (and certificate).
128 The basis of secure SILC session requires strong and secure key exchange
129 protocol and authentication. The authentication protocol is entirely
130 secured and no authentication data is ever sent in the network without
131 encrypting and authenticating it first. Thus, authentication protocol
132 may be used only after the key exchange protocol has been successfully
135 This document refers constantly to other SILC protocol specification
136 Internet Drafts that are a must read for those who wants to understand
137 the function of these protocols. The most important references are
138 the Secure Internet Live Conferencing, Protocol Specification [SILC1]
139 and SILC Packet Protocol [SILC2] Internet Drafts.
141 The protocol is intended to be used with the SILC protocol thus it
142 does not define own framework that could be used. The framework is
143 provided by the SILC protocol.
147 2 SILC Key Exchange Protocol
149 SILC Key Exchange Protocol (SKE) is used to exchange shared secret
150 between connecting entities. The result of this protocol is a key
151 material used to secure the communication channel. The protocol uses
152 Diffie-Hellman key exchange algorithm and its functionality is derived
153 from several key exchange protocols. SKE uses best parts of the SSH2
154 Key Exchange protocol, Station-To-Station (STS) protocol and the OAKLEY
155 Key Determination protocol. The protocol does not claim any conformance
156 to any of these protocols, they were merely used as a reference when
157 designing this protocol.
159 The purpose of SILC Key Exchange protocol is to create session keys to
160 be used in current SILC session. The keys are valid only for some period
161 of time (usually an hour) or at most until the session ends. These keys
162 are used to protect packets like commands, command replies and other
163 communication between two entities. If connection is server to server
164 connection, the keys are used to protect all traffic between those
165 servers. In client connections usually all the packets are protected
166 with this key except channel messages; channels has their own keys and
167 they are not exchanged with this protocol.
171 2.1 Key Exchange Payloads
173 During the key exchange procedure public data is sent between initiator
174 and responder. This data is later used in the key exchange procedure.
175 There are several payloads used in the key exchange. As for all SILC
176 packets, SILC Packet Header, described in [SILC2], is at the start of all
177 packets, the same is done with these payloads as well. All fields in
178 all payloads are always in MSB (most significant byte first) order.
179 Following descriptions of these payloads.
183 2.1.1 Key Exchange Start Payload
185 Key exchange between two entities always begins with a
186 SILC_PACKET_KEY_EXCHANGE packet containing Key Exchange Start Payload.
187 When performing key exchange between client and server, the client sends
188 Key Exchange Start Payload to server filled with all security properties
189 that the client supports. Server then checks if it supports the security
192 It then sends a Key Exchange Start Payload to client filled with security
193 properties it selected from the payload client originally sent. The
194 payload sent by server must include only one chosen property per list.
196 When performing key exchange between server and server, the server who
197 is contacting sends the Key Exchange Start Payload with security property
198 list it supports to the other server. The contacted party then chooses
199 the preferred properties same way as previously described. It then
200 replies with the properties it wanted same way as previously described.
202 The Key Exchange Start Payload is used to tell connecting entities what
203 security properties and algorithms should be used in the communication.
204 If perfect forward secrecy (PFS) is not desired (PFS is undefined by
205 default) Key Exchange Start Payload is sent only once per session, thus,
206 for example, re-keying will not cause sending of a new payload. If PFS
207 is desired, re-keying will always cause new key exchange thus causes
208 sending of a new Key Exchange Start Payload.
210 When performing first key exchange this payload is never encrypted, as
211 there are no existing keys to encrypt it with. If performing re-keying
212 (PFS was selected) this payload is encrypted with the existing key and
213 encryption algorithm.
215 Cookie is also send in this payload. Cookie is used to uniform the
216 payload so that none of the key exchange parties cannot determine this
217 payload before hand. The cookie must be returned to the original sender
220 Following diagram represents the Key Exchange Start Payload. The lists
221 mentioned below are always comma (`,') separated and the list must
222 not include spaces (` ').
233 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
234 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
235 | RESERVED | Flags | Payload Length |
236 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
244 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
245 | Key Exchange Grp Length | |
246 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
248 ~ Key Exchange Groups ~
250 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
251 | PKCS Alg Length | |
252 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
256 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
257 | Encryption Alg Length | |
258 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
260 ~ Encryption Algorithms ~
262 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
263 | Hash Alg Length | |
264 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
268 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
269 | Compression Alg Length | |
270 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
272 ~ Compression Algorithms ~
274 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
278 Figure 1: Key Exchange Start Payload
283 o RESERVED (1 byte) - Reserved field. Sender fills this with
286 o Flags (1 byte) - Indicates flags to be used in the key
287 exchange. Several flags can be set at once by ORing the
288 flags together. Following flags are reserved for this field.
292 In this case the field is ignored.
296 If set the receiver of the payload does not reply to
301 Perfect Forward Secrecy (PFS) to be used in the
302 key exchange protocol. If not set, re-keying
303 is performed using the old key. When PFS is used,
304 re-keying and creating new keys for any particular
305 purpose will cause new key exchange.
307 Rest of the flags are reserved for the future and
310 o Payload Length (2 bytes) - Length of the entire Key Exchange
313 o Cookie (16 bytes) - Cookie that uniforms this payload so
314 that each of the party cannot determine the payload before
317 o Key Exchange Grp Length (2 bytes) - The length of the
318 key exchange group list, including this field as well.
320 o Key Exchange Group (variable length) - The list of
321 key exchange groups. See the section 2.1.2 SILC Key Exchange
322 Groups for definitions of these groups.
324 o PKCS Alg Length (2 bytes) - The length of the PKCS algorithms
325 list, including this field as well.
327 o PKCS Algorithms (variable length) - The list of PKCS
330 o Encryption Alg Length (2 bytes) - The length of the encryption
331 algorithms list, including this field as well.
333 o Encryption Algorithms (variable length) - The list of
334 encryption algorithms.
336 o Hash Alg Length (2 bytes) - The length of the Hash algorithms
337 list, including this field as well.
339 o Hash Algorithms (variable length) - The list of Hash algorithms.
341 o Compression Alg Length (2 bytes) - The length of the
342 compression algorithms list, including this field as well.
344 o Compression Algorithms (variable length) - The list of
345 compression algorithms.
350 2.1.2 Key Exchange 1 Payload
352 Key Exchange 1 Payload is used to deliver computed public data from
353 initiator to responder. This data is used to compute the shared secret,
354 later by all parties. Key Exchange 1 Payload is only sent after the
355 SILC_PACKET_KEY_EXCHANGE packet and the Key Exchange Start Payload has
356 been processed by all the parties.
358 This payload sends the initiator's public key to the responder. Responder
359 may need the public key in which case it should be checked to be trusted
362 The payload may only be sent with SILC_PACKET_KEY_EXCHANGE_1 packet.
363 It must not be sent in any other packet type. Following diagram
364 represent the Key Exchange 1 Payload.
384 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
385 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
386 | Public Key Length | Public Key Type |
387 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
389 ~ Public Key of the Host (or certificate) ~
391 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
392 | Public Data Length | |
393 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
395 ~ Public Data (e = g ^ x mod p) ~
397 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
401 Figure 2: Key Exchange 1 Payload
405 o Public Key Length (2 bytes) - The length of the public key
406 (or certificate), including this field and public key type
409 o Public Key Type (2 bytes) - The public key (or certificate)
410 type. This field indicates the type of the public key in
411 the packet. Following types are defined:
413 1 SILC style public key (mandatory)
414 2 SSH2 style public key (optional)
415 3 X.509 Version 3 certificate (optional)
416 4 OpenPGP certificate (optional)
417 5 SPKI certificate (optional)
419 The only required type to support is type number 1. See
420 [SILC1] for the SILC public key specification. See
421 SSH public key specification in [SSH-TRANS]. See X.509v3
422 certificate specification in [PKIX-Part1]. See OpenPGP
423 certificate specification in [PGP]. See SPKI certificate
424 specification in [SPKI]. If this field includes zero (0)
425 or unsupported type number the protocol must be aborted
426 sending SILC_PACKET_FAILURE message.
428 o Public Data Length (2 bytes) - The length of the public
429 data computed by the responder, including this field
432 o Public Data (variable length) - The public data to be
433 sent to the responder. See section 2.2 Key Exchange
434 Procedure for detailed description how this field is
435 computed. This value is binary encoded.
440 2.1.3 Key Exchange 2 Payload
442 Key Exchange 2 Payload is used to deliver public key, computed public
443 data and signature from responder to initiator. Initiator uses these
444 public parts of the key exchange protocol to compute the shared secret.
446 The payload may only be sent with SILC_PACKET_KEY_EXCHANGE_2 packet.
447 It must not be sent in any other packet type. Following diagram
448 represent the Key Exchange 2 Payload.
455 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
456 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
457 | Public Key Length | Public Key Type |
458 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
460 ~ Public Key of the Host (or certificate) ~
462 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
463 | Public Data Length | |
464 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
466 ~ Public Data (f = g ^ y mod p) ~
468 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
469 | Signature Length | |
470 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ +
474 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
478 Figure 3: Key Exchange 2 Payload
483 o Public Key Length (2 bytes) - The length of the public key
484 (or certificate), including this field and public key type
487 o Public Key Type (2 bytes) - The public key (or certificate)
488 type. This field indicates the type of the public key in
489 the packet. See previous sections for defined public key
492 o Public Key of the host (variable length) - The public
493 key of the sender (or its certificate). This is verified
494 by the receiver of the packet. The type of this field
495 is indicated by previous Public Key Type field.
497 o Public Data Length (2 bytes) - The length of the public
498 data computed by the responder, including this field
501 o Public Data (variable length) - The public data computed
502 by the responder. See section 2.2 Key Exchange Procedure
503 for detailed description how this field is computed. This
504 value is binary encoded.
506 o Signature Length (2 bytes) - The length of the signature,
507 including the length of this field as well.
509 o Signature Data (variable length) - The signature signed
510 by the responder. The receiver of this signature must
511 verify it. The verification is done using the public
512 key received in this same payload. See section 2.2
513 Key Exchange Procedure for detailed description how
514 to produce the signature.
518 2.2 Key Exchange Procedure
520 The key exchange begins by sending SILC_PACKET_KEY_EXCHANGE packet with
521 Key Exchange Start Payload to select the security properties to be used
522 in the key exchange and later in the communication.
524 After Key Exchange Start Payload has been processed by both of the
525 parties the protocol proceeds as follows:
528 Setup: p is a large and public safe prime. This is one of the
529 Diffie Hellman groups. q is order of subgroup (largest
530 prime factor of p). g is a generator and is defined
531 along with the Diffie Hellman group.
533 1. Initiator generates a random number x, where 1 < x < q,
534 and computes e = g ^ x mod p. The result e is then
535 encoded into Key Exchange 1 Payload and sent
539 2. Responder generates a random number y, where 1 < y < q,
540 and computes f = g ^ y mod p. It then computes the
541 shared secret KEY = e ^ y mod p, and, a hash value
542 HASH = hash(Key Exchange Start Payload data | Host public
543 key (or certificate) | e | f | KEY). It then signs
544 the HASH value with its private key resulting a signature
547 It then encodes its public key (or certificate), f and
548 SIGN into Key Exchange 2 Payload and sends it to the
552 3. Initiator verifies that the public key provided in
553 the payload is authentic, or if certificates are used
554 it verifies the certificate. Initiator may accept
555 the public key without verifying it, however, doing
556 so may result to insecure key exchange (accepting the
557 public key without verifying may be desirable for
558 practical reasons on many environments. For long term
559 use this is never desirable, in which case certificates
560 would be the preferred method to use).
562 Initiator then computes the shared secret KEY =
563 f ^ x mod p, and, a hash value HASH in the same way as
564 responder did in phase 2. It then verifies the
565 signature SIGN from the payload with the hash value
566 HASH using the received public key.
569 If any of these phases is to fail SILC_PACKET_FAILURE is sent to
570 indicate that the key exchange protocol failed. Any other packets must
571 not be sent or accepted during the key exchange except the
572 SILC_PACKET_KEY_EXCHANGE_*, SILC_PACKET_DISCONNECT, SILC_PACKET_FAILURE
573 and/or SILC_PACKET_SUCCESS packets.
575 The result of this protocol is a shared secret key material KEY and
576 a hash value HASH. The key material itself is not fit to be used as
577 a key, it needs to be processed further to derive the actual keys to be
578 used. The key material is also used to produce other security parameters
579 later used in the communication. See section 2.3 Processing the Key
580 Material for detailed description how to process the key material.
582 After the keys are processed the protocol is ended by sending the
583 SILC_PACKET_SUCCESS packet. Both entities send this packet to
584 each other. After this both parties will start using the new keys.
589 2.3 Processing the Key Material
591 Key Exchange protocol produces secret shared key material KEY. This
592 key material is used to derive the actual keys used in the encryption
593 of the communication channel. The key material is also used to derive
594 other security parameters used in the communication. Key Exchange
595 protocol produces a hash value HASH as well. This is used in the key
596 deriving process as a session identifier.
598 Keys are derived from the key material as follows:
601 Sending Initial Vector (IV) = hash(0 | KEY | HASH)
602 Receiving Initial Vector (IV) = hash(1 | KEY | HASH)
603 Sending Encryption Key = hash(2 | KEY | HASH)
604 Receiving Encryption Key = hash(3 | KEY | HASH)
605 HMAC Key = hash(4 | KEY | HASH)
609 The Initial Vector (IV) is used in the encryption when doing for
610 example CBC mode. As many bytes as needed are taken from the start of
611 the hash output for IV. Sending IV is for sending key and receiving IV
612 is for receiving key. For receiving party, the receiving IV is actually
613 sender's sending IV, and, the sending IV is actually sender's receiving
614 IV. Initiator uses IV's as they are (sending IV for sending and
615 receiving IV for receiving).
617 The Encryption Keys are derived as well from the hash(). If the hash()
618 output is too short for the encryption algorithm more key material is
619 produced in following manner:
622 K1 = hash(2 | KEY | HASH)
624 K3 = hash(KEY | K1 | K2) ...
626 Sending Encryption Key = K1 | K2 | K3 ...
629 K1 = hash(3 | KEY | HASH)
631 K3 = hash(KEY | K1 | K2) ...
633 Receiving Encryption Key = K1 | K2 | K3 ...
637 The key is distributed by hashing the previous hash with the original
638 key material. The final key is a concatenation of the hash values.
639 For Receiving Encryption Key the procedure is equivalent. Sending key
640 is used only for encrypting data to be sent. The receiving key is used
641 only to decrypt received data. For receiving party, the receive key is
642 actually sender's sending key, and, the sending key is actually sender's
643 receiving key. Initiator uses generated keys as they are (sending key
644 for sending and receiving key for sending).
646 The HMAC key is used to create MAC values to packets in the communication
647 channel. As many bytes as needed are taken from the start of the hash
650 These procedures are performed by all parties of the key exchange
651 protocol. This must be done before the protocol has been ended by
652 sending the SILC_PACKET_SUCCESS packet.
656 2.4 SILC Key Exchange Groups
658 Following groups may be used in the SILC Key Exchange protocol. The
659 first group diffie-hellman-group1 is mandatory, other groups maybe
660 negotiated to be used in the connection with Key Exchange Start Payload
661 and SILC_PACKET_KEY_EXCHANGE packet. However, the first group must be
662 proposed in the Key Exchange Start Payload regardless of any other
663 requested group (however, it doesn't have to be the first on the list).
667 2.4.1 diffie-hellman-group1
669 The length of this group is 1024 bits. This is mandatory group.
670 The prime is 2^1024 - 2^960 - 1 + 2^64 * { [2^894 pi] + 129093 }.
675 179769313486231590770839156793787453197860296048756011706444
676 423684197180216158519368947833795864925541502180565485980503
677 646440548199239100050792877003355816639229553136239076508735
678 759914822574862575007425302077447712589550957937778424442426
679 617334727629299387668709205606050270810842907692932019128194
683 Its hexadecimal value is
686 FFFFFFFF FFFFFFFF C90FDAA2 2168C234 C4C6628B 80DC1CD1
687 29024E08 8A67CC74 020BBEA6 3B139B22 514A0879 8E3404DD
688 EF9519B3 CD3A431B 302B0A6D F25F1437 4FE1356D 6D51C245
689 E485B576 625E7EC6 F44C42E9 A637ED6B 0BFF5CB6 F406B7ED
690 EE386BFB 5A899FA5 AE9F2411 7C4B1FE6 49286651 ECE65381
695 The generator used with this prime is g = 2. The group order q is
698 This group was taken from the OAKLEY specification.
702 2.4.2 diffie-hellman-group2
704 The length of this group is 1536 bits. This is optional group.
705 The prime is 2^1536 - 2^1472 - 1 + 2^64 * { [2^1406 pi] + 741804 }.
710 241031242692103258855207602219756607485695054850245994265411
711 694195810883168261222889009385826134161467322714147790401219
712 650364895705058263194273070680500922306273474534107340669624
713 601458936165977404102716924945320037872943417032584377865919
714 814376319377685986952408894019557734611984354530154704374720
715 774996976375008430892633929555996888245787241299381012913029
716 459299994792636526405928464720973038494721168143446471443848
717 8520940127459844288859336526896320919633919
720 Its hexadecimal value is
723 FFFFFFFF FFFFFFFF C90FDAA2 2168C234 C4C6628B 80DC1CD1
724 29024E08 8A67CC74 020BBEA6 3B139B22 514A0879 8E3404DD
725 EF9519B3 CD3A431B 302B0A6D F25F1437 4FE1356D 6D51C245
726 E485B576 625E7EC6 F44C42E9 A637ED6B 0BFF5CB6 F406B7ED
727 EE386BFB 5A899FA5 AE9F2411 7C4B1FE6 49286651 ECE45B3D
728 C2007CB8 A163BF05 98DA4836 1C55D39A 69163FA8 FD24CF5F
729 83655D23 DCA3AD96 1C62F356 208552BB 9ED52907 7096966D
730 670C354E 4ABC9804 F1746C08 CA237327 FFFFFFFF FFFFFFFF
733 The generator used with this prime is g = 2. The group order q is
736 This group was taken from the OAKLEY specification.
740 2.5 Key Exchange Status Types
742 This section defines all key exchange protocol status types that may be
743 returned in the SILC_PACKET_SUCCESS or SILC_PACKET_FAILURE packets to
744 indicate the status of the protocol. Implementations may map the
745 status types to human readable error message. All types except the
746 SILC_SKE_STATUS_OK type must be sent in SILC_PACKET_FAILURE packet.
747 Following status types are defined:
752 Protocol were exeucted succesfully.
755 1 SILC_SKE_STATUS_ERROR
757 Unknown error occured. No specific error type is defined.
760 2 SILC_SKE_STATUS_BAD_PAYLOAD
762 Provided KE payload were malformed or included bad fields.
765 3 SILC_SKE_STATUS_UNSUPPORTED_GROUP
767 None of the provided groups were supported.
770 4 SILC_SKE_STATUS_UNSUPPORTED_CIPHER
772 None of the provided ciphers were supported.
775 5 SILC_SKE_STATUS_UNSUPPORTED_PKCS
777 None of the provided public key algorithms were supported.
780 6 SILC_SKE_STATUS_UNSUPPORTED_HASH_FUNCTION
782 None of the provided hash functions were supported.
785 7 SILC_SKE_STATUS_UNSUPPORTED_PUBLIC_KEY
787 Provided public key type is not supported.
790 8 SILC_SKE_STATUS_INCORRECT_SIGNATURE
792 Provided signature was incorrect.
800 3 SILC Connection Authentication Protocol
802 Purpose of Connection Authentication protocol is to authenticate the
803 connecting party with server. Usually connecting party is client but
804 server may connect to server as well. Its other purpose is to provide
805 information for the server about which type of connection this is.
806 The type defines whether this is client, server or router connection.
807 Server uses this information to create the ID for the connection. After
808 the authentication protocol has been successfully completed
809 SILC_PACKET_NEW_ID must be sent to the connecting party by the server.
810 See section New ID Payload in [SILC2] for detailed description for this
813 Server must verify the authentication data received and if it is to fail
814 the authentication must be failed by sending SILC_PACKET_FAILURE packet.
815 If everything checks out fine the protocol is ended by server by sending
816 SILC_PACKET_SUCCESS packet.
818 The protocol is executed after the SILC Key Exchange protocol. It must
819 not be executed in any other time. As it is performed after key exchange
820 protocol all traffic in the connection authentication protocol is
821 encrypted with the exchanged keys.
823 The protocol is started by the connecting party by sending
824 SILC_PACKET_CONNECTION_AUTH packet with Connection Auth Payload,
825 described in the next section. This payload must include the
826 authentication data. Authentication data is set according
827 authentication method that must be known by both parties. If connecting
828 party does not know what is the mandatory authentication method it must
829 request it from the server by sending SILC_PACKET_CONNECTION_AUTH_REQUEST
830 packet. This packet is not part of this protocol and is described in
831 section Connection Auth Request Payload in [SILC2]. However, if
832 connecting party already knows the mandatory authentication method
833 sending the request is not necessary.
835 See [SILC1] and section Connection Auth Request Payload in [SILC2] also
836 for the list of different authentication methods. Authentication method
837 may also be NONE, in which case the server does not require
838 authentication at all. However, in this case the protocol still must be
839 executed; the authentication data just is empty indicating no
840 authentication is required.
842 If authentication method is passphrase the authentication data is
843 plaintext passphrase. As the payload is entirely encrypted it is safe
844 to have plaintext passphrase. 3.2.1 Passphrase Authentication for
848 If authentication method is public key authentication the authentication
849 data is signature of the hash value HASH plus Key Exchange Start Payload,
850 established by the SILC Key Exchange protocol. This signature must then
851 be verified by the server. See section 3.2.2 Public Key Authentication
852 for more information.
854 The connecting party of this protocol must wait after successful execution
855 of this protocol for the SILC_PACKET_NEW_ID packet where it will receive
856 the ID it will be using in the SILC network. Connecting party cannot
857 start normal SILC session (sending messages or commands) until it has
858 received its ID. The ID's are always created by the server except
859 for server to server connection where servers create their own ID's.
864 3.1 Connection Auth Payload
866 Client sends this payload to authenticate itself to the server. Server
867 connecting to another server also sends this payload. Server receiving
868 this payload must verify all the data in it and if something is to fail
869 the authentication must be failed by sending SILC_PACKET_FAILURE packet.
871 The payload may only be sent with SILC_PACKET_CONNECTION_AUTH packet.
872 It must not be sent in any other packet type. Following diagram
873 represent the Connection Auth Payload.
879 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
880 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
881 | Payload Length | Connection Type |
882 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
884 ~ Authentication Data ~
886 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
890 Figure 4: Connection Auth Payload
894 o Payload Length (2 bytes) - Length of the entire Connection
897 o Connection Type (2 bytes) - Indicates the type of the
898 connection. See section Connection Auth Request Payload
899 in [SILC2] for the list of connection types. This field must
900 include valid connection type or the packet must be discarded
901 and authentication must be failed.
903 o Authentication Data (variable length) - The actual
904 authentication data. Contents of this depends on the
905 authentication method known by both parties. If no
906 authentication is required this field does not exist.
911 3.2 Connection Authentication Types
913 SILC supports two authentication types to be used in the connection
914 authentication protocol; passphrase or public key based authentication.
915 Following sections defines the authentication methods. See [SILC2]
916 for defined numerical authentication method types.
920 3.2.1 Passphrase Authentication
922 Passphrase authentication or pre-shared-key base authentication is
923 simply an authentication where the party that wants to authenticate
924 itself to the other end sends the passphrase that is required by
925 the other end, for example server.
927 If the passphrase matches with the one in the server's end the
928 authentication is successful. Otherwise SILC_PACKET_FAILURE must be
929 sent to the sender and the protocol execution fails.
931 This is required authentication method to be supported by all SILC
936 3.2.2 Public Key Authentication
938 Public key authentication may be used if passphrase based authentication
939 is not desired. The public key authentication works by sending a
940 signature as authentication data to the other end, say, server. The
941 server must then verify the signature by the public key of the sender,
942 which the server has received earlier in SKE protocol.
944 The signature is computed using the private key of the sender by signing
945 the HASH value provided by the SKE protocol previously, and the Key
946 Exchange Start Payload from SKE protocol that was sent to the server.
947 The server must verify the data, thus it must keep the HASH and the
948 Key Exchange Start Payload saved during SKE and authentication protocols.
950 If the verified signature matches the sent signature, the authentication
951 were successful and SILC_PACKET_SUCCESS is sent. If it failed the protocol
952 execution is stopped and SILC_PACKET_FAILURE is sent.
954 This is required authentication method to be supported by all SILC
959 3.3 Connection Authentication Status Types
961 This section defines all connection authentication status types that
962 may be returned in the SILC_PACKET_SUCCESS or SILC_PACKET_FAILURE packets
963 to indicate the status of the protocol. Implementations may map the
964 status types to human readable error message. All types except the
965 SILC_AUTH_STATUS_OK type must be sent in SILC_PACKET_FAILURE packet.
966 Following status types are defined:
970 Protocol was executed succesfully.
975 Authentication failed.
979 4 Security Considerations
981 Security is central to the design of this protocol, and these security
982 considerations permeate the specification.
988 [SILC1] Riikonen, P., "Secure Internet Live Conferencing (SILC),
989 Protocol Specification", Internet Draft, June 2000.
991 [SILC2] Riikonen, P., "SILC Packet Protocol", Internet Draft,
994 [IRC] Oikarinen, J., and Reed D., "Internet Relay Chat Protocol",
997 [SSH-TRANS] Ylonen, T., et al, "SSH Transport Layer Protocol",
1000 [PGP] Callas, J., et al, "OpenPGP Message Format", RFC 2440,
1003 [SPKI] Ellison C., et al, "SPKI Certificate Theory", RFC 2693,
1006 [PKIX-Part1] Housley, R., et al, "Internet X.509 Public Key
1007 Infrastructure, Certificate and CRL Profile", RFC 2459,
1010 [Schneier] Schneier, B., "Applied Cryptography Second Edition",
1011 John Wiley & Sons, New York, NY, 1996.
1013 [Menezes] Menezes, A., et al, "Handbook of Applied Cryptography",
1016 [OAKLEY] Orman, H., "The OAKLEY Key Determination Protocol",
1017 RFC 2412, November 1998.
1019 [ISAKMP] Maughan D., et al, "Internet Security Association and
1020 Key Management Protocol (ISAKMP)", RFC 2408, November
1023 [IKE] Harkins D., and Carrel D., "The Internet Key Exhange
1024 (IKE)", RFC 2409, November 1998.
1026 [HMAC] Krawczyk, H., "HMAC: Keyed-Hashing for Message
1027 Authentication", RFC 2104, February 1997.
1039 EMail: priikone@poseidon.pspt.fi
1041 This Internet-Draft expires 28 Jan 2001