RADIUS Client API (V3)

com.theorem.radius3.eap
Class EAPMD5Client

Object
  extended byEAPClient
      extended byEAPMD5Client

public final class EAPMD5Client
extends EAPClient

Class to handle EAP MD5 authentication.


Field Summary
 
Fields inherited from class EAPClient
radClient
 
Constructor Summary
EAPMD5Client(byte[] name, InetAddress server, int port, String secret, int timeout, InetAddress nasIPAddress, String nasIdentifier)
          EAP MD5 client constructor.
EAPMD5Client(byte[] name, RADIUSClient radClient, InetAddress nasIPAddress, String nasIdentifier)
          EAP MD5 client constructor.
EAPMD5Client(RADIUSClient rc, AttributeList commonList)
          EAP MD5 client constructor.
 
Method Summary
 boolean authenticate(byte[] password)
          Perform an authentication with the name given to the constructor.
 boolean authenticate(byte[] name, byte[] password)
          Perform the EAP MD5 authethentication with a new name.
 void setAttributes(AttributeList local)
          Add local attributes to the EAP transactions.
 
Methods inherited from class EAPClient
addAttributes, createPacketId, debug, getAttributes, getEAPPacket, logToDebug, reset, send, setDebug, setDebug
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EAPMD5Client

public EAPMD5Client(RADIUSClient rc,
                    AttributeList commonList)
             throws EAPException
EAP MD5 client constructor. One of the nasIPAddress or the nasIdentifier should exist. It is recommended that both not be defined in the common attribute list.

Parameters:
rc - RADIUSClient.
commonList - List of common attributes (User-Name, NAS-IP-Address, NAS-Identifier and so on).
Throws:
EAPException - if the server cannot be found.

EAPMD5Client

public EAPMD5Client(byte[] name,
                    InetAddress server,
                    int port,
                    String secret,
                    int timeout,
                    InetAddress nasIPAddress,
                    String nasIdentifier)
             throws EAPException
EAP MD5 client constructor. One of the nasIPAddress or the nasIdentifier should exist. It is recommended that both not be defined.

Parameters:
name - User-Name attribute value.
nasIPAddress - Client NAS-IP-Address value or null.
nasIdentifier - Client NAS-Identifier value or null.
server - RADIUS server address.
port - RADIUS server port
secret - RADIUS server shared secret.
timeout - Packet round trip timeout in milliseconds.
Throws:
EAPException - if the server cannot be found.

EAPMD5Client

public EAPMD5Client(byte[] name,
                    RADIUSClient radClient,
                    InetAddress nasIPAddress,
                    String nasIdentifier)
             throws EAPException
EAP MD5 client constructor. One of the nasIPAddress or the nasIdentifier should exist. It is recommended that both not be defined.

Parameters:
name - User-Name attribute value.
radClient - Existing RADIUSClient.
nasIPAddress - Client NAS-IP-Address value or null.
nasIdentifier - Client NAS-Identifier value or null.
Throws:
EAPException - if the server cannot be found.
Method Detail

authenticate

public boolean authenticate(byte[] password)
                     throws EAPException
Perform an authentication with the name given to the constructor.

Parameters:
password -
Throws:
EAPException - if there is a problem during authentication.

authenticate

public boolean authenticate(byte[] name,
                            byte[] password)
                     throws EAPException
Perform the EAP MD5 authethentication with a new name.

Parameters:
name - EAP Identity.
password - Authentication password.
Throws:
EAPException - if there is a problem during authentication.

setAttributes

public void setAttributes(AttributeList local)
Add local attributes to the EAP transactions.

These must not include User-Name, NAS-IP-Address, NAS-Identifier, Message-Authenticator, nor EAP-Message which are included automatically.

This list will replace any local attributes previously set by this method.

Parameters:
local - Locally added attributes.

RADIUS Client API (V3)

Submit a bug report or feature request

Copyright 1998-2008 AXL Software. PO Box 97, Viola, Delaware 19979, U.S.A. All Rights Reserved.