/*
* Program: UsernameToken.java
* Purpose: object class to encapsulate username token
* @author Ray Lai (ray.lai@sun.com)
* @version 1.1
* Updated: April 16, 2005
* Copyright: (c) 2005 by Sun Microsystems/Ray Lai under Common Development and Distribution License
* Remarks: Full program and documentation will be available under developer.java.net
* For simplicity, logger class is removed.
* =====================================================================================
*/
package com.csp.identity;
public class UsernameToken extends com.csp.identity.SecurityToken {
protected static String password;
static final String TOKEN_TYPE = "USERNAME_TOKEN";
/** Constructor - create usernameToken
*
* In future implementation, the constructor should be private, and this class
* should provide a getInstance() to fetch the instance.
*/
public UsernameToken(String principal, String password) {
this.principal = principal;
this.password = password;
}
/**
* Get token id from the binary token
*
* @return binaryToken security token in binary form
*/
public String getToken() {
return this.password;
}
}