idnits 2.17.1 draft-ietf-secsh-architecture-15.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** Looks like you're using RFC 2026 boilerplate. This must be updated to follow RFC 3978/3979, as updated by RFC 4748. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- == No 'Intended status' indicated for this document; assuming Proposed Standard == It seems as if not all pages are separated by form feeds - found 0 form feeds but 29 pages Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** There are 3 instances of too long lines in the document, the longest one being 4 characters in excess of 72. ** There are 4 instances of lines with control characters in the document. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the RFC 3978 Section 5.4 Copyright Line does not match the current year == Line 909 has weird spacing: '...er from modif...' == The document seems to lack the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. (The document does seem to have the reference to RFC 2119 which the ID-Checklist requires). -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (Oct 2003) is 7498 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Missing Reference: 'RFC-854' is mentioned on line 180, but not defined == Missing Reference: 'RFC-1282' is mentioned on line 181, but not defined == Missing Reference: 'RFC-894' is mentioned on line 291, but not defined == Missing Reference: 'RFC-1134' is mentioned on line 298, but not defined ** Obsolete undefined reference: RFC 1134 (Obsoleted by RFC 1171) == Missing Reference: 'RFC-2279' is mentioned on line 315, but not defined ** Obsolete undefined reference: RFC 2279 (Obsoleted by RFC 3629) == Missing Reference: 'RFC-3066' is mentioned on line 426, but not defined ** Obsolete undefined reference: RFC 3066 (Obsoleted by RFC 4646, RFC 4647) == Missing Reference: 'RFC-1700' is mentioned on line 354, but not defined ** Obsolete undefined reference: RFC 1700 (Obsoleted by RFC 3232) == Missing Reference: 'RFC-1034' is mentioned on line 464, but not defined == Missing Reference: 'RFC-2343' is mentioned on line 519, but not defined -- Looks like a reference, but probably isn't: '1' on line 693 -- Looks like a reference, but probably isn't: '2' on line 542 -- Looks like a reference, but probably isn't: '3' on line 548 -- Looks like a reference, but probably isn't: '1750' on line 565 == Missing Reference: 'KAUFMAN' is mentioned on line 604, but not defined == Missing Reference: 'PERLMAN' is mentioned on line 604, but not defined == Missing Reference: 'SPECINER' is mentioned on line 604, but not defined == Missing Reference: 'BELLARE' is mentioned on line 616, but not defined == Missing Reference: 'KOHNO' is mentioned on line 616, but not defined == Missing Reference: 'NAMPREMPRE' is mentioned on line 616, but not defined == Missing Reference: 'ARCH' is mentioned on line 771, but not defined == Unused Reference: 'RFC0854' is defined on line 1126, but no explicit reference was found in the text == Unused Reference: 'RFC0894' is defined on line 1129, but no explicit reference was found in the text == Unused Reference: 'RFC1034' is defined on line 1132, but no explicit reference was found in the text == Unused Reference: 'RFC1134' is defined on line 1135, but no explicit reference was found in the text == Unused Reference: 'RFC1282' is defined on line 1139, but no explicit reference was found in the text == Unused Reference: 'RFC1700' is defined on line 1144, but no explicit reference was found in the text == Unused Reference: 'RFC1750' is defined on line 1147, but no explicit reference was found in the text == Unused Reference: 'RFC3066' is defined on line 1150, but no explicit reference was found in the text == Unused Reference: 'RFC2279' is defined on line 1170, but no explicit reference was found in the text == Unused Reference: 'RFC2410' is defined on line 1173, but no explicit reference was found in the text == Unused Reference: 'RFC2434' is defined on line 1176, but no explicit reference was found in the text == Unused Reference: 'KAUFMAN,PERLMAN,SPECINER' is defined on line 1187, but no explicit reference was found in the text == Unused Reference: 'BELLARE,KOHNO,NAMPREMPRE' is defined on line 1208, but no explicit reference was found in the text -- No information found for draft-ietf-architecture - is the name correct? -- Possible downref: Normative reference to a draft: ref. 'SSH-ARCH' -- No information found for draft-ietf-transport - is the name correct? -- Possible downref: Normative reference to a draft: ref. 'SSH-TRANS' -- No information found for draft-ietf-userauth - is the name correct? -- Possible downref: Normative reference to a draft: ref. 'SSH-USERAUTH' -- No information found for draft-ietf-connect - is the name correct? -- Possible downref: Normative reference to a draft: ref. 'SSH-CONNECT' == Outdated reference: A later version (-12) exists of draft-ietf-secsh-assignednumbers-05 -- Obsolete informational reference (is this intentional?): RFC 1134 (Obsoleted by RFC 1171) -- Obsolete informational reference (is this intentional?): RFC 1510 (Obsoleted by RFC 4120, RFC 6649) -- Obsolete informational reference (is this intentional?): RFC 1700 (Obsoleted by RFC 3232) -- Obsolete informational reference (is this intentional?): RFC 1750 (Obsoleted by RFC 4086) -- Obsolete informational reference (is this intentional?): RFC 3066 (Obsoleted by RFC 4646, RFC 4647) -- Obsolete informational reference (is this intentional?): RFC 2246 (Obsoleted by RFC 4346) -- Obsolete informational reference (is this intentional?): RFC 2279 (Obsoleted by RFC 3629) -- Obsolete informational reference (is this intentional?): RFC 2434 (Obsoleted by RFC 5226) Summary: 7 errors (**), 0 flaws (~~), 35 warnings (==), 22 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 Network Working Group T. Ylonen 2 Internet-Draft SSH Communications Security Corp 3 Expires: March 31, 2004 D. Moffat, Ed. 4 Sun Microsystems, Inc 5 Oct 2003 7 SSH Protocol Architecture 8 draft-ietf-secsh-architecture-15.txt 10 Status of this Memo 12 This document is an Internet-Draft and is in full conformance with 13 all provisions of Section 10 of RFC2026. 15 Internet-Drafts are working documents of the Internet Engineering 16 Task Force (IETF), its areas, and its working groups. Note that other 17 groups may also distribute working documents as Internet-Drafts. 19 Internet-Drafts are draft documents valid for a maximum of six months 20 and may be updated, replaced, or obsoleted by other documents at any 21 time. It is inappropriate to use Internet-Drafts as reference 22 material or to cite them other than as "work in progress." 24 The list of current Internet-Drafts can be accessed at http:// 25 www.ietf.org/ietf/1id-abstracts.txt. 27 The list of Internet-Draft Shadow Directories can be accessed at 28 http://www.ietf.org/shadow.html. 30 This Internet-Draft will expire on March 31, 2004. 32 Copyright Notice 34 Copyright (C) The Internet Society (2003). All Rights Reserved. 36 Abstract 38 SSH is a protocol for secure remote login and other secure network 39 services over an insecure network. This document describes the 40 architecture of the SSH protocol, as well as the notation and 41 terminology used in SSH protocol documents. It also discusses the SSH 42 algorithm naming system that allows local extensions. The SSH 43 protocol consists of three major components: The Transport Layer 44 Protocol provides server authentication, confidentiality, and 45 integrity with perfect forward secrecy. The User Authentication 46 Protocol authenticates the client to the server. The Connection 47 Protocol multiplexes the encrypted tunnel into several logical 48 channels. Details of these protocols are described in separate 49 documents. 51 Table of Contents 53 1. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 3 54 2. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 55 3. Specification of Requirements . . . . . . . . . . . . . . . 3 56 4. Architecture . . . . . . . . . . . . . . . . . . . . . . . . 3 57 4.1 Host Keys . . . . . . . . . . . . . . . . . . . . . . . . . 4 58 4.2 Extensibility . . . . . . . . . . . . . . . . . . . . . . . 5 59 4.3 Policy Issues . . . . . . . . . . . . . . . . . . . . . . . 5 60 4.4 Security Properties . . . . . . . . . . . . . . . . . . . . 6 61 4.5 Packet Size and Overhead . . . . . . . . . . . . . . . . . . 6 62 4.6 Localization and Character Set Support . . . . . . . . . . . 7 63 5. Data Type Representations Used in the SSH Protocols . . . . 8 64 6. Algorithm Naming . . . . . . . . . . . . . . . . . . . . . . 10 65 7. Message Numbers . . . . . . . . . . . . . . . . . . . . . . 11 66 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . 11 67 9. Security Considerations . . . . . . . . . . . . . . . . . . 12 68 9.1 Pseudo-Random Number Generation . . . . . . . . . . . . . . 12 69 9.2 Transport . . . . . . . . . . . . . . . . . . . . . . . . . 13 70 9.2.1 Confidentiality . . . . . . . . . . . . . . . . . . . . . . 13 71 9.2.2 Data Integrity . . . . . . . . . . . . . . . . . . . . . . . 16 72 9.2.3 Replay . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 73 9.2.4 Man-in-the-middle . . . . . . . . . . . . . . . . . . . . . 17 74 9.2.5 Denial-of-service . . . . . . . . . . . . . . . . . . . . . 19 75 9.2.6 Covert Channels . . . . . . . . . . . . . . . . . . . . . . 19 76 9.2.7 Forward Secrecy . . . . . . . . . . . . . . . . . . . . . . 20 77 9.3 Authentication Protocol . . . . . . . . . . . . . . . . . . 20 78 9.3.1 Weak Transport . . . . . . . . . . . . . . . . . . . . . . . 21 79 9.3.2 Debug messages . . . . . . . . . . . . . . . . . . . . . . . 21 80 9.3.3 Local security policy . . . . . . . . . . . . . . . . . . . 21 81 9.3.4 Public key authentication . . . . . . . . . . . . . . . . . 22 82 9.3.5 Password authentication . . . . . . . . . . . . . . . . . . 22 83 9.3.6 Host based authentication . . . . . . . . . . . . . . . . . 23 84 9.4 Connection protocol . . . . . . . . . . . . . . . . . . . . 23 85 9.4.1 End point security . . . . . . . . . . . . . . . . . . . . . 23 86 9.4.2 Proxy forwarding . . . . . . . . . . . . . . . . . . . . . . 23 87 9.4.3 X11 forwarding . . . . . . . . . . . . . . . . . . . . . . . 24 88 Normative References . . . . . . . . . . . . . . . . . . . . 24 89 Informative References . . . . . . . . . . . . . . . . . . . 25 90 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . 27 91 Intellectual Property and Copyright Statements . . . . . . . 28 93 1. Contributors 95 The major original contributors of this document were: Tatu Ylonen, 96 Tero Kivinen, Timo J. Rinne, Sami Lehtinen (all of SSH Communications 97 Security Corp), and Markku-Juhani O. Saarinen (University of 98 Jyvaskyla) 100 The document editor is: Darren.Moffat@Sun.COM. Comments on this 101 internet draft should be sent to the IETF SECSH working group, 102 details at: http://ietf.org/html.charters/secsh-charter.html 104 2. Introduction 106 SSH is a protocol for secure remote login and other secure network 107 services over an insecure network. It consists of three major 108 components: 109 o The Transport Layer Protocol [SSH-TRANS] provides server 110 authentication, confidentiality, and integrity. It may optionally 111 also provide compression. The transport layer will typically be 112 run over a TCP/IP connection, but might also be used on top of any 113 other reliable data stream. 114 o The User Authentication Protocol [SSH-USERAUTH] authenticates the 115 client-side user to the server. It runs over the transport layer 116 protocol. 117 o The Connection Protocol [SSH-CONNECT] multiplexes the encrypted 118 tunnel into several logical channels. It runs over the user 119 authentication protocol. 121 The client sends a service request once a secure transport layer 122 connection has been established. A second service request is sent 123 after user authentication is complete. This allows new protocols to 124 be defined and coexist with the protocols listed above. 126 The connection protocol provides channels that can be used for a wide 127 range of purposes. Standard methods are provided for setting up 128 secure interactive shell sessions and for forwarding ("tunneling") 129 arbitrary TCP/IP ports and X11 connections. 131 3. Specification of Requirements 133 All documents related to the SSH protocols shall use the keywords 134 "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", 135 "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" to describe 136 requirements. They are to be interpreted as described in [RFC2119]. 138 4. Architecture 139 4.1 Host Keys 141 Each server host SHOULD have a host key. Hosts MAY have multiple 142 host keys using multiple different algorithms. Multiple hosts MAY 143 share the same host key. If a host has keys at all, it MUST have at 144 least one key using each REQUIRED public key algorithm (DSS 145 [FIPS-186]). 147 The server host key is used during key exchange to verify that the 148 client is really talking to the correct server. For this to be 149 possible, the client must have a priori knowledge of the server's 150 public host key. 152 Two different trust models can be used: 153 o The client has a local database that associates each host name (as 154 typed by the user) with the corresponding public host key. This 155 method requires no centrally administered infrastructure, and no 156 third-party coordination. The downside is that the database of 157 name-to-key associations may become burdensome to maintain. 158 o The host name-to-key association is certified by some trusted 159 certification authority. The client only knows the CA root key, 160 and can verify the validity of all host keys certified by accepted 161 CAs. 163 The second alternative eases the maintenance problem, since 164 ideally only a single CA key needs to be securely stored on the 165 client. On the other hand, each host key must be appropriately 166 certified by a central authority before authorization is possible. 167 Also, a lot of trust is placed on the central infrastructure. 169 The protocol provides the option that the server name - host key 170 association is not checked when connecting to the host for the first 171 time. This allows communication without prior communication of host 172 keys or certification. The connection still provides protection 173 against passive listening; however, it becomes vulnerable to active 174 man-in-the-middle attacks. Implementations SHOULD NOT normally allow 175 such connections by default, as they pose a potential security 176 problem. However, as there is no widely deployed key infrastructure 177 available on the Internet yet, this option makes the protocol much 178 more usable during the transition time until such an infrastructure 179 emerges, while still providing a much higher level of security than 180 that offered by older solutions (e.g. telnet [RFC-854] and rlogin 181 [RFC-1282]). 183 Implementations SHOULD try to make the best effort to check host 184 keys. An example of a possible strategy is to only accept a host key 185 without checking the first time a host is connected, save the key in 186 a local database, and compare against that key on all future 187 connections to that host. 189 Implementations MAY provide additional methods for verifying the 190 correctness of host keys, e.g. a hexadecimal fingerprint derived from 191 the SHA-1 hash of the public key. Such fingerprints can easily be 192 verified by using telephone or other external communication channels. 194 All implementations SHOULD provide an option to not accept host keys 195 that cannot be verified. 197 We believe that ease of use is critical to end-user acceptance of 198 security solutions, and no improvement in security is gained if the 199 new solutions are not used. Thus, providing the option not to check 200 the server host key is believed to improve the overall security of 201 the Internet, even though it reduces the security of the protocol in 202 configurations where it is allowed. 204 4.2 Extensibility 206 We believe that the protocol will evolve over time, and some 207 organizations will want to use their own encryption, authentication 208 and/or key exchange methods. Central registration of all extensions 209 is cumbersome, especially for experimental or classified features. 210 On the other hand, having no central registration leads to conflicts 211 in method identifiers, making interoperability difficult. 213 We have chosen to identify algorithms, methods, formats, and 214 extension protocols with textual names that are of a specific format. 215 DNS names are used to create local namespaces where experimental or 216 classified extensions can be defined without fear of conflicts with 217 other implementations. 219 One design goal has been to keep the base protocol as simple as 220 possible, and to require as few algorithms as possible. However, all 221 implementations MUST support a minimal set of algorithms to ensure 222 interoperability (this does not imply that the local policy on all 223 hosts would necessary allow these algorithms). The mandatory 224 algorithms are specified in the relevant protocol documents. 226 Additional algorithms, methods, formats, and extension protocols can 227 be defined in separate drafts. See Section Algorithm Naming (Section 228 6) for more information. 230 4.3 Policy Issues 232 The protocol allows full negotiation of encryption, integrity, key 233 exchange, compression, and public key algorithms and formats. 234 Encryption, integrity, public key, and compression algorithms can be 235 different for each direction. 237 The following policy issues SHOULD be addressed in the configuration 238 mechanisms of each implementation: 239 o Encryption, integrity, and compression algorithms, separately for 240 each direction. The policy MUST specify which is the preferred 241 algorithm (e.g. the first algorithm listed in each category). 242 o Public key algorithms and key exchange method to be used for host 243 authentication. The existence of trusted host keys for different 244 public key algorithms also affects this choice. 245 o The authentication methods that are to be required by the server 246 for each user. The server's policy MAY require multiple 247 authentication for some or all users. The required algorithms MAY 248 depend on the location where the user is trying to log in from. 249 o The operations that the user is allowed to perform using the 250 connection protocol. Some issues are related to security; for 251 example, the policy SHOULD NOT allow the server to start sessions 252 or run commands on the client machine, and MUST NOT allow 253 connections to the authentication agent unless forwarding such 254 connections has been requested. Other issues, such as which TCP/ 255 IP ports can be forwarded and by whom, are clearly issues of local 256 policy. Many of these issues may involve traversing or bypassing 257 firewalls, and are interrelated with the local security policy. 259 4.4 Security Properties 261 The primary goal of the SSH protocol is improved security on the 262 Internet. It attempts to do this in a way that is easy to deploy, 263 even at the cost of absolute security. 264 o All encryption, integrity, and public key algorithms used are 265 well-known, well-established algorithms. 266 o All algorithms are used with cryptographically sound key sizes 267 that are believed to provide protection against even the strongest 268 cryptanalytic attacks for decades. 269 o All algorithms are negotiated, and in case some algorithm is 270 broken, it is easy to switch to some other algorithm without 271 modifying the base protocol. 273 Specific concessions were made to make wide-spread fast deployment 274 easier. The particular case where this comes up is verifying that 275 the server host key really belongs to the desired host; the protocol 276 allows the verification to be left out (but this is NOT RECOMMENDED). 277 This is believed to significantly improve usability in the short 278 term, until widespread Internet public key infrastructures emerge. 280 4.5 Packet Size and Overhead 282 Some readers will worry about the increase in packet size due to new 283 headers, padding, and MAC. The minimum packet size is in the order 284 of 28 bytes (depending on negotiated algorithms). The increase is 285 negligible for large packets, but very significant for one-byte 286 packets (telnet-type sessions). There are, however, several factors 287 that make this a non-issue in almost all cases: 288 o The minimum size of a TCP/IP header is 32 bytes. Thus, the 289 increase is actually from 33 to 51 bytes (roughly). 290 o The minimum size of the data field of an Ethernet packet is 46 291 bytes [RFC-894]. Thus, the increase is no more than 5 bytes. When 292 Ethernet headers are considered, the increase is less than 10 293 percent. 294 o The total fraction of telnet-type data in the Internet is 295 negligible, even with increased packet sizes. 297 The only environment where the packet size increase is likely to have 298 a significant effect is PPP [RFC-1134] over slow modem lines (PPP 299 compresses the TCP/IP headers, emphasizing the increase in packet 300 size). However, with modern modems, the time needed to transfer is in 301 the order of 2 milliseconds, which is a lot faster than people can 302 type. 304 There are also issues related to the maximum packet size. To 305 minimize delays in screen updates, one does not want excessively 306 large packets for interactive sessions. The maximum packet size is 307 negotiated separately for each channel. 309 4.6 Localization and Character Set Support 311 For the most part, the SSH protocols do not directly pass text that 312 would be displayed to the user. However, there are some places where 313 such data might be passed. When applicable, the character set for the 314 data MUST be explicitly specified. In most places, ISO 10646 with 315 UTF-8 encoding is used [RFC-2279]. When applicable, a field is also 316 provided for a language tag [RFC-3066]. 318 One big issue is the character set of the interactive session. There 319 is no clear solution, as different applications may display data in 320 different formats. Different types of terminal emulation may also be 321 employed in the client, and the character set to be used is 322 effectively determined by the terminal emulation. Thus, no place is 323 provided for directly specifying the character set or encoding for 324 terminal session data. However, the terminal emulation type (e.g. 325 "vt100") is transmitted to the remote site, and it implicitly 326 specifies the character set and encoding. Applications typically use 327 the terminal type to determine what character set they use, or the 328 character set is determined using some external means. The terminal 329 emulation may also allow configuring the default character set. In 330 any case, the character set for the terminal session is considered 331 primarily a client local issue. 333 Internal names used to identify algorithms or protocols are normally 334 never displayed to users, and must be in US-ASCII. 336 The client and server user names are inherently constrained by what 337 the server is prepared to accept. They might, however, occasionally 338 be displayed in logs, reports, etc. They MUST be encoded using ISO 339 10646 UTF-8, but other encodings may be required in some cases. It 340 is up to the server to decide how to map user names to accepted user 341 names. Straight bit-wise binary comparison is RECOMMENDED. 343 For localization purposes, the protocol attempts to minimize the 344 number of textual messages transmitted. When present, such messages 345 typically relate to errors, debugging information, or some externally 346 configured data. For data that is normally displayed, it SHOULD be 347 possible to fetch a localized message instead of the transmitted 348 message by using a numerical code. The remaining messages SHOULD be 349 configurable. 351 5. Data Type Representations Used in the SSH Protocols 352 byte 354 A byte represents an arbitrary 8-bit value (octet) [RFC-1700]. 355 Fixed length data is sometimes represented as an array of bytes, 356 written byte[n], where n is the number of bytes in the array. 358 boolean 360 A boolean value is stored as a single byte. The value 0 361 represents FALSE, and the value 1 represents TRUE. All non-zero 362 values MUST be interpreted as TRUE; however, applications MUST NOT 363 store values other than 0 and 1. 365 uint32 367 Represents a 32-bit unsigned integer. Stored as four bytes in the 368 order of decreasing significance (network byte order). For 369 example, the value 699921578 (0x29b7f4aa) is stored as 29 b7 f4 370 aa. 372 uint64 374 Represents a 64-bit unsigned integer. Stored as eight bytes in 375 the order of decreasing significance (network byte order). 377 string 379 Arbitrary length binary string. Strings are allowed to contain 380 arbitrary binary data, including null characters and 8-bit 381 characters. They are stored as a uint32 containing its length 382 (number of bytes that follow) and zero (= empty string) or more 383 bytes that are the value of the string. Terminating null 384 characters are not used. 386 Strings are also used to store text. In that case, US-ASCII is 387 used for internal names, and ISO-10646 UTF-8 for text that might 388 be displayed to the user. The terminating null character SHOULD 389 NOT normally be stored in the string. 391 For example, the US-ASCII string "testing" is represented as 00 00 392 00 07 t e s t i n g. The UTF8 mapping does not alter the encoding 393 of US-ASCII characters. 395 mpint 397 Represents multiple precision integers in two's complement format, 398 stored as a string, 8 bits per byte, MSB first. Negative numbers 399 have the value 1 as the most significant bit of the first byte of 400 the data partition. If the most significant bit would be set for a 401 positive number, the number MUST be preceded by a zero byte. 402 Unnecessary leading bytes with the value 0 or 255 MUST NOT be 403 included. The value zero MUST be stored as a string with zero 404 bytes of data. 406 By convention, a number that is used in modular computations in 407 Z_n SHOULD be represented in the range 0 <= x < n. 409 Examples: 410 value (hex) representation (hex) 411 --------------------------------------------------------------- 412 0 00 00 00 00 413 9a378f9b2e332a7 00 00 00 08 09 a3 78 f9 b2 e3 32 a7 414 80 00 00 00 02 00 80 415 -1234 00 00 00 02 ed cc 416 -deadbeef 00 00 00 05 ff 21 52 41 11 418 name-list 420 A string containing a comma separated list of names. A name list 421 is represented as a uint32 containing its length (number of bytes 422 that follow) followed by a comma-separated list of zero or more 423 names. A name MUST be non-zero length, and it MUST NOT contain a 424 comma (','). Context may impose additional restrictions on the 425 names; for example, the names in a list may have to be valid 426 algorithm identifier (see Algorithm Naming below), or [RFC-3066] 427 language tags. The order of the names in a list may or may not be 428 significant, also depending on the context where the list is is 429 used. Terminating NUL characters are not used, neither for the 430 individual names, nor for the list as a whole. 432 Examples: 433 value representation (hex) 434 --------------------------------------- 435 (), the empty list 00 00 00 00 436 ("zlib") 00 00 00 04 7a 6c 69 62 437 ("zlib", "none") 00 00 00 09 7a 6c 69 62 2c 6e 6f 6e 65 439 6. Algorithm Naming 441 The SSH protocols refer to particular hash, encryption, integrity, 442 compression, and key exchange algorithms or protocols by names. 443 There are some standard algorithms that all implementations MUST 444 support. There are also algorithms that are defined in the protocol 445 specification but are OPTIONAL. Furthermore, it is expected that 446 some organizations will want to use their own algorithms. 448 In this protocol, all algorithm identifiers MUST be printable 449 US-ASCII non-empty strings no longer than 64 characters. Names MUST 450 be case-sensitive. 452 There are two formats for algorithm names: 453 o Names that do not contain an at-sign (@) are reserved to be 454 assigned by IETF consensus (RFCs). Examples include `3des-cbc', 455 `sha-1', `hmac-sha1', and `zlib' (the quotes are not part of the 456 name). Names of this format MUST NOT be used without first 457 registering them. Registered names MUST NOT contain an at-sign 458 (@) or a comma (,). 459 o Anyone can define additional algorithms by using names in the 460 format name@domainname, e.g. "ourcipher-cbc@example.com". The 461 format of the part preceding the at sign is not specified; it MUST 462 consist of US-ASCII characters except at-sign and comma. The part 463 following the at-sign MUST be a valid fully qualified internet 464 domain name [RFC-1034] controlled by the person or organization 465 defining the name. It is up to each domain how it manages its 466 local namespace. 468 7. Message Numbers 470 SSH packets have message numbers in the range 1 to 255. These numbers 471 have been allocated as follows: 473 Transport layer protocol: 475 1 to 19 Transport layer generic (e.g. disconnect, ignore, debug, 476 etc.) 477 20 to 29 Algorithm negotiation 478 30 to 49 Key exchange method specific (numbers can be reused for 479 different authentication methods) 481 User authentication protocol: 483 50 to 59 User authentication generic 484 60 to 79 User authentication method specific (numbers can be 485 reused for different authentication methods) 487 Connection protocol: 489 80 to 89 Connection protocol generic 490 90 to 127 Channel related messages 492 Reserved for client protocols: 494 128 to 191 Reserved 496 Local extensions: 498 192 to 255 Local extensions 500 8. IANA Considerations 502 The initial state of the IANA registry is detailed in [SSH-NUMBERS]. 504 Allocation of the following types of names in the SSH protocols is 505 assigned by IETF consensus: 506 o SSH encryption algorithm names, 507 o SSH MAC algorithm names, 508 o SSH public key algorithm names (public key algorithm also implies 509 encoding and signature/encryption capability), 510 o SSH key exchange method names, and 511 o SSH protocol (service) names. 513 These names MUST be printable US-ASCII strings, and MUST NOT contain 514 the characters at-sign ('@'), comma (','), or whitespace or control 515 characters (ASCII codes 32 or less). Names are case-sensitive, and 516 MUST NOT be longer than 64 characters. 518 Names with the at-sign ('@') in them are allocated by the owner of 519 DNS name after the at-sign (hierarchical allocation in [RFC-2343]), 520 otherwise the same restrictions as above. 522 Each category of names listed above has a separate namespace. 523 However, using the same name in multiple categories SHOULD be avoided 524 to minimize confusion. 526 Message numbers (see Section Message Numbers (Section 7)) in the 527 range of 0..191 are allocated via IETF consensus; message numbers in 528 the 192..255 range (the "Local extensions" set) are reserved for 529 private use. 531 9. Security Considerations 533 In order to make the entire body of Security Considerations more 534 accessible, Security Considerations for the transport, 535 authentication, and connection documents have been gathered here. 537 The transport protocol [1] provides a confidential channel over an 538 insecure network. It performs server host authentication, key 539 exchange, encryption, and integrity protection. It also derives a 540 unique session id that may be used by higher-level protocols. 542 The authentication protocol [2] provides a suite of mechanisms which 543 can be used to authenticate the client user to the server. 544 Individual mechanisms specified in the in authentication protocol use 545 the session id provided by the transport protocol and/or depend on 546 the security and integrity guarantees of the transport protocol. 548 The connection protocol [3] specifies a mechanism to multiplex 549 multiple streams [channels] of data over the confidential and 550 authenticated transport. It also specifies channels for accessing an 551 interactive shell, for 'proxy-forwarding' various external protocols 552 over the secure transport (including arbitrary TCP/IP protocols), and 553 for accessing secure 'subsystems' on the server host. 555 9.1 Pseudo-Random Number Generation 557 This protocol binds each session key to the session by including 558 random, session specific data in the hash used to produce session 559 keys. Special care should be taken to ensure that all of the random 560 numbers are of good quality. If the random data here (e.g., DH 561 parameters) are pseudo-random then the pseudo-random number generator 562 should be cryptographically secure (i.e., its next output not easily 563 guessed even when knowing all previous outputs) and, furthermore, 564 proper entropy needs to be added to the pseudo-random number 565 generator. RFC 1750 [1750] offers suggestions for sources of random 566 numbers and entropy. Implementors should note the importance of 567 entropy and the well-meant, anecdotal warning about the difficulty in 568 properly implementing pseudo-random number generating functions. 570 The amount of entropy available to a given client or server may 571 sometimes be less than what is required. In this case one must 572 either resort to pseudo-random number generation regardless of 573 insufficient entropy or refuse to run the protocol. The latter is 574 preferable. 576 9.2 Transport 578 9.2.1 Confidentiality 580 It is beyond the scope of this document and the Secure Shell Working 581 Group to analyze or recommend specific ciphers other than the ones 582 which have been established and accepted within the industry. At the 583 time of this writing, ciphers commonly in use include 3DES, ARCFOUR, 584 twofish, serpent and blowfish. AES has been accepted by The 585 published as a US Federal Information Processing Standards [FIPS-197] 586 and the cryptographic community as being acceptable for this purpose 587 as well has accepted AES. As always, implementors and users should 588 check current literature to ensure that no recent vulnerabilities 589 have been found in ciphers used within products. Implementors should 590 also check to see which ciphers are considered to be relatively 591 stronger than others and should recommend their use to users over 592 relatively weaker ciphers. It would be considered good form for an 593 implementation to politely and unobtrusively notify a user that a 594 stronger cipher is available and should be used when a weaker one is 595 actively chosen. 597 The "none" cipher is provided for debugging and SHOULD NOT be used 598 except for that purpose. It's cryptographic properties are 599 sufficiently described in RFC 2410, which will show that its use does 600 not meet the intent of this protocol. 602 The relative merits of these and other ciphers may also be found in 603 current literature. Two references that may provide information on 604 the subject are [SCHNEIER] and [KAUFMAN,PERLMAN,SPECINER]. Both of 605 these describe the CBC mode of operation of certain ciphers and the 606 weakness of this scheme. Essentially, this mode is theoretically 607 vulnerable to chosen cipher-text attacks because of the high 608 predictability of the start of packet sequence. However, this attack 609 is still deemed difficult and not considered fully practicable 610 especially if relatively longer block sizes are used. 612 Additionally, another CBC mode attack may be mitigated through the 613 insertion of packets containing SSH_MSG_IGNORE. Without this 614 technique, a specific attack may be successful. For this attack 615 (commonly known as the Rogaway attack 616 [ROGAWAY],[DAI],[BELLARE,KOHNO,NAMPREMPRE]) to work, the attacker 617 would need to know the IV of the next block that is going to be 618 encrypted. In CBC mode that is the output of the encryption of the 619 previous block. If the attacker does not have any way to see the 620 packet yet (i.e it is in the internal buffers of the ssh 621 implementation or even in the kernel) then this attack will not work. 622 If the last packet has been sent out to the network (i.e the attacker 623 has access to it) then he can use the attack. 625 In the optimal case an implementor would need to add an extra packet 626 only if the packet has been sent out onto the network and there are 627 no other packets waiting for transmission. Implementors may wish to 628 check to see if there are any unsent packets awaiting transmission, 629 but unfortunately it is not normally easy to obtain this information 630 from the kernel or buffers. If there are not, then a packet 631 containing SSH_MSG_IGNORE SHOULD be sent. If a new packet is added 632 to the stream every time the attacker knows the IV that is supposed 633 to be used for the next packet, then the attacker will not be able to 634 guess the correct IV, thus the attack will never be successfull. 636 As an example, consider the following case: 638 Client Server 639 ------ ------ 640 TCP(seq=x, len=500) -> 641 contains Record 1 643 [500 ms passes, no ACK] 645 TCP(seq=x, len=1000) -> 646 contains Records 1,2 648 ACK 650 1. The Nagle algorithm + TCP retransmits mean that the two records 651 get coalesced into a single TCP segment 652 2. Record 2 is *not* at the beginning of the TCP segment and never 653 will be, since it gets ACKed. 655 3. Yet, the attack is possible because Record 1 has already been 656 seen. 658 As this example indicates, it's totally unsafe to use the existence 659 of unflushed data in the TCP buffers proper as a guide to whether you 660 need an empty packet, since when you do the second write(), the 661 buffers will contain the un-ACKed Record 1. 663 On the other hand, it's perfectly safe to have the following 664 situation: 666 Client Server 667 ------ ------ 668 TCP(seq=x, len=500) -> 669 contains SSH_MSG_IGNORE 671 TCP(seq=y, len=500) -> 672 contains Data 674 Provided that the IV for second SSH Record is fixed after the data for 675 the Data packet is determined -i.e. you do: 676 read from user 677 encrypt null packet 678 encrypt data packet 680 9.2.2 Data Integrity 682 This protocol does allow the Data Integrity mechanism to be disabled. 683 Implementors SHOULD be wary of exposing this feature for any purpose 684 other than debugging. Users and administrators SHOULD be explicitly 685 warned anytime the "none" MAC is enabled. 687 So long as the "none" MAC is not used, this protocol provides data 688 integrity. 690 Because MACs use a 32 bit sequence number, they might start to leak 691 information after 2**32 packets have been sent. However, following 692 the rekeying recommendations should prevent this attack. The 693 transport protocol [1] recommends rekeying after one gigabyte of 694 data, and the smallest possible packet is 16 bytes. Therefore, 695 rekeying SHOULD happen after 2**28 packets at the very most. 697 9.2.3 Replay 699 The use of a MAC other than 'none' provides integrity and 700 authentication. In addition, the transport protocol provides a 701 unique session identifier (bound in part to pseudo-random data that 702 is part of the algorithm and key exchange process) that can be used 703 by higher level protocols to bind data to a given session and prevent 704 replay of data from prior sessions. For example, the authentication 705 protocol uses this to prevent replay of signatures from previous 706 sessions. Because public key authentication exchanges are 707 cryptographically bound to the session (i.e., to the initial key 708 exchange) they cannot be successfully replayed in other sessions. 710 Note that the session ID can be made public without harming the 711 security of the protocol. 713 If two session happen to have the same session ID [hash of key 714 exchanges] then packets from one can be replayed against the other. 715 It must be stressed that the chances of such an occurrence are, 716 needless to say, minimal when using modern cryptographic methods. 717 This is all the more so true when specifying larger hash function 718 outputs and DH parameters. 720 Replay detection using monotonically increasing sequence numbers as 721 input to the MAC, or HMAC in some cases, is described in [RFC2085] /> 722 [RFC2246], [RFC2743], [RFC1964], [RFC2025], and [RFC1510]. The 723 underlying construct is discussed in [RFC2104]. Essentially a 724 different sequence number in each packet ensures that at least this 725 one input to the MAC function will be unique and will provide a 726 nonrecurring MAC output that is not predictable to an attacker. If 727 the session stays active long enough, however, this sequence number 728 will wrap. This event may provide an attacker an opportunity to 729 replay a previously recorded packet with an identical sequence number 730 but only if the peers have not rekeyed since the transmission of the 731 first packet with that sequence number. If the peers have rekeyed, 732 then the replay will be detected as the MAC check will fail. For 733 this reason, it must be emphasized that peers MUST rekey before a 734 wrap of the sequence numbers. Naturally, if an attacker does attempt 735 to replay a captured packet before the peers have rekeyed, then the 736 receiver of the duplicate packet will not be able to validate the MAC 737 and it will be discarded. The reason that the MAC will fail is 738 because the receiver will formulate a MAC based upon the packet 739 contents, the shared secret, and the expected sequence number. Since 740 the replayed packet will not be using that expected sequence number 741 (the sequence number of the replayed packet will have already been 742 passed by the receiver) then the calculated MAC will not match the 743 MAC received with the packet. 745 9.2.4 Man-in-the-middle 747 This protocol makes no assumptions nor provisions for an 748 infrastructure or means for distributing the public keys of hosts. It 749 is expected that this protocol will sometimes be used without first 750 verifying the association between the server host key and the server 751 host name. Such usage is vulnerable to man-in-the-middle attacks. 752 This section describes this and encourages administrators and users 753 to understand the importance of verifying this association before any 754 session is initiated. 756 There are three cases of man-in-the-middle attacks to consider. The 757 first is where an attacker places a device between the client and the 758 server before the session is initiated. In this case, the attack 759 device is trying to mimic the legitimate server and will offer its 760 public key to the client when the client initiates a session. If it 761 were to offer the public key of the server, then it would not be able 762 to decrypt or sign the transmissions between the legitimate server 763 and the client unless it also had access to the private-key of the 764 host. The attack device will also, simultaneously to this, initiate 765 a session to the legitimate server masquerading itself as the client. 766 If the public key of the server had been securely distributed to the 767 client prior to that session initiation, the key offered to the 768 client by the attack device will not match the key stored on the 769 client. In that case, the user SHOULD be given a warning that the 770 offered host key does not match the host key cached on the client. 771 As described in Section 3.1 of [ARCH], the user may be free to accept 772 the new key and continue the session. It is RECOMMENDED that the 773 warning provide sufficient information to the user of the client 774 device so they may make an informed decision. If the user chooses to 775 continue the session with the stored public-key of the server (not 776 the public-key offered at the start of the session), then the session 777 specific data between the attacker and server will be different 778 between the client-to-attacker session and the attacker-to-server 779 sessions due to the randomness discussed above. From this, the 780 attacker will not be able to make this attack work since the attacker 781 will not be able to correctly sign packets containing this session 782 specific data from the server since he does not have the private key 783 of that server. 785 The second case that should be considered is similar to the first 786 case in that it also happens at the time of connection but this case 787 points out the need for the secure distribution of server public 788 keys. If the server public keys are not securely distributed then 789 the client cannot know if it is talking to the intended server. An 790 attacker may use social engineering techniques to pass off server 791 keys to unsuspecting users and may then place a man-in-the-middle 792 attack device between the legitimate server and the clients. If this 793 is allowed to happen then the clients will form client-to-attacker 794 sessions and the attacker will form attacker-to-server sessions and 795 will be able to monitor and manipulate all of the traffic between the 796 clients and the legitimate servers. Server administrators are 797 encouraged to make host key fingerprints available for checking by 798 some means whose security does not rely on the integrity of the 799 actual host keys. Possible mechanisms are discussed in Section 3.1 800 of [SSH-ARCH] and may also include secured Web pages, physical pieces 801 of paper, etc. Implementors SHOULD provide recommendations on how 802 best to do this with their implementation. Because the protocol is 803 extensible, future extensions to the protocol may provide better 804 mechanisms for dealing with the need to know the server's host key 805 before connecting. For example, making the host key fingerprint 806 available through a secure DNS lookup, or using kerberos over gssapi 807 during key exchange to authenticate the server are possibilities. 809 In the third man-in-the-middle case, attackers may attempt to 810 manipulate packets in transit between peers after the session has 811 been established. As described in the Replay part of this section, a 812 successful attack of this nature is very improbable. As in the 813 Replay section, this reasoning does assume that the MAC is secure and 814 that it is infeasible to construct inputs to a MAC algorithm to give 815 a known output. This is discussed in much greater detail in Section 816 6 of RFC 2104. If the MAC algorithm has a vulnerability or is weak 817 enough, then the attacker may be able to specify certain inputs to 818 yield a known MAC. With that they may be able to alter the contents 819 of a packet in transit. Alternatively the attacker may be able to 820 exploit the algorithm vulnerability or weakness to find the shared 821 secret by reviewing the MACs from captured packets. In either of 822 those cases, an attacker could construct a packet or packets that 823 could be inserted into an SSH stream. To prevent that, implementors 824 are encouraged to utilize commonly accepted MAC algorithms and 825 administrators are encouraged to watch current literature and 826 discussions of cryptography to ensure that they are not using a MAC 827 algorithm that has a recently found vulnerability or weakness. 829 In summary, the use of this protocol without a reliable association 830 of the binding between a host and its host keys is inherently 831 insecure and is NOT RECOMMENDED. It may however be necessary in 832 non-security critical environments, and will still provide protection 833 against passive attacks. Implementors of protocols and applications 834 running on top of this protocol should keep this possibility in mind. 836 9.2.5 Denial-of-service 838 This protocol is designed to be used over a reliable transport. If 839 transmission errors or message manipulation occur, the connection is 840 closed. The connection SHOULD be re-established if this occurs. 841 Denial of service attacks of this type ("wire cutter") are almost 842 impossible to avoid. 844 In addition, this protocol is vulnerable to Denial of Service attacks 845 because an attacker can force the server to go through the CPU and 846 memory intensive tasks of connection setup and key exchange without 847 authenticating. Implementors SHOULD provide features that make this 848 more difficult. For example, only allowing connections from a subset 849 of IPs known to have valid users. 851 9.2.6 Covert Channels 853 The protocol was not designed to eliminate covert channels. For 854 example, the padding, SSH_MSG_IGNORE messages, and several other 855 places in the protocol can be used to pass covert information, and 856 the recipient has no reliable way to verify whether such information 857 is being sent. 859 9.2.7 Forward Secrecy 861 It should be noted that the Diffie-Hellman key exchanges may provide 862 perfect forward secrecy (PFS). PFS is essentially defined as the 863 cryptographic property of a key-establishment protocol in which the 864 compromise of a session key or long-term private key after a given 865 session does not cause the compromise of any earlier session. [ANSI 866 T1.523-2001] SSHv2 sessions resulting from a key exchange using 867 diffie-hellman-group1-sha1 are secure even if private keying/ 868 authentication material is later revealed, but not if the session 869 keys are revealed. So, given this definition of PFS, SSHv2 does have 870 PFS. It is hoped that all other key exchange mechanisms proposed and 871 used in the future will also provide PFS. This property is not 872 commuted to any of the applications or protocols using SSH as a 873 transport however. The transport layer of SSH provides 874 confidentiality for password authentication and other methods that 875 rely on secret data. 877 Of course, if the DH private parameters for the client and server are 878 revealed then the session key is revealed, but these items can be 879 thrown away after the key exchange completes. It's worth pointing 880 out that these items should not be allowed to end up on swap space 881 and that they should be erased from memory as soon as the key 882 exchange completes. 884 9.3 Authentication Protocol 886 The purpose of this protocol is to perform client user 887 authentication. It assumes that this run over a secure transport 888 layer protocol, which has already authenticated the server machine, 889 established an encrypted communications channel, and computed a 890 unique session identifier for this session. 892 Several authentication methods with different security 893 characteristics are allowed. It is up to the server's local policy 894 to decide which methods (or combinations of methods) it is willing to 895 accept for each user. Authentication is no stronger than the weakest 896 combination allowed. 898 The server may go into a "sleep" period after repeated unsuccessful 899 authentication attempts to make key search more difficult for 900 attackers. Care should be taken so that this doesn't become a 901 self-denial of service vector. 903 9.3.1 Weak Transport 905 If the transport layer does not provide confidentiality, 906 authentication methods that rely on secret data SHOULD be disabled. 907 If it does not provide strong integrity protection, requests to 908 change authentication data (e.g. a password change) SHOULD be 909 disabled to prevent an attacker from modifying the ciphertext 910 without being noticed, or rendering the new authentication data 911 unusable (denial of service). 913 The assumption as stated above that the Authentication Protocol only 914 run over a secure transport that has previously authenticated the 915 server is very important to note. People deploying SSH are reminded 916 of the consequences of man-in-the-middle attacks if the client does 917 not have a very strong a priori association of the server with the 918 host key of that server. Specifically for the case of the 919 Authentication Protocol the client may form a session to a 920 man-in-the-middle attack device and divulge user credentials such as 921 their username and password. Even in the cases of authentication 922 where no user credentials are divulged, an attacker may still gain 923 information they shouldn't have by capturing key-strokes in much the 924 same way that a honeypot works. 926 9.3.2 Debug messages 928 Special care should be taken when designing debug messages. These 929 messages may reveal surprising amounts of information about the host 930 if not properly designed. Debug messages can be disabled (during 931 user authentication phase) if high security is required. 932 Administrators of host machines should make all attempts to 933 compartmentalize all event notification messages and protect them 934 from unwarranted observation. Developers should be aware of the 935 sensitive nature of some of the normal event messages and debug 936 messages and may want to provide guidance to administrators on ways 937 to keep this information away from unauthorized people. Developers 938 should consider minimizing the amount of sensitive information 939 obtainable by users during the authentication phase in accordance 940 with the local policies. For this reason, it is RECOMMENDED that 941 debug messages be initially disabled at the time of deployment and 942 require an active decision by an administrator to allow them to be 943 enabled. It is also RECOMMENDED that a message expressing this 944 concern be presented to the administrator of a system when the action 945 is taken to enable debugging messages. 947 9.3.3 Local security policy 949 Implementer MUST ensure that the credentials provided validate the 950 professed user and also MUST ensure that the local policy of the 951 server permits the user the access requested. In particular, because 952 of the flexible nature of the SSH connection protocol, it may not be 953 possible to determine the local security policy, if any, that should 954 apply at the time of authentication because the kind of service being 955 requested is not clear at that instant. For example, local policy 956 might allow a user to access files on the server, but not start an 957 interactive shell. However, during the authentication protocol, it is 958 not known whether the user will be accessing files or attempting to 959 use an interactive shell, or even both. In any event, where local 960 security policy for the server host exists, it MUST be applied and 961 enforced correctly. 963 Implementors are encouraged to provide a default local policy and 964 make its parameters known to administrators and users. At the 965 discretion of the implementors, this default policy may be along the 966 lines of 'anything goes' where there are no restrictions placed upon 967 users, or it may be along the lines of 'excessively restrictive' in 968 which case the administrators will have to actively make changes to 969 this policy to meet their needs. Alternatively, it may be some 970 attempt at providing something practical and immediately useful to 971 the administrators of the system so they don't have to put in much 972 effort to get SSH working. Whatever choice is made MUST be applied 973 and enforced as required above. 975 9.3.4 Public key authentication 977 The use of public-key authentication assumes that the client host has 978 not been compromised. It also assumes that the private-key of the 979 server host has not been compromised. 981 This risk can be mitigated by the use of passphrases on private keys; 982 however, this is not an enforceable policy. The use of smartcards, 983 or other technology to make passphrases an enforceable policy is 984 suggested. 986 The server could require both password and public-key authentication, 987 however, this requires the client to expose its password to the 988 server (see section on password authentication below.) 990 9.3.5 Password authentication 992 The password mechanism as specified in the authentication protocol 993 assumes that the server has not been compromised. If the server has 994 been compromised, using password authentication will reveal a valid 995 username / password combination to the attacker, which may lead to 996 further compromises. 998 This vulnerability can be mitigated by using an alternative form of 999 authentication. For example, public-key authentication makes no 1000 assumptions about security on the server. 1002 9.3.6 Host based authentication 1004 Host based authentication assumes that the client has not been 1005 compromised. There are no mitigating strategies, other than to use 1006 host based authentication in combination with another authentication 1007 method. 1009 9.4 Connection protocol 1011 9.4.1 End point security 1013 End point security is assumed by the connection protocol. If the 1014 server has been compromised, any terminal sessions, port forwarding, 1015 or systems accessed on the host are compromised. There are no 1016 mitigating factors for this. 1018 If the client end point has been compromised, and the server fails to 1019 stop the attacker at the authentication protocol, all services 1020 exposed (either as subsystems or through forwarding) will be 1021 vulnerable to attack. Implementors SHOULD provide mechanisms for 1022 administrators to control which services are exposed to limit the 1023 vulnerability of other services. 1025 These controls might include controlling which machines and ports can 1026 be target in 'port-forwarding' operations, which users are allowed to 1027 use interactive shell facilities, or which users are allowed to use 1028 exposed subsystems. 1030 9.4.2 Proxy forwarding 1032 The SSH connection protocol allows for proxy forwarding of other 1033 protocols such as SNMP, POP3, and HTTP. This may be a concern for 1034 network administrators who wish to control the access of certain 1035 applications by users located outside of their physical location. 1036 Essentially, the forwarding of these protocols may violate site 1037 specific security policies as they may be undetectably tunneled 1038 through a firewall. Implementors SHOULD provide an administrative 1039 mechanism to control the proxy forwarding functionality so that site 1040 specific security policies may be upheld. 1042 In addition, a reverse proxy forwarding functionality is available, 1043 which again can be used to bypass firewall controls. 1045 As indicated above, end-point security is assumed during proxy 1046 forwarding operations. Failure of end-point security will compromise 1047 all data passed over proxy forwarding. 1049 9.4.3 X11 forwarding 1051 Another form of proxy forwarding provided by the ssh connection 1052 protocol is the forwarding of the X11 protocol. If end-point 1053 security has been compromised, X11 forwarding may allow attacks 1054 against the X11 server. Users and administrators should, as a matter 1055 of course, use appropriate X11 security mechanisms to prevent 1056 unauthorized use of the X11 server. Implementors, administrators and 1057 users who wish to further explore the security mechanisms of X11 are 1058 invited to read [SCHEIFLER] and analyze previously reported problems 1059 with the interactions between SSH forwarding and X11 in CERT 1060 vulnerabilities VU#363181 and VU#118892 [CERT]. 1062 X11 display forwarding with SSH, by itself, is not sufficient to 1063 correct well known problems with X11 security [VENEMA]. However, X11 1064 display forwarding in SSHv2 (or other, secure protocols), combined 1065 with actual and pseudo-displays which accept connections only over 1066 local IPC mechanisms authorized by permissions or ACLs, does correct 1067 many X11 security problems as long as the "none" MAC is not used. It 1068 is RECOMMENDED that X11 display implementations default to allowing 1069 display opens only over local IPC. It is RECOMMENDED that SSHv2 1070 server implementations that support X11 forwarding default to 1071 allowing display opens only over local IPC. On single-user systems 1072 it might be reasonable to default to allowing local display opens 1073 over TCP/IP. 1075 Implementors of the X11 forwarding protocol SHOULD implement the 1076 magic cookie access checking spoofing mechanism as described in 1077 [ssh-connect] as an additional mechanism to prevent unauthorized use 1078 of the proxy. 1080 Normative References 1082 [SSH-ARCH] 1083 Ylonen, T., "SSH Protocol Architecture", I-D 1084 draft-ietf-architecture-15.txt, Oct 2003. 1086 [SSH-TRANS] 1087 Ylonen, T., "SSH Transport Layer Protocol", I-D 1088 draft-ietf-transport-17.txt, Oct 2003. 1090 [SSH-USERAUTH] 1091 Ylonen, T., "SSH Authentication Protocol", I-D 1092 draft-ietf-userauth-18.txt, Oct 2003. 1094 [SSH-CONNECT] 1095 Ylonen, T., "SSH Connection Protocol", I-D 1096 draft-ietf-connect-18.txt, Oct 2003. 1098 [SSH-NUMBERS] 1099 Lehtinen, S. and D. Moffat, "SSH Protocol Assigned 1100 Numbers", I-D draft-ietf-secsh-assignednumbers-05.txt, Oct 1101 2003. 1103 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1104 Requirement Levels", BCP 14, RFC 2119, March 1997. 1106 Informative References 1108 [FIPS-186] 1109 Federal Information Processing Standards Publication, 1110 "FIPS PUB 186, Digital Signature Standard", May 1994. 1112 [FIPS-197] 1113 National Institue of Standards and Technology, "FIPS 197, 1114 Specification for the Advanced Encryption Standard", 1115 November 2001. 1117 [ANSI T1.523-2001] 1118 American National Standards Insitute, Inc., "Telecom 1119 Glossary 2000", February 2001. 1121 [SCHEIFLER] 1122 Scheifler, R., "X Window System : The Complete Reference 1123 to Xlib, X Protocol, Icccm, Xlfd, 3rd edition.", Digital 1124 Press ISBN 1555580882, Feburary 1992. 1126 [RFC0854] Postel, J. and J. Reynolds, "Telnet Protocol 1127 Specification", STD 8, RFC 854, May 1983. 1129 [RFC0894] Hornig, C., "Standard for the transmission of IP datagrams 1130 over Ethernet networks", STD 41, RFC 894, April 1984. 1132 [RFC1034] Mockapetris, P., "Domain names - concepts and facilities", 1133 STD 13, RFC 1034, November 1987. 1135 [RFC1134] Perkins, D., "Point-to-Point Protocol: A proposal for 1136 multi-protocol transmission of datagrams over 1137 Point-to-Point links", RFC 1134, November 1989. 1139 [RFC1282] Kantor, B., "BSD Rlogin", RFC 1282, December 1991. 1141 [RFC1510] Kohl, J. and B. Neuman, "The Kerberos Network 1142 Authentication Service (V5)", RFC 1510, September 1993. 1144 [RFC1700] Reynolds, J. and J. Postel, "Assigned Numbers", RFC 1700, 1145 October 1994. 1147 [RFC1750] Eastlake, D., Crocker, S. and J. Schiller, "Randomness 1148 Recommendations for Security", RFC 1750, December 1994. 1150 [RFC3066] Alvestrand, H., "Tags for the Identification of 1151 Languages", BCP 47, RFC 3066, January 2001. 1153 [RFC1964] Linn, J., "The Kerberos Version 5 GSS-API Mechanism", RFC 1154 1964, June 1996. 1156 [RFC2025] Adams, C., "The Simple Public-Key GSS-API Mechanism 1157 (SPKM)", RFC 2025, October 1996. 1159 [RFC2085] Oehler, M. and R. Glenn, "HMAC-MD5 IP Authentication with 1160 Replay Prevention", RFC 2085, February 1997. 1162 [RFC2104] Krawczyk, H., Bellare, M. and R. Canetti, "HMAC: 1163 Keyed-Hashing for Message Authentication", RFC 2104, 1164 February 1997. 1166 [RFC2246] Dierks, T., Allen, C., Treese, W., Karlton, P., Freier, A. 1167 and P. Kocher, "The TLS Protocol Version 1.0", RFC 2246, 1168 January 1999. 1170 [RFC2279] Yergeau, F., "UTF-8, a transformation format of ISO 1171 10646", RFC 2279, January 1998. 1173 [RFC2410] Glenn, R. and S. Kent, "The NULL Encryption Algorithm and 1174 Its Use With IPsec", RFC 2410, November 1998. 1176 [RFC2434] Narten, T. and H. Alvestrand, "Guidelines for Writing an 1177 IANA Considerations Section in RFCs", BCP 26, RFC 2434, 1178 October 1998. 1180 [RFC2743] Linn, J., "Generic Security Service Application Program 1181 Interface Version 2, Update 1", RFC 2743, January 2000. 1183 [SCHNEIER] 1184 Schneier, B., "Applied Cryptography Second Edition: 1185 protocols algorithms and source in code in C", 1996. 1187 [KAUFMAN,PERLMAN,SPECINER] 1188 Kaufman, C., Perlman, R. and M. Speciner, "Network 1189 Security: PRIVATE Communication in a PUBLIC World", 1995. 1191 [CERT] CERT Coordination Center, The., "http://www.cert.org/nav/ 1192 index_red.html". 1194 [VENEMA] Venema, W., "Murphy's Law and Computer Security", 1195 Proceedings of 6th USENIX Security Symposium, San Jose CA 1196 http://www.usenix.org/publications/library/proceedings/ 1197 sec96/venema.html, July 1996. 1199 [ROGAWAY] Rogaway, P., "Problems with Proposed IP Cryptography", 1200 Unpublished paper http://www.cs.ucdavis.edu/~rogaway/ 1201 papers/draft-rogaway-ipsec-comments-00.txt, 1996. 1203 [DAI] Dai, W., "An attack against SSH2 protocol", Email to the 1204 SECSH Working Group ietf-ssh@netbsd.org ftp:// 1205 ftp.ietf.org/ietf-mail-archive/secsh/2002-02.mail, Feb 1206 2002. 1208 [BELLARE,KOHNO,NAMPREMPRE] 1209 Bellaire, M., Kohno, T. and C. Namprempre, "Authenticated 1210 Encryption in SSH: Fixing the SSH Binary Packet Protocol", 1211 , Sept 2002. 1213 Authors' Addresses 1215 Tatu Ylonen 1216 SSH Communications Security Corp 1217 Fredrikinkatu 42 1218 HELSINKI FIN-00100 1219 Finland 1221 EMail: ylo@ssh.com 1223 Darren J. Moffat (editor) 1224 Sun Microsystems, Inc 1225 17 Network Circle 1226 Menlo Park CA 94025 1227 USA 1229 EMail: Darren.Moffat@Sun.COM 1231 Intellectual Property Statement 1233 The IETF takes no position regarding the validity or scope of any 1234 intellectual property or other rights that might be claimed to 1235 pertain to the implementation or use of the technology described in 1236 this document or the extent to which any license under such rights 1237 might or might not be available; neither does it represent that it 1238 has made any effort to identify any such rights. Information on the 1239 IETF's procedures with respect to rights in standards-track and 1240 standards-related documentation can be found in BCP-11. Copies of 1241 claims of rights made available for publication and any assurances of 1242 licenses to be made available, or the result of an attempt made to 1243 obtain a general license or permission for the use of such 1244 proprietary rights by implementors or users of this specification can 1245 be obtained from the IETF Secretariat. 1247 The IETF invites any interested party to bring to its attention any 1248 copyrights, patents or patent applications, or other proprietary 1249 rights which may cover technology that may be required to practice 1250 this standard. Please address the information to the IETF Executive 1251 Director. 1253 The IETF has been notified of intellectual property rights claimed in 1254 regard to some or all of the specification contained in this 1255 document. For more information consult the online list of claimed 1256 rights. 1258 Full Copyright Statement 1260 Copyright (C) The Internet Society (2003). All Rights Reserved. 1262 This document and translations of it may be copied and furnished to 1263 others, and derivative works that comment on or otherwise explain it 1264 or assist in its implementation may be prepared, copied, published 1265 and distributed, in whole or in part, without restriction of any 1266 kind, provided that the above copyright notice and this paragraph are 1267 included on all such copies and derivative works. However, this 1268 document itself may not be modified in any way, such as by removing 1269 the copyright notice or references to the Internet Society or other 1270 Internet organizations, except as needed for the purpose of 1271 developing Internet standards in which case the procedures for 1272 copyrights defined in the Internet Standards process must be 1273 followed, or as required to translate it into languages other than 1274 English. 1276 The limited permissions granted above are perpetual and will not be 1277 revoked by the Internet Society or its successors or assignees. 1279 This document and the information contained herein is provided on an 1280 "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING 1281 TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING 1282 BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION 1283 HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF 1284 MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 1286 Acknowledgment 1288 Funding for the RFC Editor function is currently provided by the 1289 Internet Society.