Package org.globus.gsi.gssapi.auth
Class SelfAuthorization
- java.lang.Object
-
- org.globus.gsi.gssapi.auth.Authorization
-
- org.globus.gsi.gssapi.auth.GSSAuthorization
-
- org.globus.gsi.gssapi.auth.SelfAuthorization
-
public class SelfAuthorization extends GSSAuthorization
Performs the identity authorization check. The identity is obtained from specified Globus credentials.
-
-
Field Summary
Fields Modifier and Type Field Description private static SelfAuthorization
authorization
private static org.apache.commons.logging.Log
logger
-
Constructor Summary
Constructors Constructor Description SelfAuthorization()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
authorize(org.ietf.jgss.GSSContext context, java.lang.String host)
Performs self authorization.org.ietf.jgss.GSSName
getExpectedName(org.ietf.jgss.GSSCredential cred, java.lang.String host)
Returns expectedGSSName
used for authorization purposes.static SelfAuthorization
getInstance()
Returns a single instance of this class.-
Methods inherited from class org.globus.gsi.gssapi.auth.Authorization
generateAuthorizationException
-
-
-
-
Field Detail
-
logger
private static org.apache.commons.logging.Log logger
-
authorization
private static SelfAuthorization authorization
-
-
Method Detail
-
getInstance
public static SelfAuthorization getInstance()
Returns a single instance of this class.- Returns:
- the instance of this class.
-
getExpectedName
public org.ietf.jgss.GSSName getExpectedName(org.ietf.jgss.GSSCredential cred, java.lang.String host) throws org.ietf.jgss.GSSException
Description copied from class:GSSAuthorization
Returns expectedGSSName
used for authorization purposes. Can returns null for self authorization.- Specified by:
getExpectedName
in classGSSAuthorization
- Parameters:
cred
- credentials usedhost
- host address of the peer.- Throws:
org.ietf.jgss.GSSException
- if unable to create the name.
-
authorize
public void authorize(org.ietf.jgss.GSSContext context, java.lang.String host) throws AuthorizationException
Performs self authorization.- Specified by:
authorize
in classAuthorization
- Parameters:
context
- the securit contexthost
- host address of the peer.- Throws:
AuthorizationException
- if the peer is not authorized to access/use the resource.
-
-