draft-ietf-netconf-tls-00.txt   draft-ietf-netconf-tls-01.txt 
NETCONF Working Group Mohamad Badra NETCONF Working Group Mohamad Badra
Internet Draft LIMOS Laboratory Internet Draft LIMOS Laboratory
Intended status: Standard Track January 1, 2008 Intended status: Standards Track February 15, 2008
NETCONF over TLS Expires: August 2008
draft-ietf-netconf-tls-00.txt
NETCONF over Transport Layer Security (TLS)
draft-ietf-netconf-tls-01.txt
Status of this Memo Status of this Memo
By submitting this Internet-Draft, each author represents that any By submitting this Internet-Draft, each author represents that any
applicable patent or other IPR claims of which he or she is aware applicable patent or other IPR claims of which he or she is aware
have been or will be disclosed, and any of which he or she becomes have been or will be disclosed, and any of which he or she becomes
aware will be disclosed, in accordance with Section 6 of BCP 79. aware will be disclosed, in accordance with Section 6 of BCP 79.
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 1, line 31 skipping to change at page 1, line 33
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
The list of current Internet-Drafts can be accessed at The list of current Internet-Drafts can be accessed at
http://www.ietf.org/ietf/1id-abstracts.txt http://www.ietf.org/ietf/1id-abstracts.txt
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
This Internet-Draft will expire on July 1, 2008. This Internet-Draft will expire on August 15, 2008.
Copyright Notice Copyright Notice
Copyright (C) The IETF Trust (2008). Copyright (C) The IETF Trust (2008).
Abstract Abstract
The NETCONF configuration protocol provides mechanisms to install, The Network Configuration Protocol (NETCONF) provides mechanisms to
manipulate, and delete the configuration of network devices. This install, manipulate, and delete the configuration of network devices.
document describes how to use TLS to secure NETCONF exchanges. This document describes how to use the Transport Layer Protocol (TLS)
to secure NETCONF exchanges.
Table of Contents Table of Contents
1. Introduction...................................................2 1. Introduction...................................................2
1.1. Conventions used in this document.........................2 1.1. Conventions used in this document.........................2
2. NETCONF over TLS...............................................3 2. NETCONF over TLS...............................................3
2.1. Connection Initiation.....................................3 2.1. Connection Initiation.....................................3
2.2. Connection Closure........................................3 2.2. Connection Closure........................................3
3. Endpoint Authentication and Identification.....................4 3. Endpoint Authentication and Identification.....................4
3.1. Public Key Based-Certificate Authentication...............4 3.1. Server Identity...........................................4
3.1.1. Server Identity......................................4 3.2. Client Identity...........................................5
3.1.2. Client Identity......................................5 3.3. Password-Based Authentication.............................5
3.2. Password-Based Authentication for the NETCONF manager (TLS 4. Cipher Suite Requirements......................................7
client)........................................................5 5. Security Considerations........................................7
4. Security Considerations........................................6 6. IANA Considerations............................................7
5. IANA Considerations............................................6 7. Acknowledgments................................................7
6. Acknowledgments................................................6 8. References.....................................................7
7. References.....................................................7 8.1. Normative References......................................7
7.1. Normative References......................................7
7.2. Informative References....................................7
Author's Addresses................................................8 Author's Addresses................................................8
Intellectual Property Statement...................................8 Intellectual Property Statement...................................8
Disclaimer of Validity............................................8 Disclaimer of Validity............................................9
1. Introduction 1. Introduction
The NETCONF protocol [NETCONF] defines a simple mechanism through The NETCONF protocol [RFC4741] defines a simple mechanism through
which a network device can be managed. NETCONF is connection- which a network device can be managed. NETCONF is connection-
oriented, requiring a persistent connection between peers. This oriented, requiring a persistent connection between peers. This
connection must provide reliable, sequenced data delivery, integrity connection must provide reliable, sequenced data delivery, integrity
and confidentiality and peers authentication. This document describes and confidentiality and peers authentication. This document
how to use TLS [TLS] to secure NETCONF connections. describes how to use TLS [RFC4346] to secure NETCONF connections.
1.1. Conventions used in this document
This document uses the following terms:
manager Throughout this document, the terms "client" and "server" are used to
It refers to the end initiating the NETCONF connection. It issues refer to the two ends of the TLS connection. The client actively
the NETCONF RPC commands. opens the TLS connection, and the server passively listens for the
incoming TLS connection. The terms "manager" and "agent" are used to
refer to the two ends of the NETCONF protocol session. The manager
issues NETCONF remote procedure call (RPC) commands, and the agent
replies to those commands. When NETCONF is run over TLS using the
mapping defined in this document, the client is always the manager,
and the server is always the agent.
agent 1.1. Conventions used in this document
It refers to the end replying to the manager's commands during the
NETCONF connection.
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
document are to be interpreted as described in RFC-2119 [RFC2119]. document are to be interpreted as described in RFC-2119 [RFC2119].
2. NETCONF over TLS 2. NETCONF over TLS
Since TLS is application protocol-independent, NETCONF can operate on Since TLS is application protocol-independent, NETCONF can operate on
top of the TLS protocol transparently. This document defines how top of the TLS protocol transparently. This document defines how
NETCONF can be used within a Transport Layer Security (TLS) session. NETCONF can be used within a Transport Layer Security (TLS) session.
2.1. Connection Initiation 2.1. Connection Initiation
The peer acting as the NETCONF manager MUST also act as the TLS The peer acting as the NETCONF manager MUST also act as the TLS
client. It MUST connect to the server that passively listens for the client. It MUST connect to the server that passively listens for the
incoming TLS connection on the IANA-to-be-assigned TCP port <TBC>. It incoming TLS connection on the IANA-to-be-assigned TCP port <TBA>.
MUST therefore send the TLS ClientHello to begin the TLS handshake. It MUST therefore send the TLS ClientHello to begin the TLS
Once the TLS handshake has been finished, the manager and the agent handshake. Once the TLS handshake has been finished, the client and
MAY then send their NETCONF exchanges. In particular, the manager the server MAY then send their NETCONF exchanges. In particular, the
will send complete XML documents to the server containing <rpc> client will send complete XML documents to the server containing
elements, and the agent will respond with complete XML documents <rpc> elements, and the server will respond with complete XML
containing <rpc-reply> elements. The client MAY indicate interest in documents containing <rpc-reply> elements. The client MAY indicate
receiving event notifications from a NETCONF server by creating a interest in receiving event notifications from a NETCONF server by
subscription to receive event notifications [NETNOT], in which the creating a subscription to receive event notifications [NETNOT], in
NETCONF server replies to indicate whether the subscription request which the NETCONF server replies to indicate whether the subscription
was successful and, if it was successful, begins sending the event request was successful and, if it was successful, begins sending the
notifications to the NETCONF client as the events occur within the event notifications to the NETCONF client as the events occur within
system. All these elements are encapsulated into TLS records of type the system. All these elements are encapsulated into TLS records of
"application data". These records are protected using the TLS type "application data". These records are protected using the TLS
material keys. material keys.
Current NETCONF messages don't include a message's length. This Current NETCONF messages don't include a message's length. This
document uses consequently the same delimiter sequence defined in document uses consequently the same delimiter sequence defined in
[NETSSH] and therefore the special character sequence, ]]>]]>, to [RFC4742] and therefore the special character sequence, ]]>]]>, to
delimit XML documents. delimit XML documents.
2.2. Connection Closure 2.2. Connection Closure
Either NETCONF peer MAY stop the NETCONF connection at any time and Either NETCONF peer MAY stop the NETCONF connection at any time and
therefore notify the other NETCONF peer that no more data on this therefore notify the other NETCONF peer that no more data on this
channel will be sent and that any data received after a closure channel will be sent and that any data received after a closure
request will be ignored. This MAY happen when no data is received request will be ignored. This MAY happen when no data is received
from a connection for a long time, where the application decides what from a connection for a long time, where the application decides what
"long" means. "long" means.
skipping to change at page 4, line 17 skipping to change at page 4, line 15
Unless some other fatal alert has been transmitted, each party is Unless some other fatal alert has been transmitted, each party is
required to send a close_notify alert before closing the write side required to send a close_notify alert before closing the write side
of the connection. The other party MUST respond with a close_notify of the connection. The other party MUST respond with a close_notify
alert of its own and close down the connection immediately, alert of its own and close down the connection immediately,
discarding any pending writes. It is not required for the initiator discarding any pending writes. It is not required for the initiator
of the close to wait for the responding close_notify alert before of the close to wait for the responding close_notify alert before
closing the read side of the connection. closing the read side of the connection.
3. Endpoint Authentication and Identification 3. Endpoint Authentication and Identification
Usually, TLS uses public key based-certificates [TLS], Kerberos NETCONF requires that its transport provide mutual authentication of
[TLSKERB], or preshared keys [TLSPSK] for authentication. client and server, so cipher suites that are anonymous or which only
authenticate the server to the client MUST NOT be used with NETCONF.
3.1. Public Key Based-Certificate Authentication This document specifies how to use TLS with endpoint authentication
in TLS can be based on either preshared keys [RFC4279] or public key
When public key is used for authentication, TLS supports three certificates [RFC4346]. Some cipher suites (e.g.
authentication modes: authentication of both parties, server TLS_RSA_PSK_WITH_AES_128_CBC_SHA) use both. Section 3.1 describes
authentication with an unauthenticated client, and total anonymity. how the client authenticates the server if public key certificates
For the last two modes, a profile to enable the password-based client are provided by the server, section 3.2 describes how the server
(manager) authentication is defined in section 3.2. authenticates the client if public key certificates are provided by
the client, and section 3.3 describes how the client and server
mutually authenticate one another using a password.
3.1.1. Server Identity 3.1. Server Identity
During the TLS negotiation, the client MUST carefully examine the During the TLS negotiation, the client MUST carefully examine the
certificate presented by the server to determine if it meets their certificate presented by the server to determine if it meets their
expectations. Particularly, the client MUST check its understanding expectations. Particularly, the client MUST check its understanding
of the server hostname against the server's identity as presented in of the server hostname against the server's identity as presented in
the server Certificate message, in order to prevent man-in-the-middle the server Certificate message, in order to prevent man-in-the-middle
attacks. attacks.
Matching is performed according to these rules [RFC4642]: Matching is performed according to these rules [RFC4642]:
- The client MUST use the server hostname it used to open the - The client MUST use the server hostname it used to open the
connection (or the hostname specified in TLS "server_name" connection (or the hostname specified in TLS "server_name"
extension [TLSEXT]) as the value to compare against the server extension [RFC4366]) as the value to compare against the server
name as expressed in the server certificate. The client MUST name as expressed in the server certificate. The client MUST
NOT use any form of the server hostname derived from an NOT use any form of the server hostname derived from an
insecure remote source (e.g., insecure DNS lookup). CNAME insecure remote source (e.g., insecure DNS lookup). CNAME
canonicalization is not done. canonicalization is not done.
- If a subjectAltName extension of type dNSName is present in the - If a subjectAltName extension of type dNSName is present in the
certificate, it MUST be used as the source of the server's certificate, it MUST be used as the source of the server's
identity. identity.
- Matching is case-insensitive. - Matching is case-insensitive.
skipping to change at page 5, line 22 skipping to change at page 5, line 20
- If the certificate contains multiple names (e.g., more than one - If the certificate contains multiple names (e.g., more than one
dNSName field), then a match with any one of the fields is dNSName field), then a match with any one of the fields is
considered acceptable. considered acceptable.
If the match fails, the client MUST either ask for explicit user If the match fails, the client MUST either ask for explicit user
confirmation or terminate the connection and indicate the server's confirmation or terminate the connection and indicate the server's
identity is suspect. identity is suspect.
Additionally, clients MUST verify the binding between the identity of Additionally, clients MUST verify the binding between the identity of
the servers to which they connect and the public keys presented by the servers to which they connect and the public keys presented by
those servers. Clients SHOULD implement the algorithm in Section 6 of those servers. Clients SHOULD implement the algorithm in Section 6
[PKICERT] for general certificate validation, but MAY supplement that of [RFC3280] for general certificate validation, but MAY supplement
algorithm with other validation methods that achieve equivalent that algorithm with other validation methods that achieve equivalent
levels of verification (such as comparing the server certificate levels of verification (such as comparing the server certificate
against a local store of already-verified certificates and identity against a local store of already-verified certificates and identity
bindings). bindings).
If the client has external information as to the expected identity of If the client has external information as to the expected identity of
the server, the hostname check MAY be omitted. the server, the hostname check MAY be omitted.
3.1.2. Client Identity 3.2. Client Identity
Typically, the server has no external knowledge of what the client's Typically, the server has no external knowledge of what the client's
identity ought to be and so checks (other than that the client has a identity ought to be and so checks (other than that the client has a
certificate chain rooted in an appropriate CA) are not possible. If a certificate chain rooted in an appropriate CA) are not possible. If
server has such knowledge (typically from some source external to a server has such knowledge (typically from some source external to
NETCONF or TLS) it MUST check the identity as described above. NETCONF or TLS) it MUST check the identity as described above.
3.2. Password-Based Authentication for the NETCONF manager (TLS client) 3.3. Password-Based Authentication
RFC4279 supports authentication based on pre-shared keys (PSKs). [RFC4279] supports authentication based on pre-shared keys (PSKs).
These pre-shared keys are symmetric keys, shared in advance among the These pre-shared keys are symmetric keys, shared in advance among the
communicating parties. communicating parties.
The PSK can be generated in many ways and its length is variable. The PSK can be generated in many ways and its length is variable.
Implementation of this document MAY rely on RFC4279 to enable Implementation of this document MAY rely on [RFC4279] to enable
password based user authentication. In this case, the hashed version password based user authentication. In this case, the password is
of the password is stored is used to generate the PSK. It is used to generate the PSK. It is RECOMMENDED that implementations
RECOMMENDED that implementations that allow the administrator to that allow the administrator to manually configure the password also
manually configure the password also provide functionality for provide functionality for generating a new random password, taking
generating a new random password, taking RFC4086 into account. [RFC4086] into account.
This document generates the PSK from the password as follow: This document generates the PSK from the password as follow:
PSK = SHA-1(SHA-1(stored-hash + "Key Pad for Netconf") + PSK = SHA-1(SHA-1(password + psk_identity + "Key Pad for Netconf") +
psk_identity_hint) psk_identity_hint)
Where + means concatenation. Where + means concatenation.
The stored-hash is the hashed version of the password.
The label "Key Pad for Netconf" is an ASCII string. The label "Key Pad for Netconf" is an ASCII string.
The psk_identity_hint is initially defined in section 5.1 of RFC4279. The psk_identity_hint is initially defined in section 5.1 of
The psk_identity_hint can do double duty and also provide a form of [RFC4279]. The psk_identity_hint can do double duty and also provide
server authentication in the case where the user has the same a form of server authentication in the case where the user has the
password on a number of NETCONF agents. If a hint is provided, the same password on a number of NETCONF servers. If a hint is provided,
psk_identity_hint is encoded in the same way as in [RFC4279] and the psk_identity_hint is encoded in the same way as in [RFC4279] and
should be a string representation of the name of the server should be a string representation of the name of the server
recognizable to the administrator or his software. In the case where recognizable to the administrator or his software. In the case where
the user types a server name to connect to, it should be that string. the user types a server name to connect to, it should be that string.
If the string the user enters differs from the one returned as If the string the user enters differs from the one returned as
psk_identity_hint, the software could display the server's name and psk_identity_hint, the software could display the server's name and
ask the user to confirm. For automated scripts, the names could be ask the user to confirm. For automated scripts, the names could be
expected to match. It is highly recommended that implementations set expected to match. It is highly recommended that implementations set
the psk_identity_hint to the DNS name of the NETCONF agent (i.e., the the psk_identity_hint to the DNS name of the NETCONF server (i.e.,
TLS server). the TLS server).
4. Security Considerations It is RECOMMENDED that users choose different passwords for the
different servers they manage.
The security considerations described throughout [TLS] and [TLSPSK] Note 1: The NETCONF over TLS implementation need not store the
apply here as well. password in clear text, but rather can store the value of SHA-
1(SHA-1(password + psk_identity + "Key Pad for Netconf") +
psk_identity_hint), which could not be used as a password
equivalent for applications other than NETCONF. Deriving the PSK
from a password is not secure. This construction is used because
it is anticipated that people will do it anyway.
5. IANA Considerations Note 2: [RFC4279] defines some conformance requirements for the
PSK, for the PSK identity encoding and for the identity hint. The
same requirements apply here as well; in particular on the
password. Moreover, the management interface by which the
password is provided MUST accept ASCII strings of at least 64
octets and MUST NOT add a null terminator before using them as
shared secrets. It MUST also accept a HEX encoding of the
password. The management interface MAY accept other encodings if
the algorithm for translating the encoding to a binary string is
specified.
4. Cipher Suite Requirements
A compliant implementation of the protocol specified in this document
MUST implement the cipher suite TLS_DHE_PSK_WITH_AES_128_CBC_SHA and
MAY implement any TLS cipher suite that provides mutual
authentication.
5. Security Considerations
The security considerations described throughout [RFC4346] and
[RFC4279] apply here as well.
As with all schemes involving shared keys and passwords, special care
should be taken to protect the shared values and passwords as well as
to limit their exposure over time. Alternatively, using certificates
would provide better protection.
6. IANA Considerations
IANA is requested to assign a TCP port number that will be the IANA is requested to assign a TCP port number that will be the
default port for NETCONF over TLS sessions as defined in this default port for NETCONF over TLS sessions as defined in this
document. document.
IANA has assigned port <TBD> for this purpose. IANA has assigned port <TBA> for this purpose.
6. Acknowledgments 7. Acknowledgments
The author would like to acknowledge Eric Rescorla and Juergen A significant amount of the text in this document was lifted from
Schoenwaelder for their detailed reviews of the content of the [RFC4642].
document. The author appreciates also David Harrington, Miao Fuyou
and Dan Romascanu for their effort on issues resolving discussion, The author would like to acknowledge David Harrington, Miao Fuyou,
and Charlie Kaufman for his contribution on the password-based Eric Rescorla, Juergen Schoenwaelder and the NETCONF mailing list
members for their comments on the document. The author appreciates
also Bert Wijnen and Dan Romascanu for their efforts on issues
resolving discussion, and Charlie Kaufman for the thorough review of
this document and for the helpful comments on the password-based
authentication. authentication.
7. References 8. References
7.1. Normative References 8.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119, March 1997. Requirement Levels", BCP 14, RFC 2119, March 1997.
[NETCONF] Enns, R., "NETCONF Configuration Protocol", RFC 4741, [RFC3280] Housley, R., Polk, W., Ford, W., and D. Solo, "Internet
December 2006. X.509 Public Key Infrastructure Certificate and Certificate
Revocation List (CRL) Profile", RFC 3280, April 2002.
[TLS] Dierks, T. and E. Rescorla, "The TLS Protocol Version 1.1", [RFC4086] Eastlake, D., 3rd, Schiller, J., and S. Crocker,
RFC 4346, April 2005. "Randomness Requirements for Security", BCP 106, RFC 4086,
June 2005.
[TLSEXT] Blake-Wilson, S., et. al., "Transport Layer Security (TLS) [RFC4279] Eronen, P. and H. Tschofenig., "Pre-Shared Key Ciphersuites
Extensions", RFC 4346, April 2006. for Transport Layer Security (TLS)", RFC 4279, December
2005.
[TLSPSK] Eronen, P., et. al., "Pre-Shared Key Ciphersuites for [RFC4346] Dierks, T. and E. Rescorla, "The Transport Layer Security
Transport Layer Security (TLS)", RFC 4279, December 2005. (TLS) Protocol 1.1", RFC 4346, April 2006.
[RFC4366] Blake-Wilson, S., Nystrom, M., Hopwood, D., Mikkelsen, J.,
and T. Wright, "Transport Layer Security (TLS) Extensions",
RFC 4366, April 2006.
[RFC4642] Murchison, K., Vinocur, J., Newman, C., "Using Transport [RFC4642] Murchison, K., Vinocur, J., Newman, C., "Using Transport
Layer Security (TLS) with Network News Transfer Protocol Layer Security (TLS) with Network News Transfer Protocol
(NNTP)", RFC 4642, October 2006 (NNTP)", RFC 4642, October 2006
[PKICERT] Housley, R., Polk, W., Ford, W., and D. Solo, "Internet [RFC4741] Enns, R., "NETCONF Configuration Protocol", RFC 4741,
X.509 Public Key Infrastructure Certificate and Certificate December 2006.
Revocation List (CRL) Profile", RFC 3280, April 2002.
[NETSSH] Wasserman, M. and T. Goddard, "Using the NETCONF [RFC4742] Wasserman, M. and T. Goddard, "Using the NETCONF
Configuration Protocol over Secure Shell (SSH)", RFC 4742, Configuration Protocol over Secure Shell (SSH)", RFC 4742,
December 2006. December 2006.
[NETNOT] Chisholm, S. and H. Trevino, "NETCONF Event Notifications", [NETNOT] Chisholm, S. and H. Trevino, "NETCONF Event Notifications",
draft-ietf-netconf-notification-11.txt, (work in progress), draft-ietf-netconf-notification-11.txt, (work in progress),
November 2007. November 2007.
7.2. Informative References
[TLSKERB] Medvinsky, A. and M. Hur, "Addition of Kerberos Cipher
Suites to Transport Layer Security (TLS)", RFC 2712,
October 1999.
Author's Addresses Author's Addresses
Mohamad Badra Mohamad Badra
LIMOS Laboratory - UMR6158, CNRS LIMOS Laboratory - UMR6158, CNRS
France France
Email: badra@isima.fr Email: badra@isima.fr
Intellectual Property Statement Intellectual Property Statement
 End of changes. 39 change blocks. 
114 lines changed or deleted 153 lines changed or added

This html diff was produced by rfcdiff 1.34. The latest version is available from http://tools.ietf.org/tools/rfcdiff/