Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle ADF Share
11g Release 1 (11.1.1)

E10686-03


oracle.adf.share.security
Interface SecurityContext

All Superinterfaces:
javax.naming.Context
All Known Implementing Classes:
JpsSecurityContext, SecurityContextImpl

public interface SecurityContext
extends javax.naming.Context

Field Summary

 

Fields inherited from interface javax.naming.Context
APPLET, AUTHORITATIVE, BATCHSIZE, DNS_URL, INITIAL_CONTEXT_FACTORY, LANGUAGE, OBJECT_FACTORIES, PROVIDER_URL, REFERRAL, SECURITY_AUTHENTICATION, SECURITY_CREDENTIALS, SECURITY_PRINCIPAL, SECURITY_PROTOCOL, STATE_FACTORIES, URL_PKG_PREFIXES

 

Method Summary
 boolean attachToLightweightSession(java.sql.Connection conn)
          Attach connection to lightweight XS session
 java.security.Permission createPermissionInstance(java.util.Hashtable values)
          Create a FunctionPermission, DataPermission or Permission.
 boolean detachFromLightweightSession()
          Detach connection from lightweight XS session
 java.lang.Object getAttachedLightweightSession()
          Return the attached lightweight XS session
 PermissionState getPermissionState()
          Internal: Applications should not use this method. Return the current active PermissionState
 javax.security.auth.Subject getSubject()
          Retrieves the subject in the SecurityContext or AccessController context.
 java.lang.String getUserName()
          Retrieves the name of principal of this SecurityContext.
 java.security.Principal getUserPrincipal()
          Retrieves the principal of this SecurityContext.
 UserProfile getUserProfile()
          Retrieves the user profile object of this SecurityContext.
 java.lang.String[] getUserRoles()
          A list of role names in the Subject
 boolean hasPermission(java.security.Permission permission)
          True if the principal in this SecurityContext has the permission
 boolean isAnyoneEnabled()
          Internal: Applications should not use this class. True if anyone role is enable
 boolean isAuthenticated()
          True if authenticated
 boolean isAuthenticationEnabled()
          True if authenticationRequired set
 boolean isAuthorizationEnabled()
          True if authorization check is enable
 boolean isPageSecurityMetadataEnabled()
          True if page security metadata is enable.
 boolean isReAuthenticated(long ts)
          True if re-authenticated since last time
 boolean isUserInRole(java.lang.String roleName)
          True if user is in the specified role
 boolean isXSMode()
          True is using DB Extensible Security (XS)
 void setPermissionState(PermissionState permissionState)
          Internal: Applications should not use this method. Set the PermissionState

 

Methods inherited from interface javax.naming.Context
addToEnvironment, bind, bind, close, composeName, composeName, createSubcontext, createSubcontext, destroySubcontext, destroySubcontext, getEnvironment, getNameInNamespace, getNameParser, getNameParser, list, list, listBindings, listBindings, lookup, lookup, lookupLink, lookupLink, rebind, rebind, removeFromEnvironment, rename, rename, unbind, unbind

 

Method Detail

getUserPrincipal

java.security.Principal getUserPrincipal()
Retrieves the principal of this SecurityContext. It is the current authenticated user principal obtained from the HttpServletRequest.getUserPrincipal()
Returns:
the user principal

getUserName

java.lang.String getUserName()
Retrieves the name of principal of this SecurityContext.
Returns:
the name of the user principal

getUserProfile

UserProfile getUserProfile()
Retrieves the user profile object of this SecurityContext.
Returns:
the user profile object

hasPermission

boolean hasPermission(java.security.Permission permission)
True if the principal in this SecurityContext has the permission
Parameters:
permission - the permission to be checked
Returns:
true if the principal has the specified permission.

isAuthorizationEnabled

boolean isAuthorizationEnabled()
True if authorization check is enable
Returns:
true if authorization check should be performed.

isAuthenticationEnabled

boolean isAuthenticationEnabled()
True if authenticationRequired set
Returns:
true if authentication require flag set to be enforced by security constraints.

isAuthenticated

boolean isAuthenticated()
True if authenticated
Returns:
true if there is an authenticated user.

isUserInRole

boolean isUserInRole(java.lang.String roleName)
True if user is in the specified role
Returns:
true if current user in the role.

getUserRoles

java.lang.String[] getUserRoles()
A list of role names in the Subject
Returns:
a list of role principal names

getSubject

javax.security.auth.Subject getSubject()
Retrieves the subject in the SecurityContext or AccessController context.
Returns:
the current Subject

isAnyoneEnabled

boolean isAnyoneEnabled()
Internal: Applications should not use this class. True if anyone role is enable
Returns:
true if authorization check should be performed.

createPermissionInstance

java.security.Permission createPermissionInstance(java.util.Hashtable values)
Create a FunctionPermission, DataPermission or Permission. The hashtable specfied the permission types, privilge name and namespace.
Returns:
a permission instance

isXSMode

boolean isXSMode()
True is using DB Extensible Security (XS)

attachToLightweightSession

boolean attachToLightweightSession(java.sql.Connection conn)
Attach connection to lightweight XS session

detachFromLightweightSession

boolean detachFromLightweightSession()
Detach connection from lightweight XS session

getAttachedLightweightSession

java.lang.Object getAttachedLightweightSession()
Return the attached lightweight XS session

isReAuthenticated

boolean isReAuthenticated(long ts)
True if re-authenticated since last time

isPageSecurityMetadataEnabled

boolean isPageSecurityMetadataEnabled()
True if page security metadata is enable. The default is false if pageSecurityMetadataEnable not set in adf-config.xml

getPermissionState

PermissionState getPermissionState()
Internal: Applications should not use this method. Return the current active PermissionState

setPermissionState

void setPermissionState(PermissionState permissionState)
Internal: Applications should not use this method. Set the PermissionState
Parameters:
permissionState - the active permission state

Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle ADF Share
11g Release 1 (11.1.1)

E10686-03


Copyright © 1997, 2009, Oracle. All rights reserved.