Class SecurityContext
java.lang.Object
com.j_spaces.core.SecurityContext
- All Implemented Interfaces:
SmartExternalizable, Externalizable, Serializable
Deprecated.
The SecurityContext class defines security info passed from the proxy to the space, and is used
by the security filters to validate access to space functions.
- Version:
- 1.0
- Author:
- Yechiel Fefer
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringDeprecated.Default user name and password, when default constructor is used.static final charDeprecated.Admin functions permission.static final charDeprecated.Task executions permissionstatic final charDeprecated.Read permission.static final charDeprecated.Write/Take/Update/Replace permission. -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated.The default constructor shall create a security context used forANONYMOUS_USERuser account.SecurityContext(String username, String password) Deprecated.Create new security context. -
Method Summary
Modifier and TypeMethodDescriptionvoidDeprecated.Disable all operations to user represented by this security context.Deprecated.Get the implementation specific free context.Deprecated.Gets the password.Deprecated.Gets the the permissionString.Deprecated.Gets user name.booleanDeprecated.Check is encrypted.booleanDeprecated.voidDeprecated.voidsetEncrypted(boolean isEncrypted) Deprecated.Set indicator if encrypted.voidsetImplementorContext(Object implementorContext) Deprecated.Set implementation specific free context, must implement Serializable.voidsetInitialized(boolean initialized) Deprecated.voidsetPassword(String pass) Deprecated.Sets password.voidsetPermissions(String permissions) Deprecated.Set the permission.voidsetUsername(String username) Deprecated.Sets user name.voidDeprecated.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface SmartExternalizable
enabledSmartExternalizableWithReference
-
Field Details
-
PERMISSION_READ
public static final char PERMISSION_READDeprecated.Read permission.- See Also:
-
PERMISSION_WRITE
public static final char PERMISSION_WRITEDeprecated.Write/Take/Update/Replace permission.- See Also:
-
PERMISSION_ADMIN
public static final char PERMISSION_ADMINDeprecated.Admin functions permission.- See Also:
-
PERMISSION_EXECUTE
public static final char PERMISSION_EXECUTEDeprecated.Task executions permission- See Also:
-
ANONYMOUS_USER
Deprecated.Default user name and password, when default constructor is used.- See Also:
-
-
Constructor Details
-
SecurityContext
public SecurityContext()Deprecated.The default constructor shall create a security context used forANONYMOUS_USERuser account. -
SecurityContext
-
-
Method Details
-
disableAllOperations
public void disableAllOperations()Deprecated.Disable all operations to user represented by this security context. -
writeExternal
Deprecated.- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
readExternal
Deprecated.- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
setUsername
Deprecated.Sets user name.- Parameters:
username- the user name
-
getUsername
-
setPassword
-
getPassword
-
setEncrypted
public void setEncrypted(boolean isEncrypted) Deprecated.Set indicator if encrypted.- Parameters:
isEncrypted-trueif encrypted
-
isEncrypted
public boolean isEncrypted()Deprecated.Check is encrypted.- Returns:
trueif encrypted
-
setPermissions
Deprecated.Set the permission.For example:
SecurityContext context = ...; context.setPermissions("" + PERMISSION_WRITE + PERMISSION_READ); // read invalid input: '&' write permission- Parameters:
permissions- the permission string
-
getPermissions
Deprecated.Gets the the permissionString.- Returns:
- the permission
String - See Also:
-
setImplementorContext
Deprecated.Set implementation specific free context, must implement Serializable. This can be used to attach a metadata to the context.- Parameters:
implementorContext- implementation specific free context
-
getImplementorContext
Deprecated.Get the implementation specific free context.- Returns:
- implementation specific free context
- See Also:
-
isInitialized
public boolean isInitialized()Deprecated. -
setInitialized
public void setInitialized(boolean initialized) Deprecated.
-