hudson.plugins.collabnet.auth
Class CNAuthentication

java.lang.Object
  extended by hudson.plugins.collabnet.auth.CNAuthentication
All Implemented Interfaces:
java.io.Serializable, java.security.Principal, org.acegisecurity.Authentication

public class CNAuthentication
extends java.lang.Object
implements org.acegisecurity.Authentication

Authentication class for CollabNet.

See Also:
Serialized Form

Field Summary
static java.lang.String SUPER_USER
           
 
Constructor Summary
CNAuthentication(java.lang.Object principal, java.lang.Object credentials)
           
 
Method Summary
 org.acegisecurity.GrantedAuthority[] getAuthorities()
           
 java.lang.Object getCredentials()
           
 java.lang.Object getDetails()
           
 java.lang.String getName()
           
 java.lang.Object getPrincipal()
           
 java.lang.String getSessionId()
           
 boolean isAuthenticated()
           
 boolean isCNAuthed()
           
 boolean isMember(java.lang.String group)
           
 void setAuthenticated(boolean authenticated)
           
 void setCNAuthed(boolean cnauthed)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.security.Principal
equals, hashCode
 

Field Detail

SUPER_USER

public static final java.lang.String SUPER_USER
See Also:
Constant Field Values
Constructor Detail

CNAuthentication

public CNAuthentication(java.lang.Object principal,
                        java.lang.Object credentials)
Method Detail

setAuthenticated

public void setAuthenticated(boolean authenticated)
Specified by:
setAuthenticated in interface org.acegisecurity.Authentication

isAuthenticated

public boolean isAuthenticated()
Specified by:
isAuthenticated in interface org.acegisecurity.Authentication

getAuthorities

public org.acegisecurity.GrantedAuthority[] getAuthorities()
Specified by:
getAuthorities in interface org.acegisecurity.Authentication
Returns:
a copy of the granted authorities.

getPrincipal

public java.lang.Object getPrincipal()
Specified by:
getPrincipal in interface org.acegisecurity.Authentication

getName

public java.lang.String getName()
Specified by:
getName in interface java.security.Principal

getDetails

public java.lang.Object getDetails()
Specified by:
getDetails in interface org.acegisecurity.Authentication

getCredentials

public java.lang.Object getCredentials()
Specified by:
getCredentials in interface org.acegisecurity.Authentication

isMember

public boolean isMember(java.lang.String group)
Parameters:
group - name of a CN group.
Returns:
true if the user is a member of the given group.

toString

public java.lang.String toString()
Specified by:
toString in interface java.security.Principal
Overrides:
toString in class java.lang.Object

isCNAuthed

public boolean isCNAuthed()

setCNAuthed

public void setCNAuthed(boolean cnauthed)

getSessionId

public java.lang.String getSessionId()


Copyright © 2010. All Rights Reserved.