org.csapi.jr.se.fw.fw_access.trust_and_security
Interface ClientAPILevelAuthentication
- All Superinterfaces:
- CsapiInterface, java.io.Serializable
- public interface ClientAPILevelAuthentication
- extends CsapiInterface
If the IpClientAPILevelAuthentication interface is implemented by a client, challenge(), abortAuthentication() and authenticationSucceeded() methods shall be implemented.
|
Method Summary |
void |
abortAuthentication()
The framework uses this method to abort the authentication process where the client is authenticating the Framework. |
void |
authenticationSucceeded()
The Framework uses this method to inform the client of the success of the authentication attempt. |
byte[] |
challenge(byte[] challenge)
This method is used by the framework to authenticate the client. |
abortAuthentication
public void abortAuthentication()
- The framework uses this method to abort the authentication process where the client is authenticating the Framework. This method is invoked if the framework wishes to abort the authentication process before it has been authenticated by the client, (unless the client responded incorrectly to a challenge in which case no further communication with the client should occur.) Calls to this method after the Framework has been authenticated by the client shall not result in an immediate removal of the Framework's authentication (the client may wish to authenticate the Framework again, however).
authenticationSucceeded
public void authenticationSucceeded()
- The Framework uses this method to inform the client of the success of the authentication attempt. The client may invoke requestAccess on the Framework's APILevelAuthentication interface following invocation of this method.
challenge
public byte[] challenge(byte[] challenge)
- This method is used by the framework to authenticate the client. The client must respond with the correct responses to the challenges presented by the framework. The number of exchanges is dependent on the policies of each side. The authentication of the client is deemed successful when the authenticationSucceeded method is invoked by the Framework.
The invocation of this method may be interleaved with challenge() calls by the client on the IpAPILevelAuthentication interface. The client shall respond immediately to authentication challenges from the Framework, and not wait until the Framework has responded to any challenge the client may issue.
- Parameters:
challenge - The challenge presented by the framework to be responded to by the client. The challenge format used will be in accordance with the IETF PPP Authentication Protocols - Challenge Handshake Authentication Protocol (RFC 1994).
The challenge octet set must be formatted as a CHAP Challenge packet as defined in section 4.1 of RFC 1994. A complete and properly formatted CHAP Challenge packet must be used. The Name field of the CHAP Challenge packet must be present and contain a valid value in order for the CHAP Response to be valid. However, the Name field is not used in the authentication process.
Steps for constructing the challenge octet set
1. Create a random challenge value (octet set). Per RFC 1994, this value must between 1 and 255 octets in length.
2. Construct a CHAP Challenge packet based on 4.1 of RFC 1994 with the octet set from the previous step passed in the Value field within the CHAP Challenge.
- Returns:
- response This is the response of the client application to the challenge of the framework in the current sequence. The formatting and construction of this parameter shall be according to section 4.1 of RFC 1994. A complete CHAP Response packet shall be used to carry the response octet set. That octet set will be the result of applying the designated hashing algorithm, which is indicated via the client's invocation of selectAuthenticationMechanism(), to an octet set consisting of the concatenation of the CHAP Identifier, the shared "secret", and the supplied challenge value. The Name field of the CHAP Response packet must be present and contain a valid value in order for the CHAP Response to be valid. However, the Name field is not used in the authentication process.
Steps for constructing the response octet set
1. Extract the Identifier and Value fields from the CHAP Challenge packet passed in the challenge() method's challenge parameter
2. Build an octet set consisting of the concatenation of the Identifier, the "shared secret", and the Value from the CHAP Challenge
3. Compute the hash of the octet set resulting from the previous step using the designated hashing algorithm
4. Construct a complete CHAP Response packet with the resulting octet set from previous step as the CHAP Value
Steps for validating the response octet set
1. Verify that the Identifier sent in the original CHAP Challenge matches the Identifier received in the CHAP Response. If it does not, authentication fails.
2. Build an octet set consisting of the concatenation of the original Identifier, the "shared secret", and the original challenge value
3. Compute the hash of the resulting octet set from the previous step using the designated hashing algorithm
4. Verify the octet set resulting from the previous step matches the octet set contained in the Value field of the CHAP Response. A match indicates successful authentication.