Network Working Group G. Zorn, Ed. Internet-Draft Network Zen Updates: 2865, 2866 November 17, 2008 (if approved) Intended status: Informational Expires: May 21, 2009 RADIUS Error Messages draft-zorn-radius-err-msg-10.txt Status of this Memo By submitting this Internet-Draft, each author represents that any 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 aware will be disclosed, in accordance with Section 6 of BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt. The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. This Internet-Draft will expire on May 21, 2009. Copyright Notice Copyright (C) The IETF Trust (2008). Abstract This document describes new RADIUS protocol elements designed to allow the communication of packet and attribute errors between RADIUS servers and clients. Zorn Expires May 21, 2009 [Page 1] Internet-Draft RADIUS Error Messages November 2008 Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 2. Specification of Requirements . . . . . . . . . . . . . . . . 3 3. RADIUS Packet Format . . . . . . . . . . . . . . . . . . . . . 3 4. Packet Types . . . . . . . . . . . . . . . . . . . . . . . . . 6 4.1. Error-Notification . . . . . . . . . . . . . . . . . . . . 6 5. Attributes . . . . . . . . . . . . . . . . . . . . . . . . . . 7 5.1. Error-Code . . . . . . . . . . . . . . . . . . . . . . . . 7 6. Attribute Values . . . . . . . . . . . . . . . . . . . . . . . 8 6.1. Acct-Error-Notification . . . . . . . . . . . . . . . . . 9 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 9 8. Security Considerations . . . . . . . . . . . . . . . . . . . 9 9. Normative References . . . . . . . . . . . . . . . . . . . . . 9 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 9 Intellectual Property and Copyright Statements . . . . . . . . . . 11 Zorn Expires May 21, 2009 [Page 2] Internet-Draft RADIUS Error Messages November 2008 1. Introduction The RADIUS protocol [RFC2865] is defined to allow most errors to be ignored and to silently discard unrecognized or erroneous packets. In many cases, this behavior is beneficial or at least innocuous. For example, it's probably a good idea to discard messages from unknown clients and server messages having incorrect authenticators, and discarding short packets doesn't seem to hurt anything. In some cases, however, this policy can cause interoperability problems and may result in the provision of incorrect services to users, particularly in roaming situations. Because RADIUS packets having unknown values in the Code field of the header are silently discarded it is difficult to ascertain whether a new packet type is considered invalid by the remote client/server or if the message was simply lost. Similarly, RFC 2865 allows clients to ignore unrecognized attributes, which can lead to incorrect service provisioning. This document defines a set of messages and attributes that can be used to notify a RADIUS client or server of various message errors. Discussion of this draft may be directed to the author. 2. Specification of Requirements The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119]. 3. RADIUS Packet Format Exactly one RADIUS packet is encapsulated in the UDP Data field [RFC0768] where the UDP Destination Port field indicates 1812 (decimal). When a reply is generated, the source and destination ports are reversed. A summary of the RADIUS data format is shown below. The fields are transmitted from left to right. Zorn Expires May 21, 2009 [Page 3] Internet-Draft RADIUS Error Messages November 2008 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Code | Identifier | Length | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | | | Authenticator | | | | | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Attributes ... +-+-+-+-+-+-+-+-+-+-+-+-+- Code The Code field is one octet, and identifies the type of RADIUS packet. When a client receives a packet with an invalid Code field, it is silently discarded. If a server receives a packet with an invalid Code field from a valid client, it SHOULD reply with an Error-Notification packet (section 4.1); if the server does not support the Error Notification packet, it MUST silently discard the received packet. The RADIUS Codes (decimal) defined in this document are as follows: Error-Notification Identifier The Identifier field is one octet, and aids in matching requests, replies and notifications. The RADIUS server can detect a duplicate request if it has the same client source IP address, source UDP port and Identifier within a short span of time. Length The Length field is two octets. It indicates the length of the packet including the Code, Identifier, Length, Authenticator and Attribute fields. Octets outside the range of the Length field MUST be treated as padding and ignored on reception. If the packet is shorter than the Length field indicates, it MUST be silently discarded. The minimum length is 20 and maximum length is 4096. Zorn Expires May 21, 2009 [Page 4] Internet-Draft RADIUS Error Messages November 2008 Authenticator The Authenticator field is sixteen (16) octets. The most significant octet is transmitted first. This value is used to authenticate the reply from the RADIUS server. Notification Authenticator The value of the Authenticator field in the Error- Notification packet is called the Notification Authenticator, and contains a one-way MD5 hash calculated over a stream of octets consisting of: the RADIUS packet, beginning with the Code field, including the Identifier, the Length, the Authenticator field from the packet to which this packet is a response, and the response Attributes, followed by the shared secret. That is, Notification Auth = MD5(Code+ID+Length+RequestAuth+Attributes+Secret) where '+' denotes concatenation. Administrative Note The secret shared between the client and the RADIUS server SHOULD be at least as large and unguessable as a well-chosen password. It is preferred that the secret be at least 16 octets. This is to ensure a sufficiently large range for the secret to provide protection against exhaustive search attacks. The secret MUST NOT be empty (length 0) since this would allow packets to be trivially forged. A RADIUS server MUST use the source IP address of the RADIUS UDP packet to decide which shared secret to use, so that RADIUS requests can be proxied. When using a forwarding proxy, the proxy must be able to alter the packet as it passes through in each direction - when the proxy forwards the request, the proxy MAY add a Proxy-State Attribute, and when the proxy forwards a response, it MUST remove its Proxy-State Attribute if it added one. Proxy-State is always added or removed after any other Proxy-States, but no other assumptions regarding its location within the list of attributes can be made. Since Access-Accept and Access-Reject replies are authenticated on the entire packet contents, the stripping of the Proxy-State attribute invalidates the signature in the packet - so the proxy has to re-sign it. Further details of RADIUS proxy implementation are outside the Zorn Expires May 21, 2009 [Page 5] Internet-Draft RADIUS Error Messages November 2008 scope of this document. 4. Packet Types The RADIUS Packet type is determined by the Code field in the first octet of the Packet. 4.1. Error-Notification Description Error-Notification packets are sent by a RADIUS server as an indication that a previous request contained one or more errors. A RADIUS server wishing to notify a client that one or more errors occurred MUST transmit a RADIUS packet with the Code field set to (Error-Notification). Error-Notification packets MUST contain at least one Error-Code Attribute. A summary of the Error-Notification packet format is shown below. The fields are transmitted from left to right. 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Code | Identifier | Length | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | | | Notification Authenticator | | | | | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Attributes ... +-+-+-+-+-+-+-+-+-+-+-+-+- Code for Error-Notification Identifier The Identifier field is a copy of the Identifier field of the packet which caused this Error-Notification packet to be Zorn Expires May 21, 2009 [Page 6] Internet-Draft RADIUS Error Messages November 2008 created. Notification Authenticator The Notification Authenticator value is calculated from the Error-Notification packet, as described above. Attributes The Attribute field is variable in length, and contains any desired optional Attributes in addition to the required Attributes. 5. Attributes 5.1. Error-Code Description This attribute contains a code identifying the class of error that occurred, a code signifying the error itself and an optional text description of the error. The Error-Code Attribute MUST be included in Error-Notification packets sent from a server. RADIUS Accounting [RFC2866] clients MUST include this Attribute in Accounting-Request packets in which the Acct-Status-Type Attribute has a value of Acct-Error-Notification (see below). A summary of the Error-Code Attribute format is shown below. The fields are transmitted from left to right. 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Type | Length | Class | Code | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Code (cont'd.)| String... +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Zorn Expires May 21, 2009 [Page 7] Internet-Draft RADIUS Error Messages November 2008 Type for Error-Code. Length >= 4 Class The CLASS field contains a single ASCII character indicating the severity of the error. This document defines the following error classes: F The error was fatal and the message causing the error was discarded. W Warning error: the message was processed, but the result may not be as anticipated. Code The Code field contains an unsigned integer representing the type of error that occurred. This document defines the following decimal values for the Code field: 1 Unrecognized Packet Type 2 Unrecognized Vendor OUI 3 Unrecognized Attribute 4 Unknown Session Identifier 5 Unknown Key Identifier String The optional String field contains a text description of the error. When the Error-Code Attribute is used in Accounting- Request packets, the String field SHOULD contain a message describing the error. 6. Attribute Values The following sub-sections defines a new value for the Acct-Status- Type Attribute [RFC2866]. Zorn Expires May 21, 2009 [Page 8] Internet-Draft RADIUS Error Messages November 2008 6.1. Acct-Error-Notification Description When the value is present in the Value field of an Acct- Status-Type Attribute in an Accounting-Request packet, it signifies that one or more errors have occurred on the client side. 7. IANA Considerations The criteria to be used by the Internet Assigned Numbers Authority (IANA) for assignment of numbers within namespaces defined within this document are identical to those given in [RFC3575]. 8. Security Considerations None. 9. Normative References [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, August 1980. [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997. [RFC2865] Rigney, C., Willens, S., Rubens, A., and W. Simpson, "Remote Authentication Dial In User Service (RADIUS)", RFC 2865, June 2000. [RFC2866] Rigney, C., "RADIUS Accounting", RFC 2866, June 2000. [RFC3575] Aboba, B., "IANA Considerations for RADIUS (Remote Authentication Dial In User Service)", RFC 3575, July 2003. Zorn Expires May 21, 2009 [Page 9] Internet-Draft RADIUS Error Messages November 2008 Author's Address Glen Zorn (editor) Network Zen 1310 East Thomas Street Seattle, Washington 98102 US Phone: +1 (206) 377-9035 Email: gwz@net-zen.net Zorn Expires May 21, 2009 [Page 10] Internet-Draft RADIUS Error Messages November 2008 Full Copyright Statement Copyright (C) The IETF Trust (2008). This document is subject to the rights, licenses and restrictions contained in BCP 78, and except as set forth therein, the authors retain all their rights. This document and the information contained herein are provided on an "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Intellectual Property The IETF takes no position regarding the validity or scope of any Intellectual Property Rights or other rights that might be claimed to pertain to the implementation or use of the technology described in this document or the extent to which any license under such rights might or might not be available; nor does it represent that it has made any independent effort to identify any such rights. Information on the procedures with respect to rights in RFC documents can be found in BCP 78 and BCP 79. Copies of IPR disclosures made to the IETF Secretariat and any assurances of licenses to be made available, or the result of an attempt made to obtain a general license or permission for the use of such proprietary rights by implementers or users of this specification can be obtained from the IETF on-line IPR repository at http://www.ietf.org/ipr. The IETF invites any interested party to bring to its attention any copyrights, patents or patent applications, or other proprietary rights that may cover technology that may be required to implement this standard. Please address the information to the IETF at ietf-ipr@ietf.org. Acknowledgment Funding for the RFC Editor function is provided by the IETF Administrative Support Activity (IASA). Zorn Expires May 21, 2009 [Page 11]