Class PolicyDecisionUtils


  • public class PolicyDecisionUtils
    extends Object
    The class provides some policy utility methods to be used by authentication service for Resource/IP/Environment based authentication.
    • Constructor Detail

      • PolicyDecisionUtils

        public PolicyDecisionUtils()
    • Method Detail

      • doResourceIPEnvAuth

        public static List doResourceIPEnvAuth​(String resourceUrl,
                                               String realm,
                                               Map envParameters)
                                        throws PolicyException
        Performs Resource/IP/Environment based authentication. This method is used by auth login viewbean.
        Parameters:
        resourceUrl - Resource URL for policy evaluation.
        realm - The realm which is used in authentication.
        envParameters - Environment map for policy evaluation. Keys of the map are Strings, values of the map are Set of Strings.
        Returns:
        a list which may be contain empty, one or two values. If the returned List size is two, first value is an instance of AuthContext.IndexType, second value is a String which indicates the value of the AuthContext.IndexType. If the returned List size is one, the value is a String which indicates the redirection URL (this is the redirection advice case). If the return List is empty, it means that there is no policy advice for the resource to be accessed.
        Throws:
        PolicyException - if policy processing error occurs.