5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * The contents of this file are subject to the terms of the Common Development and
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * Distribution License (the License). You may not use this file except in compliance with the
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * specific language governing permission and limitations under the License.
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * When distributing Covered Software, include this CDDL Header Notice in each file and include
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * Header, with the fields enclosed by brackets [] replaced by your own identifying
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * information: "Portions copyright [year] [name of copyright owner]".
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * Portions Copyrighted 2011 ForgeRock AS
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * Portions Copyrighted 2015 Intellectual Reserve, Inc (IRI)
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * This package in large part contains the objects that model the RADIUS protocol specified in RFC 2865. The objects
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * that implement the protocol include the four packet types, authenticators for request and response packet types,
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * and all attribute fields. All attribute fields support two constructors. To be clear RFC 2865 refers to the
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * on-the-wire bytes that represent a RADIUS object as the octets of that object where an octet is a single eight bit
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * byte. One constructor for each attribute takes the octets and is responsible for extracting the model type
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * represented by the value of that attribute. The other constructor takes the model object represented by the value
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * of that attribute and generates the octets that can we sent on the wire for that attribute.
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * When a RADIUS packet is received either in the RADIUS authentication module acting as a RADIUS client or in
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * the RADIUS server, the on-the-wire octets are passed to the
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * {@link org.forgerock.openam.radius.common.PacketFactory} which splits instantiates the
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * appropriate packet type with injected id, authenticator, and attributes found in the received octets.
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * When preparing a packet from model objects in order to send it, the constructor on the packet type is used and
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * then the attributes to be sent within the packet are then injected in. Once the packet is reacy its getOctets
5c124de5c36bfc236d55578429df5f048f0d0a07Jamie Bowen * method will return the on-the-wire representation of the packet.