draft-ietf-sasl-rfc2222bis-03.txt   draft-ietf-sasl-rfc2222bis-04.txt 
Network Working Group A. Melnikov Network Working Group A. Melnikov
Internet Draft Editor Internet Draft Editor
Document: draft-ietf-sasl-rfc2222bis-03.txt October 2003 Document: draft-ietf-sasl-rfc2222bis-04.txt December 2003
Expires in six months Obsoletes: RFC 2222 Expires in six months
Simple Authentication and Security Layer (SASL) Simple Authentication and Security Layer (SASL)
Status of this Memo Status of this Memo
This document is an Internet Draft and is in full conformance with This document is an Internet Draft and is in full conformance with
all provisions of Section 10 of RFC 2026. all provisions of Section 10 of RFC 2026.
Internet Drafts are working documents of the Internet Engineering Internet Drafts are working documents of the Internet Engineering
Task Force (IETF), its Areas, and its Working Groups. Note that Task Force (IETF), its Areas, and its Working Groups. Note that
skipping to change at page 2, line ? skipping to change at page 2, line ?
The list of Internet-Draft Shadow Directories can be accessed at The list of Internet-Draft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html. http://www.ietf.org/shadow.html.
A revised version of this draft document will be submitted to the RFC A revised version of this draft document will be submitted to the RFC
editor as a Draft Standard for the Internet Community. Discussion editor as a Draft Standard for the Internet Community. Discussion
and suggestions for improvement are requested. Distribution of this and suggestions for improvement are requested. Distribution of this
draft is unlimited. draft is unlimited.
When published as an RFC this document will obsolete RFC 2222. When published as an RFC this document will obsolete RFC 2222.
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
1. Abstract 1. Abstract
The Simple Authentication and Security Layer (SASL) provides a method The Simple Authentication and Security Layer (SASL) provides a method
for adding authentication support with an optional security layer to for adding authentication support with an optional security layer to
connection-based protocols. It also describes a structure for connection-based protocols. It also describes a structure for
authentication mechanisms. The result is an abstraction layer authentication mechanisms. The result is an abstraction layer
between protocols and authentication mechanisms such that any SASL- between protocols and authentication mechanisms such that any SASL-
compatible authentication mechanism can be used with any SASL- compatible authentication mechanism can be used with any SASL-
compatible protocol. compatible protocol.
skipping to change at page 3, line 5 skipping to change at page 2, line ?
server respectively. server respectively.
The key words "MUST", "MUST NOT", "SHOULD", "SHOULD NOT", and "MAY" The key words "MUST", "MUST NOT", "SHOULD", "SHOULD NOT", and "MAY"
in this document are to be interpreted as defined in "Key words for in this document are to be interpreted as defined in "Key words for
use in RFCs to Indicate Requirement Levels" [KEYWORDS]. use in RFCs to Indicate Requirement Levels" [KEYWORDS].
Character names in this document use the notation for code points and Character names in this document use the notation for code points and
names from the Unicode Standard [Unicode]. For example, the letter names from the Unicode Standard [Unicode]. For example, the letter
"a" may be represented as either <U+0061> or <LATIN SMALL LETTER A>. "a" may be represented as either <U+0061> or <LATIN SMALL LETTER A>.
Internet DRAFT SASL 18 October 2003 This document uses terms "integrity protection" and "confidentiality
Internet DRAFT SASL 21 December 2003
protection". The former references to a security layer, that is able
to detect data modification by using some kind of hash. However,
integrity protection doesn't make the data unreadable to an attacker.
Confidentiality protection is a security layer, that is able to make
the data unreadable to an attacker by using encryption.
Confidentiality protection usually implies integrity protection.
3. Overview 3. Overview
The Simple Authentication and Security Layer (SASL) is a method for The Simple Authentication and Security Layer (SASL) is a method for
adding authentication support to connection-based protocols. adding authentication support to connection-based protocols.
The SASL specification has three layers, as indicated in the diagram The SASL specification has three layers, as indicated in the diagram
below. At the top, a protocol definition using SASL specifies a below. At the top, a protocol definition using SASL specifies a
profile, including a command for identifying and authenticating a profile, including a command for identifying and authenticating a
user to a server and for optionally negotiating a security layer for user to a server and for optionally negotiating a security layer for
skipping to change at page 3, line 47 skipping to change at page 4, line 4
4. Authentication mechanisms 4. Authentication mechanisms
SASL mechanisms are named by strings, from 1 to 20 characters in SASL mechanisms are named by strings, from 1 to 20 characters in
length, consisting of upper-case ASCII [ASCII] letters, digits, length, consisting of upper-case ASCII [ASCII] letters, digits,
hyphens, and/or underscores. SASL mechanism names must be registered hyphens, and/or underscores. SASL mechanism names must be registered
with the Internet Assigned Numbers Authority (IANA). IETF standards with the Internet Assigned Numbers Authority (IANA). IETF standards
track documents may direct the IANA to reserve a portion of the SASL track documents may direct the IANA to reserve a portion of the SASL
mechanism namespace and may specify different registration criteria mechanism namespace and may specify different registration criteria
for the reserved portion; the GSSAPI mechanism specification [SASL- for the reserved portion; the GSSAPI mechanism specification [SASL-
Internet DRAFT SASL 21 December 2003
GSSAPI] does this. Procedures for registering new SASL mechanisms are GSSAPI] does this. Procedures for registering new SASL mechanisms are
given in the section 8. given in the section 8.
The "sasl-mech" rule below defines the syntax of a SASL mechanism The "sasl-mech" rule below defines the syntax of a SASL mechanism
name. This uses the Augmented Backus-Naur Form (ABNF) notation as name. This uses the Augmented Backus-Naur Form (ABNF) notation as
specified in [ABNF] and the ABNF core rules as specified in Appendix specified in [ABNF] and the ABNF core rules as specified in Appendix
A of the ABNF specification [ABNF]. A of the ABNF specification [ABNF].
Internet DRAFT SASL 18 October 2003
sasl-mech = 1*20mech-char sasl-mech = 1*20mech-char
mech-char = %x41-5A / DIGIT / "-" / "_" mech-char = %x41-5A / DIGIT / "-" / "_"
; mech names restricted to uppercase ASCII letters, ; mech names restricted to uppercase ASCII letters,
; digits, "-" and "_" ; digits, "-" and "_"
4.1. Authentication protocol exchange 4.1. Authentication protocol exchange
A SASL mechanism is responsible for conducting an authentication A SASL mechanism is responsible for conducting an authentication
protocol exchange. This consists of a series of server challenges protocol exchange. This consists of a series of server challenges
and client responses, the contents of which are specific to and and client responses, the contents of which are specific to and
skipping to change at page 4, line 39 skipping to change at page 4, line 47
or abort the exchange. The protocol's profile specifies how each of or abort the exchange. The protocol's profile specifies how each of
these is then represented over the connection. these is then represented over the connection.
During the authentication protocol exchange, the mechanism performs During the authentication protocol exchange, the mechanism performs
authentication, transmits an authorization identity (frequently known authentication, transmits an authorization identity (frequently known
as a userid) from the client to server, and negotiates the use of a as a userid) from the client to server, and negotiates the use of a
mechanism-specific security layer. If the use of a security layer is mechanism-specific security layer. If the use of a security layer is
agreed upon, then the mechanism must also define or negotiate the agreed upon, then the mechanism must also define or negotiate the
maximum security layer buffer size that each side is able to receive. maximum security layer buffer size that each side is able to receive.
4.2. Authorization identities and proxy authentication 4.2. Authorization and authentication identities
An authorization identity is a string of zero or more ISO 10646 SASL authentication deals with two identities: the authorization
[ISO-10646] coded characters. The NUL <U+0000> character is not identity and the authentication identity. The transmitted
permitted in authorization identities. The meaning of an authorization identity may be an empty string (zero length), but the
authorization identity of the empty string (zero length) is defined transmitted authentication identity may not be an empty string.
below in this section. The authorization identity is used by the
server as the primary identity for making access policy decisions.
The character encoding scheme used (see [CHARSET-POLICY] for IETF Internet DRAFT SASL 21 December 2003
policy regarding character sets in IETF protocols) for transmitting
an authorization identity over protocol is specified in each
authentication mechanism (with the authentication mechanism's data
being further restricted/encoded by the protocol profile).
Authentication mechanisms SHOULD encode these and other strings in
Internet DRAFT SASL 18 October 2003 While some legacy mechanisms are incapable of transmitting an
authorization identity (which means that for these mechanisms the
authorization identity is always the empty string), newly defined
mechanisms SHOULD be capable of transmiting a non-empty authorization
identity.
UTF-8 [UTF-8]. While some legacy mechanisms are incapable of Authentication identity is the identity derived from the client's
transmitting an authorization identity other than the empty string, authentication credentials.
newly defined mechanisms are expected to be capable of carrying the
entire Unicode repertoire (with the exception of the NUL character).
An authorization identity of the empty string and an absent
authorization identity MUST be treated as equivalent. However,
mechanisms SHOULD NOT allow both. That is, a mechanism which provides
an optional field for an authorization identity, SHOULD NOT allow
that field, when present, to be empty.
The identity derived from the client's authentication credentials is The authorization identity is used by the server as the primary
known as the "authentication identity". With any mechanism, identity for making access policy decisions.
transmitting an authorization identity of the empty string directs
the server to derive an authorization identity from the client's 4.2.1. Authorization identities and proxy authentication
authentication identity.
With any mechanism, transmitting an authorization identity of the
empty string directs the server to derive the authorization identity
from the client's authentication identity.
If the authorization identity transmitted during the authentication If the authorization identity transmitted during the authentication
protocol exchange is not the empty string, this is typically referred protocol exchange is not the empty string, this is typically referred
to as "proxy authentication". This feature permits agents such as to as "proxy authentication". This feature permits agents such as
proxy servers to authenticate using their own credentials, yet proxy servers to authenticate using their own credentials, yet
request the access privileges of the identity for which they are request the access privileges of the identity for which they are
proxying. proxying.
The server makes an implementation defined policy decision as to The server makes an implementation defined policy decision as to
whether the authentication identity is permitted to have the access whether the authentication identity is permitted to have the access
skipping to change at page 5, line 43 skipping to change at page 5, line 45
authorization identity is permitted to receive service. If it is authorization identity is permitted to receive service. If it is
not, the server indicates failure of the authentication protocol not, the server indicates failure of the authentication protocol
exchange. exchange.
As a client might not have the same information as the server, As a client might not have the same information as the server,
clients SHOULD NOT derive authorization identities from clients SHOULD NOT derive authorization identities from
authentication identities. Instead, clients SHOULD provide no (or authentication identities. Instead, clients SHOULD provide no (or
empty) authorization identity when the user has not provided an empty) authorization identity when the user has not provided an
authorization identity. authorization identity.
The server MUST verify that a received authorization identity is in The server SHOULD verify that a received authorization identity is in
the correct form. Profiles whose authorization identities are simple the correct form. Profiles whose authorization identities are simple
user names (e.g. IMAP [RFC 3501]) SHOULD use "SASLPrep" profile user names (e.g. IMAP [RFC 3501]) SHOULD use "SASLPrep" profile
[SASLPrep] of the "stringprep" algorithm [StringPrep] to prepare [SASLPrep] of the "stringprep" algorithm [StringPrep] to prepare
these names for matching. The profiles MAY use a stringprep profile these names for matching. The profiles MAY use a stringprep profile
that is more strict than "SASLPrep". If the preparation of the that is more strict than "SASLPrep". If the preparation of the
authorization identity fails or results in an empty string, the authorization identity fails or results in an empty string, the
server MUST fail the authentication exchange. The only exception to server MUST fail the authentication exchange. The only exception to
this rule is when the received authorization identity is already the this rule is when the received authorization identity is already the
Internet DRAFT SASL 21 December 2003
empty string. empty string.
Internet DRAFT SASL 18 October 2003 4.2.2. Authorization Identity Format
An authorization identity is a string of zero or more ISO 10646
[ISO-10646] coded characters. The NUL <U+0000> character is not
permitted in authorization identities.
The character encoding scheme used (see [CHARSET-POLICY] for IETF
policy regarding character sets in IETF protocols) for transmitting
an authorization identity over protocol is specified in each
authentication mechanism (with the authentication mechanism's data
being further restricted/encoded by the protocol profile).
Authentication mechanisms SHOULD encode these and other strings in
UTF-8 [UTF-8].
Mechanisms are expected to be capable of carrying the entire Unicode
repertoire (with the exception of the NUL character). An
authorization identity of the empty string and and an absent
authorization identity MUST be treated as equivalent. That is, a
mechanism which provides an optional field for an authorization
identity, SHOULD NOT allow that field, when present, to be empty.
The meaning of an authorization identity of the empty string is
described in the previous section.
4.3. Security layers 4.3. Security layers
If use of a security layer is negotiated by the authentication If use of a security layer is negotiated by the authentication
protocol exchange, the security layer is applied to all subsequent protocol exchange, the security layer is applied to all subsequent
data sent over the connection (until another security layer or no data sent over the connection (until another security layer is
security layer is negotiated; see also section 6.3). The security negotiated; see also section 6.3). The security layer takes effect
layer takes effect immediately following the last response of the immediately following the last response of the authentication
authentication exchange for data sent by the client and the exchange for data sent by the client and the completion indication
completion indication for data sent by the server. for data sent by the server.
Note, that all SASL mechanisms that are unable to negotiate a
security layer automatically select no security layer.
Once the security layer is in effect, the protocol stream is Once the security layer is in effect, the protocol stream is
processed by the security layer into buffers of security encoded processed by the security layer into buffers of security encoded
data. Each buffer of security encoded data is transferred over the data. Each buffer of security encoded data is transferred over the
connection as a stream of octets prepended with a four octet field in connection as a stream of octets prepended with a four octet field in
network byte order that represents the length of the following network byte order that represents the length of the following
buffer. The length of the security encoded data buffer MUST be no buffer. The length of the security encoded data buffer MUST be no
larger than the maximum size that was either defined in the mechanism larger than the maximum size that was either defined in the mechanism
specification or negotiated by the other side during the specification or negotiated by the other side during the
authentication protocol exchange. Upon the receipt of a data buffer authentication protocol exchange. Upon the receipt of a data buffer
Internet DRAFT SASL 21 December 2003
which is larger than the defined/negotiated maximal buffer size, the which is larger than the defined/negotiated maximal buffer size, the
receiver SHOULD close the connection. This might be a sign of an receiver SHOULD close the connection. This might be a sign of an
attack or a buggy implementation. attack or a buggy implementation.
4.4. Character string issues 4.4. Character string issues
Authentication mechanisms SHOULD encode character strings in UTF-8 Authentication mechanisms SHOULD encode character strings in UTF-8
[UTF-8] (see [CHARSET-POLICY] for IETF policy regarding character [UTF-8] (see [CHARSET-POLICY] for IETF policy regarding character
sets in IETF protocols). In order to avoid noninteroperability due sets in IETF protocols). In order to avoid noninteroperability due
to differing normalizations, when a mechanism specifies that a string to differing normalizations, when a mechanism specifies that a string
authentication identity or password used as input to a cryptographic authentication identity or password used as input to a cryptographic
function (or used for comparison) it SHOULD specify that the string function (or used for comparison) it SHOULD specify that the string
first be prepared using the "SASLPrep" profile [SASLPrep] of the first be prepared using the "SASLPrep" profile [SASLPrep] of the
"stringprep" algorithm [StringPrep]. There are three entities that "stringprep" algorithm [StringPrep]. There are three entities that
has to deal with this issue: a client (upon getting user input or has to deal with this issue: a client (upon getting user input or
retrieving a value from configuration), a server (upon receiving the retrieving a value from configuration), a server (upon receiving the
value from the client) and a utility that is able to store value from the client) and a utility that is able to store
passwords/hashes in a database that can be later used by the server. passwords/hashes in a database that can be later used by the server.
The preparation must be done by the client and the utility and may be SASL mechanisms must define which entity (or entities) must perform
done by the server. If preparation fails or results in an empty the preparation. If preparation fails or results in an empty string,
string, the entity doing the preparation SHALL fail the the entity doing the preparation SHALL fail the authentication
authentication exchange. exchange (or, in case of the utility, refuse to store the data).
5. Protocol profile requirements 5. Protocol profile requirements
In order to use this specification, a protocol definition MUST supply In order to use this specification, a protocol definition MUST supply
the following information: the following information:
Internet DRAFT SASL 18 October 2003
A service name, to be selected from the IANA registry of "service" A service name, to be selected from the IANA registry of "service"
elements for the GSSAPI host-based service name form [GSSAPI]. This elements for the GSSAPI host-based service name form [GSSAPI]. This
service name is made available to the authentication mechanism. service name is made available to the authentication mechanism.
The registry is available at the URL The registry is available at the URL
<http://www.iana.org/assignments/gssapi-service-names>. <http://www.iana.org/assignments/gssapi-service-names>.
A definition of the command to initiate the authentication protocol A definition of the command to initiate the authentication protocol
exchange. This command must have as a parameter the name of the exchange. This command must have as a parameter the name of the
mechanism being selected by the client. mechanism being selected by the client.
The command SHOULD have an optional parameter giving an initial The command SHOULD have an optional parameter giving an initial
response. This optional parameter allows the client to avoid a round response. This optional parameter allows the client to avoid a round
trip when using a mechanism which is defined to have the client send trip when using a mechanism which is defined to have the client send
data first. When this initial response is sent by the client and the data first. When this initial response is sent by the client and the
selected mechanism is defined to have the server start with an selected mechanism is defined to have the server start with an
initial challenge, the command fails. See section 6.1 of this initial challenge, the command fails. See section 6.1 of this
document for further information. document for further information.
Internet DRAFT SASL 21 December 2003
A definition of the method by which the authentication protocol A definition of the method by which the authentication protocol
exchange is carried out, including how the challenges and responses exchange is carried out, including how the challenges and responses
are encoded, how the server indicates completion or failure of the are encoded, how the server indicates completion or failure of the
exchange, how the client aborts an exchange, and how the exchange exchange, how the client aborts an exchange, and how the exchange
method interacts with any line length limits in the protocol. method interacts with any line length limits in the protocol.
The exchange method SHOULD allow the server to include an optional The exchange method SHOULD allow the server to include an optional
data ("optional challenge") with a success notification. This allows data ("optional challenge") with a success notification. This allows
the server to avoid a round trip when using a mechanism which is the server to avoid a round trip when using a mechanism which is
defined to have the server send additional data along with the defined to have the server send additional data along with the
skipping to change at page 7, line 47 skipping to change at page 8, line 28
document for further information. document for further information.
In addition, a protocol profile SHOULD specify a mechanism through In addition, a protocol profile SHOULD specify a mechanism through
which a client may obtain the names of the SASL mechanisms available which a client may obtain the names of the SASL mechanisms available
to it. This is typically done through the protocol's extensions or to it. This is typically done through the protocol's extensions or
capabilities mechanism. capabilities mechanism.
Identification of the octet where any negotiated security layer Identification of the octet where any negotiated security layer
starts to take effect, in both directions. starts to take effect, in both directions.
Specify if the protocol supports "multiple authentications" (see Specify if the protocol profile supports "multiple authentications"
section 6.3). (see section 6.3).
<<Not sure: also specify if there is a command to cancel a negotiated
security layer>>
If both TLS and SASL security layer are allowed to be negotiated by If both TLS and SASL security layer are allowed to be negotiated by
the protocol, the protocol profile MUST define in which order they the protocol, the protocol profile MUST define in which order they
are applied to a cleartext data sent over the connection. are applied to a cleartext data sent over the connection.
A protocol profile MAY further refine the definition of an A protocol profile MAY further refine the definition of an
Internet DRAFT SASL 18 October 2003
authorization identity by adding additional syntactic restrictions authorization identity by adding additional syntactic restrictions
and protocol-specific semantics. A protocol profile MUST specify the and protocol-specific semantics. A protocol profile MUST specify the
form of the authorization identity (since it is protocol specific, as form of the authorization identity (since it is protocol specific, as
opposed to the authentication identity, which is mechanism specific) opposed to the authentication identity, which is mechanism specific)
and how authorization identities are to be compared. Profiles whose and how authorization identities are to be compared. Profiles whose
authorization identities are simple user names (e.g. IMAP [RFC 3501]) authorization identities are simple user names (e.g. IMAP [RFC 3501])
SHOULD use "SASLPrep" profile [SASLPrep] of the "stringprep" SHOULD use "SASLPrep" profile [SASLPrep] of the "stringprep"
algorithm [StringPrep] to prepare these names for matching. The algorithm [StringPrep] to prepare these names for matching. The
profiles MAY use a stringprep profile that is more strict than profiles MAY use a stringprep profile that is more strict than
SASLPrep. SASLPrep.
A protocol profile SHOULD NOT attempt to amend the definition of A protocol profile SHOULD NOT attempt to amend the definition of
mechanisms or make mechanism-specific encodings. This breaks the mechanisms or make mechanism-specific encodings. This breaks the
separation between protocol and mechanism that is fundamental to the separation between protocol and mechanism that is fundamental to the
design of SASL. Likewise, SASL mechanisms SHOULD be profile neutral. design of SASL. Likewise, SASL mechanisms SHOULD be profile neutral.
Internet DRAFT SASL 21 December 2003
6. Specific issues 6. Specific issues
6.1. Client sends data first 6.1. Client sends data first
Some mechanisms specify that the first data sent in the Some mechanisms specify that the first data sent in the
authentication protocol exchange is from the client to the server. authentication protocol exchange is from the client to the server.
If a protocol's profile permits the command which initiates an If a protocol's profile permits the command which initiates an
authentication protocol exchange to contain an initial client authentication protocol exchange to contain an initial client
response, this parameter SHOULD be used with such mechanisms. response, this parameter SHOULD be used with such mechanisms.
If the initial client response parameter is not given, or if a If the initial client response parameter is not given, or if a
protocol's profile does not permit the command which initiates an protocol's profile does not permit the command which initiates an
authentication protocol exchange to contain an initial client authentication protocol exchange to contain an initial client
response, then the server issues a challenge with no data. The response, then the server issues a challenge with no data. The
client's response to this challenge is then used as the initial client's response to this challenge is then used as the initial
client response. (The server then proceeds to send the next client response. (The server then proceeds to send the next
challenge, indicates completion, or indicates failure.) challenge, indicates completion, or indicates failure.)
6.1.1. Examples
The following are two examples of an SECURID authentication [SASL-
SECURID] in the SMTP protocol [SMTP]. In the first example below,
the client is trying fast reauthentication by sending the initial
response:
S: 220-smtp.example.com ESMTP Server
C: EHLO client.example.com
S: 250-smtp.example.com Hello client.example.com, pleased to meet you
S: 250-AUTH GSSAPI SECURID
S: 250 DSN
C: AUTH SECURID AG1hZ251cwAxMjM0NTY3OAA=
S: 235 Authentication successful
The example below is almost identical to the previous, but here
the client chooses not to use the initial response parameter.
S: 220-smtp.example.com ESMTP Server
C: EHLO client.example.com
S: 250-smtp.example.com Hello client.example.com, pleased to meet you
S: 250-AUTH GSSAPI SECURID
S: 250 DSN
C: AUTH SECURID
S: 334
C: AG1hZ251cwAxMjM0NTY3OAA=
S: 235 Authentication successful
Internet DRAFT SASL 21 December 2003
Section 7.2 contains an additional example.
6.2. Server returns success with additional data 6.2. Server returns success with additional data
Some mechanisms may specify that additional data be sent to the Some mechanisms may specify that additional data be sent to the
client along with an indication of successful completion of the client along with an indication of successful completion of the
exchange. This data would, for example, authenticate the server to exchange. This data would, for example, authenticate the server to
the client. the client.
If a protocol's profile does not permit this additional data to be If a protocol's profile does not permit this additional data to be
returned with a success indication, then the server issues the data returned with a success indication, then the server issues the data
as a server challenge, without an indication of successful as a server challenge, without an indication of successful
completion. The client then responds with no data. After receiving completion. The client then responds with no data. After receiving
this empty response, the server then indicates successful completion this empty response, the server then indicates successful completion
(with no additional data). (with no additional data).
Internet DRAFT SASL 18 October 2003
Client implementors should be aware of an additional failure case Client implementors should be aware of an additional failure case
that might occur when the profile supports sending the additional that might occur when the profile supports sending the additional
data with success. Imagine that an active attacker is trying to data with success. Imagine that an active attacker is trying to
impersonate the server and sends faked data, which should be used to impersonate the server and sends faked data, which should be used to
authenticate the server to the client, with success. (A similar authenticate the server to the client, with success. (A similar
situation can happen when either the server and/or the client has a situation can happen when either the server and/or the client has a
bug and they calculate different responses.) After checking the data, bug and they calculate different responses.) After checking the data,
the client will think that the authentication exchange has failed, the client will think that the authentication exchange has failed,
however the server will think that the authentication exchange has however the server will think that the authentication exchange has
completed successfully. At this point the client can not abort the completed successfully. At this point the client can not abort the
authentication exchange, it SHOULD close the connection instead. authentication exchange, it SHOULD close the connection instead.
However, if the profile did not support sending of additional data However, if the profile did not support sending of additional data
with success, the client could have aborted the exchange at the very with success, the client could have aborted the exchange at the very
last step of the authentication exchange. last step of the authentication exchange.
6.2.1. Examples
The following are two examples of a DIGEST-MD5 authentication [SASL-
DIGEST] in the XMPP protocol [XMPP]. In the first example below, the
server is sending mutual authentication data with success.
C: <stream:stream
xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
to='example.com'
version='1.0'>
S: <stream:stream
xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
id='c2s_234'
from='example.com'
Internet DRAFT SASL 21 December 2003
version='1.0'>
S: <stream:features>
<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
<mechanism>DIGEST-MD5</mechanism>
<mechanism>CRAM-MD5</mechanism>
</mechanisms>
</stream:features>
C: <auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl'
mechanism='DIGEST-MD5'/>
S: <challenge xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
cmVhbG09InNvbWVyZWFsbSIsbm9uY2U9Ik9BNk1HOXRFUUdtMmhoIixxb3A9ImF1dGgi
LGNoYXJzZXQ9dXRmLTgsYWxnb3JpdGhtPW1kNS1zZXNzCg==
</challenge>
C: <response xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
dXNlcm5hbWU9InNvbWVub2RlIixyZWFsbT0ic29tZXJlYWxtIixub25jZT0i
T0E2TUc5dEVRR20yaGgiLGNub25jZT0iT0E2TUhYaDZWcVRyUmsiLG5jPTAw
MDAwMDAxLHFvcD1hdXRoLGRpZ2VzdC11cmk9InhtcHAvZXhhbXBsZS5jb20i
LHJlc3BvbnNlPWQzODhkYWQ5MGQ0YmJkNzYwYTE1MjMyMWYyMTQzYWY3LGNo
YXJzZXQ9dXRmLTgK
</response>
S: <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
cnNwYXV0aD1lYTQwZjYwMzM1YzQyN2I1NTI3Yjg0ZGJhYmNkZmZmZAo=
</success>
The example below is almost identical to the previous, but here
the server chooses not to use the additional data with success.
C: <stream:stream
xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
to='example.com'
version='1.0'>
S: <stream:stream
xmlns='jabber:client'
xmlns:stream='http://etherx.jabber.org/streams'
id='c2s_234'
from='example.com'
version='1.0'>
S: <stream:features>
<mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
<mechanism>DIGEST-MD5</mechanism>
<mechanism>CRAM-MD5</mechanism>
</mechanisms>
</stream:features>
C: <auth xmlns='urn:ietf:params:xml:ns:xmpp-sasl'
mechanism='DIGEST-MD5'/>
S: <challenge xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
cmVhbG09InNvbWVyZWFsbSIsbm9uY2U9Ik9BNk1HOXRFUUdtMmhoIixxb3A9ImF1dGgi
Internet DRAFT SASL 21 December 2003
LGNoYXJzZXQ9dXRmLTgsYWxnb3JpdGhtPW1kNS1zZXNzCg==
</challenge>
C: <response xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
dXNlcm5hbWU9InNvbWVub2RlIixyZWFsbT0ic29tZXJlYWxtIixub25jZT0i
T0E2TUc5dEVRR20yaGgiLGNub25jZT0iT0E2TUhYaDZWcVRyUmsiLG5jPTAw
MDAwMDAxLHFvcD1hdXRoLGRpZ2VzdC11cmk9InhtcHAvZXhhbXBsZS5jb20i
LHJlc3BvbnNlPWQzODhkYWQ5MGQ0YmJkNzYwYTE1MjMyMWYyMTQzYWY3LGNo
YXJzZXQ9dXRmLTgK
</response>
S: <challenge xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>
cnNwYXV0aD1lYTQwZjYwMzM1YzQyN2I1NTI3Yjg0ZGJhYmNkZmZmZAo=
</challenge>
C: <response xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
S: <success xmlns='urn:ietf:params:xml:ns:xmpp-sasl'/>
6.3. Multiple authentications 6.3. Multiple authentications
Unless otherwise stated by the protocol's profile, only one Unless otherwise stated by the protocol's profile, only one
successful SASL negotiation may occur in a protocol session. In this successful SASL negotiation may occur in a protocol session. In this
case, once an authentication protocol exchange has successfully case, once an authentication protocol exchange has successfully
completed, further attempts to initiate an authentication protocol completed, further attempts to initiate an authentication protocol
exchange fail. exchange fail.
If a profile explicitly permits multiple successful SASL negotiations If a profile explicitly permits multiple successful SASL negotiations
to occur, then in no case may multiple security layers be to occur, then in no case may multiple security layers be
simultaneously in effect. If a security layer is in effect and a simultaneously in effect. If a security layer is in effect and a
subsequent SASL negotiation selects a second security layer, then the subsequent SASL negotiation selects a second security layer, then the
second security layer replaces the first. If a security layer is in second security layer replaces the first. If a security layer is in
effect and a subsequent SASL negotiation selects no security layer, effect and a subsequent SASL negotiation selects no security layer,
the original security layer MUST be removed. The next paragraphs the original security layer remains in effect.
explain why this is important.
Note, that keeping the original security layer is a subject to a
class of security attack described later in this section. However, at
the time of the writing of this document the Working Group consensus
is not to change SASL handling of security layers, as the risk of
such attacks is considered to be low. The protocol profiles that
allow for reauthentication SHOULD recommend to always negotiate
another security layer, once a security layer was installed.
Also note, that if a subsequent authentication fails, the protocol
profile MAY allow the connection state to return to non-
authenticated, however the previously negotiated security layer MUST
NOT be removed. Only a successful reauthentication is able
replace/remove the previously negotiated security layer.
Let's assume that the protected resources on a server are partitioned Let's assume that the protected resources on a server are partitioned
into a set of protection spaces, each with its own authentication into a set of protection spaces, each with its own authentication
mechanisms and/or authorization database. Let's use the term "realm" mechanisms and/or authorization database. Let's use the term "realm"
Internet DRAFT SASL 21 December 2003
to reference any such protected space. Conceptually, realm is a named to reference any such protected space. Conceptually, realm is a named
collection of user's accounts. For example, a proxy/frontend can use collection of user's accounts. For example, a proxy/frontend can use
different realms for different servers/backends it represents. different realms for different servers/backends it represents.
Now consider the following scenario. A client has already Now consider the following scenario. A client has already
authenticated and established a security layer with "Realm A" which authenticated and established a security layer with "Realm A" which
is managed by the server AA. Now the same client authenticates to is managed by the server AA. Now the same client authenticates to
"Realm B" (managed by the server BB) without negotiating a new "Realm B" (managed by the server BB) without negotiating a new
security layer, while the security layer negotiated with "Realm A" security layer, while the security layer negotiated with "Realm A"
remains in effect. The server BB is now able observe how known remains in effect. The server BB is now able observe how known
cleartext is encrypted. This scenario enables the server BB to make cleartext is encrypted. This scenario enables the server BB to make
guesses about previously observed ciphertext between the client and guesses about previously observed ciphertext between the client and
the server AA using the server's SASL engine as an oracle. This the server AA using the server's SASL engine as an oracle. This
Internet DRAFT SASL 18 October 2003
scenario is illustrated below: scenario is illustrated below:
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
+---------+ +---------+ +---------+ +---------+
| | | | | | | |
| Realm B | | Realm A | | Realm B | | Realm A |
| | | | | | | |
+---------+ +---------+ +---------+ +---------+
| ^ | | ^ |
| : +-----------+ | | : +-----------+ |
Traffic from | : | Encryption| | Traffic from A Traffic from | : | Encryption| | Traffic from A
B to client +-------->| end point |<-------+ to client B to client +-------->| end point |<-------+ to client
skipping to change at page 12, line 5 skipping to change at page 15, line 5
server indicates failure. server indicates failure.
The system providing this external information may be, for example, The system providing this external information may be, for example,
IPSec or TLS. However, the client can make no assumptions as to what IPSec or TLS. However, the client can make no assumptions as to what
information the server can use in determining client authorization. information the server can use in determining client authorization.
E.g., just because TLS was established, doesn't mean that the server E.g., just because TLS was established, doesn't mean that the server
will use the information provided by TLS. will use the information provided by TLS.
If the client sends the empty string as the authorization identity If the client sends the empty string as the authorization identity
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
(thus requesting that the authorization identity be derived from the (thus requesting that the authorization identity be derived from the
client's authentication credentials), the authorization identity is client's authentication credentials), the authorization identity is
to be derived from authentication credentials which exist in the to be derived from authentication credentials which exist in the
system that is providing the external authentication. system that is providing the external authentication.
7.1. Formal syntax 7.1. Formal syntax
The following syntax specification uses the augmented Backus-Naur The following syntax specification uses the augmented Backus-Naur
Form (BNF) notation as specified in [ABNF]. This uses the ABNF core Form (BNF) notation as specified in [ABNF]. This uses the ABNF core
skipping to change at page 13, line 5 skipping to change at page 16, line 5
S: 220 smtp.example.com ESMTP server ready S: 220 smtp.example.com ESMTP server ready
C: EHLO jgm.example.com C: EHLO jgm.example.com
S: 250-smtp.example.com S: 250-smtp.example.com
S: 250 AUTH DIGEST-MD5 EXTERNAL S: 250 AUTH DIGEST-MD5 EXTERNAL
C: AUTH EXTERNAL ZnJlZA== C: AUTH EXTERNAL ZnJlZA==
S: 235 Authentication successful. S: 235 Authentication successful.
8. IANA Considerations 8. IANA Considerations
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
8.1. Guidelines for IANA 8.1. Guidelines for IANA
It is requested that IANA updates the SASL mechanisms registry as It is requested that IANA updates the SASL mechanisms registry as
follows: follows:
Change the "Intended usage" of the KERBEROS_V4 and SKEY mechanism Change the "Intended usage" of the KERBEROS_V4 and SKEY mechanism
registrations to OBSOLETE. Change the "Published specification" registrations to OBSOLETE. Change the "Published specification"
of the EXTERNAL mechanism to this document. Updated registration of the EXTERNAL mechanism to this document. Updated registration
is provided in Section 8.6. is provided in Section 8.6.
skipping to change at page 14, line 5 skipping to change at page 17, line 5
8.3. Comments on SASL mechanism registrations 8.3. Comments on SASL mechanism registrations
Comments on registered SASL mechanisms should first be sent to the Comments on registered SASL mechanisms should first be sent to the
"owner" of the mechanism and/or to the SASL WG mailing list. "owner" of the mechanism and/or to the SASL WG mailing list.
Submitters of comments may, after a reasonable attempt to contact the Submitters of comments may, after a reasonable attempt to contact the
owner, request IANA to attach their comment to the SASL mechanism owner, request IANA to attach their comment to the SASL mechanism
registration itself. If IANA approves of this, the comment will be registration itself. If IANA approves of this, the comment will be
made accessible in conjunction with the SASL mechanism registration made accessible in conjunction with the SASL mechanism registration
itself. itself.
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
8.4. Change control 8.4. Change control
Once a SASL mechanism registration has been published by IANA, the Once a SASL mechanism registration has been published by IANA, the
author may request a change to its definition. The change request author may request a change to its definition. The change request
follows the same procedure as the registration request. follows the same procedure as the registration request.
The owner of a SASL mechanism may pass responsibility for the SASL The owner of a SASL mechanism may pass responsibility for the SASL
mechanism to another person or agency by informing IANA; this can be mechanism to another person or agency by informing IANA; this can be
done without discussion or review. done without discussion or review.
skipping to change at page 15, line 5 skipping to change at page 18, line 5
Intended usage: Intended usage:
(One of COMMON, LIMITED USE or OBSOLETE) (One of COMMON, LIMITED USE or OBSOLETE)
Owner/Change controller: Owner/Change controller:
(Any other information that the author deems interesting may be (Any other information that the author deems interesting may be
added below this line.) added below this line.)
Internet DRAFT SASL 18 October 2003 Internet DRAFT SASL 21 December 2003
8.6. The EXTERNAL mechanism registration 8.6. The EXTERNAL mechanism registration
It is requested that the SASL Mechanism registry [IANA-SASL] entry It is requested that the SASL Mechanism registry [IANA-SASL] entry
for the EXTERNAL mechanism be updated to reflect that this document for the EXTERNAL mechanism be updated to reflect that this document
now provides its technical specification. now provides its technical specification.
Subject: Updated Registration of SASL mechanism EXTERNAL Subject: Updated Registration of SASL mechanism EXTERNAL
Family of SASL mechanisms: NO Family of SASL mechanisms: NO
skipping to change at page 15, line 36 skipping to change at page 18, line 36
Intended usage: COMMON Intended usage: COMMON
Owner/Change controller: IESG <iesg@ietf.org> Owner/Change controller: IESG <iesg@ietf.org>
Note: Updates existing entry for EXTERNAL Note: Updates existing entry for EXTERNAL
9. Security considerations 9. Security considerations
Security issues are discussed throughout this memo. Security issues are discussed throughout this memo.
In order to make password cracking and/or username harvesting attacks
more difficult servers MAY implement a policy whereby the connection
is dropped after a number of failed authentication attempts. If they
do so, they SHOULD NOT drop the connection until at least 3 attempts
to authenticate have failed. Alternatively, the server MAY implement
a policy when after a number of failed authentication attempts it
returns error to all subsequent authentication attempts on the same
connection.
The mechanisms that support integrity protection are designed such The mechanisms that support integrity protection are designed such
that the negotiation of the security layer and authorization identity that the negotiation of the security layer and authorization identity
is integrity protected. When the client selects a security layer is integrity protected. When the client selects a security layer
with at least integrity protection, this protects against an active with at least integrity protection, this protects against an active
attacker hijacking the connection and modifying the authentication attacker hijacking the connection and modifying the authentication
exchange to negotiate a plaintext connection. exchange to negotiate a plaintext connection.
When a server or client supports multiple authentication mechanisms, When a server or client supports multiple authentication mechanisms,
each of which has a different security strength, it is possible for each of which has a different security strength, it is possible for
Internet DRAFT SASL 21 December 2003
an active attacker to cause a party to use the least secure mechanism an active attacker to cause a party to use the least secure mechanism
supported. To protect against this sort of attack, a client or supported. To protect against this sort of attack, a client or
server which supports mechanisms of different strengths should have a server which supports mechanisms of different strengths should have a
configurable minimum strength that it will use. It is not sufficient configurable minimum strength that it will use. It is not sufficient
for this minimum strength check to only be on the server, since an for this minimum strength check to only be on the server, since an
active attacker can change which mechanisms the client sees as being active attacker can change which mechanisms the client sees as being
supported, causing the client to send authentication credentials for supported, causing the client to send authentication credentials for
its weakest supported mechanism. its weakest supported mechanism.
Internet DRAFT SASL 18 October 2003
The client's selection of a SASL mechanism is done in the clear and The client's selection of a SASL mechanism is done in the clear and
may be modified by an active attacker. It is important for any new may be modified by an active attacker. It is important for any new
SASL mechanisms to be designed such that an active attacker cannot SASL mechanisms to be designed such that an active attacker cannot
obtain an authentication with weaker security properties by modifying obtain an authentication with weaker security properties by modifying
the SASL mechanism name and/or the challenges and responses. the SASL mechanism name and/or the challenges and responses.
In order to detect Man-in-the-middle (MITM) attacks the client MAY
list available SASL mechanisms both before and after the SASL
security layer is negotiated. This allows the client to detect
active attacks that remove mechanisms from the server's list of
supported mechanisms, and allows the client to ensure that it is
using the best mechanism supported by both client and server. New
protocol profiles SHOULd require servers to make the list of SASL
mechanisms available for the initial authentication available to the
client after security layers are established. Some older protocols
do not require this (or don't support listing of SASL mechanisms once
authentication is complete); for these protocols clients MUST NOT
treat an empty list of SASL mechanisms after authentication as a MITM
attack.
Any protocol interactions prior to authentication are performed in Any protocol interactions prior to authentication are performed in
the clear and may be modified by an active attacker. In the case the clear and may be modified by an active attacker. In the case
where a client selects integrity protection, it is important that any where a client selects integrity protection, it is important that any
security-sensitive protocol negotiations be performed after security-sensitive protocol negotiations be performed after
authentication is complete. Protocols should be designed such that authentication is complete. Protocols should be designed such that
negotiations performed prior to authentication should be either negotiations performed prior to authentication should be either
ignored or revalidated once authentication is complete. ignored or revalidated once authentication is complete.
When use of a security layer is negotiated by the authentication When use of a security layer is negotiated by the authentication
protocol exchange, the receiver should handle gracefully any security protocol exchange, the receiver should handle gracefully any security
encoded data buffer larger than the defined/negotiated maximal size. encoded data buffer larger than the defined/negotiated maximal size.
In particular, it must not blindly allocate the amount of memory In particular, it must not blindly allocate the amount of memory
specified in the buffer size field, as this might cause the "out of specified in the buffer size field, as this might cause the "out of
memory" condition. If the receiver detects a large block, it SHOULD memory" condition. If the receiver detects a large block, it SHOULD
close the connection. close the connection.
Distributed server implementations need to be careful in how they
trust other parties and, in particular, authentication secrets should
only be disclosed to other parties that are trusted to manage and use
Internet DRAFT SASL 21 December 2003
those secrets in manner acceptable to disclosing party. It should be
noted that where those secrets are used to providing data
confidentiality protections, if a third party (other then the
discloser/declosee) has knowledge of some portion of the protected
information, it can use this knowledge in an attack upon other
portions of the protected information.
"stringprep" and Unicode security considerations apply to "stringprep" and Unicode security considerations apply to
authentication identities, authorization identities and passwords. authentication identities, authorization identities and passwords.
The EXTERNAL mechanism provides no security protection; it is The EXTERNAL mechanism provides no security protection; it is
vulnerable to spoofing by either client or server, active attack, and vulnerable to spoofing by either client or server, active attack, and
eavesdropping. It should only be used when external security eavesdropping. It should only be used when external security
mechanisms are present and have sufficient strength. mechanisms are present and have sufficient strength.
10. References 10. References
skipping to change at page 17, line 5 skipping to change at page 20, line 40
Techniques for Use with the 7-bit Coded Character Set of American Techniques for Use with the 7-bit Coded Character Set of American
National Standard Code (ASCII) for Information Interchange", FIPS PUB National Standard Code (ASCII) for Information Interchange", FIPS PUB
35, 1974 35, 1974
[CHARSET-POLICY] Alvestrand, "IETF Policy on Character Sets and [CHARSET-POLICY] Alvestrand, "IETF Policy on Character Sets and
Languages", RFC 2277, January 1998 Languages", RFC 2277, January 1998
[GSSAPI] Linn, "Generic Security Service Application Program [GSSAPI] Linn, "Generic Security Service Application Program
Interface, Version 2, Update 1", RFC 2743, January 2000 Interface, Version 2, Update 1", RFC 2743, January 2000
Internet DRAFT SASL 18 October 2003
[ISO-10646] "Universal Multiple-Octet Coded Character Set (UCS) - [ISO-10646] "Universal Multiple-Octet Coded Character Set (UCS) -
Architecture and Basic Multilingual Plane", ISO/IEC 10646-1 : 1993. Architecture and Basic Multilingual Plane", ISO/IEC 10646-1 : 1993.
[KEYWORDS] Bradner, "Key words for use in RFCs to Indicate [KEYWORDS] Bradner, "Key words for use in RFCs to Indicate
Requirement Levels", RFC 2119, March 1997 Requirement Levels", RFC 2119, March 1997
[Unicode] The Unicode Consortium, "The Unicode Standard, Version [Unicode] The Unicode Consortium, "The Unicode Standard, Version
3.2.0" is defined by "The Unicode Standard, Version 3.0" (Reading, 3.2.0" is defined by "The Unicode Standard, Version 3.0" (Reading,
MA, Addison-Wesley, 2000. ISBN 0-201-61633-5), as amended by the MA, Addison-Wesley, 2000. ISBN 0-201-61633-5), as amended by the
"Unicode Standard Annex #27: Unicode 3.1" "Unicode Standard Annex #27: Unicode 3.1"
(http://www.unicode.org/reports/tr27/) and by the "Unicode Standard (http://www.unicode.org/reports/tr27/) and by the "Unicode Standard
Annex #28: Unicode 3.2" (http://www.unicode.org/reports/tr28/). Annex #28: Unicode 3.2" (http://www.unicode.org/reports/tr28/).
[Stringprep] P. Hoffman, M. Blanchet, "Preparation of [Stringprep] P. Hoffman, M. Blanchet, "Preparation of
Internationalized Strings ("stringprep")", RFC 3454, December 2002. Internationalized Strings ("stringprep")", RFC 3454, December 2002.
Internet DRAFT SASL 21 December 2003
[SASLPrep] Zeilenga, K., "SASLprep: Stringprep profile for user names [SASLPrep] Zeilenga, K., "SASLprep: Stringprep profile for user names
and passwords", Work in progress, draft-ietf-sasl-saslprep-XX.txt. and passwords", Work in progress, draft-ietf-sasl-saslprep-XX.txt.
[UTF-8] Yergeau, "UTF-8, a transformation format of ISO 10646", work [UTF-8] Yergeau, "UTF-8, a transformation format of ISO 10646", work
in progress (draft-yergeau-rfc2279bis-XX) that replaces RFC 2279, in progress (draft-yergeau-rfc2279bis-XX) that replaces RFC 2279,
Janyary 1998 Janyary 1998
10.2. Informative References 10.2. Informative References
<<Update the reference below>> [SASL-GSSAPI] Myers, J., "SASL GSSAPI [SASL-GSSAPI] Melnikov, A., "SASL GSSAPI mechanisms", work in
mechanisms", work in progress, draft-ietf-cat-sasl-gssapi-XX.txt, progress, draft-ietf-sasl-gssapi-XX.txt, November 2003
September 2000
[SASL-DIGEST] Leach, P., Newman, C., Melnikov, A., "Using Digest [SASL-DIGEST] Leach, P., Newman, C., Melnikov, A., "Using Digest
Authentication as a SASL Mechanism", work in progress, draft-ietf- Authentication as a SASL Mechanism", work in progress, draft-ietf-
sasl-rfc2831bis-XX.txt, replaces RFC 2831 sasl-rfc2831bis-XX.txt, replaces RFC 2831
[SASL-OTP] Newman, C., "The One-Time-Password SASL Mechanism", RFC [SASL-OTP] Newman, C., "The One-Time-Password SASL Mechanism", RFC
2444, October 1998 2444, October 1998
[SASL-SECURID] Nystrom, M., "The SecurID(r) SASL Mechanism", RFC
2808, April 2000
[SMTP] Klensin, J., "Simple Mail Transfer Protocol", RFC 2821, April [SMTP] Klensin, J., "Simple Mail Transfer Protocol", RFC 2821, April
2001 2001
[SMTP-AUTH] Myers, J., "SMTP Service Extension for Authentication", [SMTP-AUTH] Myers, J., "SMTP Service Extension for Authentication",
RFC 2554, March 1999 RFC 2554, March 1999
Being revised by Siemborski, R., "SMTP Service Extension for
Authentication", work in progress, draft-siemborski-rfc2554bis-XX.txt
[XMPP] Saint-Andre, P., "Extensible Messaging and Presence Protocol
(XMPP): Core", work in progress, draft-ietf-xmpp-core-XX.txt
[BASE64] Josefsson, S., "The Base16, Base32, and Base64 Data [BASE64] Josefsson, S., "The Base16, Base32, and Base64 Data
Encodings", RFC 3548, July 2003 Encodings", RFC 3548, July 2003
[RFC-INSTRUCTIONS] Postel, Reynolds, "Instructions to RFC Authors", [RFC-INSTRUCTIONS] Postel, Reynolds, "Instructions to RFC Authors",
RFC 2223, October 1997 RFC 2223, October 1997
Internet DRAFT SASL 18 October 2003
[IANA-SASL] IANA, "SIMPLE AUTHENTICATION AND SECURITY LAYER (SASL) [IANA-SASL] IANA, "SIMPLE AUTHENTICATION AND SECURITY LAYER (SASL)
MECHANISMS", http://www.iana.org/assignments/sasl-mechanisms. MECHANISMS", http://www.iana.org/assignments/sasl-mechanisms.
11. Editor's Address 11. Editor's Address
Alexey Melnikov Alexey Melnikov
Isode Isode
Internet DRAFT SASL 21 December 2003
Email: Alexey.Melnikov@isode.com Email: Alexey.Melnikov@isode.com
12. Acknowledgments 12. Acknowledgments
This document is a revision of RFC 2222 written by John G. Myers. He This document is a revision of RFC 2222 written by John G. Myers. He
also contributed significantly to this revision. also contributed significantly to this revision.
Magnus Nystrom provided the ASCII art used in Section 6.3. Magnus Nystrom provided the ASCII art used in Section 6.3.
Definition of realm was extracted from RFC 2617 ("HTTP Definition of realm was extracted from RFC 2617 ("HTTP
Authentication: Basic and Digest Access Authentication"). Authentication: Basic and Digest Access Authentication").
Contributions of many members of the SASL mailing list are gratefully Contributions of many members of the SASL mailing list are gratefully
acknowledged, in particular Kurt D. Zeilenga, Peter Saint-Andre, Rob acknowledged, in particular Kurt D. Zeilenga, Peter Saint-Andre, Rob
Siemborski, Jeffrey Hutzelman and Hallvard B Furuseth for Siemborski, Jeffrey Hutzelman, Hallvard B Furuseth and Tony Hansen
proofreading the document and various editorial suggestions. for proofreading the document and various editorial suggestions.
13. Full Copyright Statement 13. Full Copyright Statement
Copyright (C) The Internet Society (2003). All Rights Reserved. Copyright (C) The Internet Society (2003). All Rights Reserved.
This document and translations of it may be copied and furnished to This document and translations of it may be copied and furnished to
others, and derivative works that comment on or otherwise explain it others, and derivative works that comment on or otherwise explain it
or assist in its implementation may be prepared, copied, published or assist in its implementation may be prepared, copied, published
and distributed, in whole or in part, without restriction of any and distributed, in whole or in part, without restriction of any
kind, provided that the above copyright notice and this paragraph are kind, provided that the above copyright notice and this paragraph are
skipping to change at page 19, line 4 skipping to change at page 22, line 46
Internet organizations, except as needed for the purpose of Internet organizations, except as needed for the purpose of
developing Internet standards in which case the procedures for developing Internet standards in which case the procedures for
copyrights defined in the Internet Standards process must be copyrights defined in the Internet Standards process must be
followed, or as required to translate it into languages other than followed, or as required to translate it into languages other than
English. English.
The limited permissions granted above are perpetual and will not be The limited permissions granted above are perpetual and will not be
revoked by the Internet Society or its successors or assigns. revoked by the Internet Society or its successors or assigns.
This document and the information contained herein is provided on an This document and the information contained herein is provided on an
Internet DRAFT SASL 18 October 2003
"AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING
TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION
HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF
MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
Acknowledgement Acknowledgement
Internet DRAFT SASL 21 December 2003
Funding for the RFC Editor function is currently provided by the Funding for the RFC Editor function is currently provided by the
Internet Society. Internet Society.
Appendix A. Relation of SASL to transport security Appendix A. Relation of SASL to transport security
Questions have been raised about the relationship between SASL and Questions have been raised about the relationship between SASL and
various services (such as IPsec and TLS) which provide a secured various services (such as IPsec and TLS) which provide a secured
connection. connection.
Two of the key features of SASL are: Two of the key features of SASL are:
skipping to change at page 20, line 4 skipping to change at page 23, line 47
an example of such a service.) This can be done by adding a command, an example of such a service.) This can be done by adding a command,
for example "STARTTLS", to the protocol. Such a command is outside for example "STARTTLS", to the protocol. Such a command is outside
the scope of SASL, and should be different from the command which the scope of SASL, and should be different from the command which
starts a SASL authentication protocol exchange. starts a SASL authentication protocol exchange.
In certain situations, it is reasonable to use SASL underneath one of In certain situations, it is reasonable to use SASL underneath one of
these Transport Security services. The transport service would these Transport Security services. The transport service would
secure the connection, either service would authenticate the client, secure the connection, either service would authenticate the client,
and SASL would negotiate the authorization identity. The SASL and SASL would negotiate the authorization identity. The SASL
negotiation would be what moves the protocol from "unauthenticated" negotiation would be what moves the protocol from "unauthenticated"
Internet DRAFT SASL 18 October 2003
to "authenticated" state. The "EXTERNAL" SASL mechanism is to "authenticated" state. The "EXTERNAL" SASL mechanism is
explicitly intended to handle the case where the transport service explicitly intended to handle the case where the transport service
secures the connection and authenticates the client and SASL secures the connection and authenticates the client and SASL
negotiates the authorization identity. negotiates the authorization identity.
Internet DRAFT SASL 21 December 2003
Appendix B. Changes since RFC 2222 Appendix B. Changes since RFC 2222
The GSSAPI mechanism was removed. It is now specified in a separate The GSSAPI mechanism was removed. It is now specified in a separate
document [SASL-GSSAPI]. document [SASL-GSSAPI].
The "KERBEROS_V4" mechanism defined in RFC 2222 is obsolete and has The "KERBEROS_V4" mechanism defined in RFC 2222 is obsolete and has
been removed. been removed.
The "SKEY" mechanism described in RFC 2222 is obsolete and has been The "SKEY" mechanism described in RFC 2222 is obsolete and has been
removed. It has been replaced by the OTP mechanism [SASL-OTP]. removed. It has been replaced by the OTP mechanism [SASL-OTP].
skipping to change at page 21, line 5 skipping to change at page 24, line 51
portions of the SASL mechanism namespace and may amend registration portions of the SASL mechanism namespace and may amend registration
rules for the portion. However registration of individual SASL rules for the portion. However registration of individual SASL
mechanisms is still required. mechanisms is still required.
Specified that the authorization identity in the EXTERNAL mechanism Specified that the authorization identity in the EXTERNAL mechanism
is encoded in UTF-8. is encoded in UTF-8.
Added a statement that a protocol profile SHOULD allow challenge data Added a statement that a protocol profile SHOULD allow challenge data
to be sent with a success indication. to be sent with a success indication.
Internet DRAFT SASL 18 October 2003
Added a security consideration for the EXTERNAL mechansim. Added a security consideration for the EXTERNAL mechansim.
Clarified sections concerning success with additional data. Clarified sections concerning success with additional data.
Internet DRAFT SASL 21 December 2003
Cleaned up IANA considerations/registrations and assembled them in Cleaned up IANA considerations/registrations and assembled them in
one place. one place.
Updated references and split them into Informative and Normative. Updated references and split them into Informative and Normative.
Added text to the Security Considerations section regarding handling Added text to the Security Considerations section regarding handling
of extremely large SASL blocks. of extremely large SASL blocks.
Replaced UTF-8 ABNF with the reference to the UTF-8 document. Replaced UTF-8 ABNF with the reference to the UTF-8 document.
Added text about SASLPrep for authentication identities and Added text about SASLPrep for authentication identities and
passwords. Described where SASLPrep preparation should take place. passwords. Described where SASLPrep preparation should take place.
Added paragraph about verifying authorization identities. Added paragraph about verifying authorization identities.
This document requires to drop a security layer on reauthentication
when no security layer is negotiated. This differs from RFC 2222,
which required to keep the last security layer in this case.
Added a protocol profile requirement to specify interaction between Added a protocol profile requirement to specify interaction between
SASL and TLS security layers. SASL and TLS security layers.
Added a protocol profile requirement to specify if it supports Added a protocol profile requirement to specify if it supports
reauthentication. reauthentication.
Removed the text that seemed to suggest that SASL security layer must Removed the text that seemed to suggest that SASL security layer must
not be used when TLS is available. not be used when TLS is available.
Internet DRAFT SASL 18 October 2003 Created two subsections in 4.2 to talk separately about proxy
authorization and format of the authorization identities.
Made requirement to verify that an authorization identity is correct
by performing SASLPrep a SHOULD, instead of a MUST.
Clarified that each SASL mechanism must decide where SASLPrep is
taking place.
Added 4 new examples for initial response and additional data with
success.
Added text on checking the list of available SASL mechanisms after
negotiating a security layer.
Added definition of "integrity protection" and "confidentiality
protection".
Added text about preventing password cracking/username harvesting
attacks.
Added warning about negotiating no layer once a security layer is
negotiated.
Internet DRAFT SASL 21 December 2003
Status of this Memo .......................................... i Status of this Memo .......................................... i
1. Abstract ............................................... 2 1. Abstract ............................................... 2
2. Organization of this document .......................... 2 2. Organization of this document .......................... 2
2.1. How to read this document .............................. 2 2.1. How to read this document .............................. 2
2.2. Conventions used in this document ...................... 2 2.2. Conventions used in this document ...................... 2
3. Overview ............................................... 3 3. Overview ............................................... 3
4. Authentication mechanisms .............................. 3 4. Authentication mechanisms .............................. 3
4.1. Authentication protocol exchange ....................... 4 4.1. Authentication protocol exchange ....................... 4
4.2. Authorization identities and proxy authentication ...... 4 4.2. Authorization and authentication identities ............ 4
4.2.1. Authorization identities and proxy authentication .... 5
4.2.2. Authorization Identity Format ........................ 6
4.3. Security layers ........................................ 6 4.3. Security layers ........................................ 6
4.4. Character string issues ................................ 6 4.4. Character string issues ................................ 7
5. Protocol profile requirements .......................... 6 5. Protocol profile requirements .......................... 7
6. Specific issues ........................................ 8 6. Specific issues ........................................ 9
6.1. Client sends data first ................................ 8 6.1. Client sends data first ................................ 9
6.2. Server returns success with additional data ............ 8 6.1.1. Examples ............................................. 9
6.3. Multiple authentications ............................... 9 6.2. Server returns success with additional data ........... 10
7. The EXTERNAL mechanism ................................ 11 6.2.1. Examples ............................................ 10
7.1. Formal syntax ......................................... 12 6.3. Multiple authentications .............................. 12
7.2. Example ............................................... 12 7. The EXTERNAL mechanism ................................ 14
8. IANA Considerations ................................... 12 7.1. Formal syntax ......................................... 15
8.1. Guidelines for IANA ................................... 13 7.2. Example ............................................... 15
8.2. Registration procedure ................................ 13 8. IANA Considerations ................................... 15
8.3. Comments on SASL mechanism registrations .............. 13 8.1. Guidelines for IANA ................................... 16
8.4. Change control ........................................ 14 8.2. Registration procedure ................................ 16
8.5. Registration template ................................. 14 8.3. Comments on SASL mechanism registrations .............. 16
8.6. The EXTERNAL mechanism registration ................... 15 8.4. Change control ........................................ 17
9. Security considerations ................................ 15 8.5. Registration template ................................. 17
10. References ........................................... 16 8.6. The EXTERNAL mechanism registration ................... 18
10.1. Normative References ................................. 16 9. Security considerations ................................ 18
10.2. Informative References ............................... 17 10. References ........................................... 20
11. Editor's Address ...................................... 18 10.1. Normative References ................................. 20
12. Acknowledgments ....................................... 18 10.2. Informative References ............................... 21
13. Full Copyright Statement .............................. 18 11. Editor's Address ...................................... 21
Appendix A. Relation of SASL to transport security .......... 19 12. Acknowledgments ....................................... 22
Appendix B. Changes since RFC 2222 .......................... 20 13. Full Copyright Statement .............................. 22
Appendix A. Relation of SASL to transport security .......... 23
Appendix B. Changes since RFC 2222 .......................... 24
 End of changes. 

This html diff was produced by rfcdiff 1.23, available from http://www.levkowetz.com/ietf/tools/rfcdiff/