* @throws Exception ..
*/
// Package on purpose
- AAFAuthn(AAFCon<CLIENT> con) throws Exception {
+ AAFAuthn(AAFCon<CLIENT> con) {
super(con.access,con.cleanInterval,con.highCount,con.usageRefreshTriggerCount);
this.con = con;
}
*
* Convenience function. Passes "null" for State object
*/
- public String validate(String user, String password) throws IOException, CadiException {
+ public String validate(String user, String password) throws IOException {
return validate(user,password,null);
}
* @throws CadiException
* @throws Exception
*/
- public String validate(String user, String password, Object state) throws IOException, CadiException {
+ public String validate(String user, String password, Object state) throws IOException {
password = access.decrypt(password, false);
byte[] bytes = password.getBytes();
User<AAFPermission> usr = getUser(user,bytes);
}
}
- AAFCachedPrincipal cp = new AAFCachedPrincipal(this,con.app, user, bytes, con.cleanInterval);
+ AAFCachedPrincipal cp = new AAFCachedPrincipal(user, bytes, con.cleanInterval);
// Since I've relocated the Validation piece in the Principal, just revalidate, then do Switch
// Statement
switch(cp.revalidate(state)) {
}
private class AAFCachedPrincipal extends ConfigPrincipal implements CachedPrincipal {
- private long expires,timeToLive;
+ private long expires;
+ private long timeToLive;
- public AAFCachedPrincipal(AAFAuthn<?> aaf, String app, String name, byte[] pass, int timeToLive) {
+ private AAFCachedPrincipal(String name, byte[] pass, int timeToLive) {
super(name,pass);
this.timeToLive = timeToLive;
expires = timeToLive + System.currentTimeMillis();
public long expires() {
return expires;
}
- };
+ }
}