Interface AuthorizationModule

    • Method Detail

      • commit

        boolean commit()
                throws AuthorizationException
        Overall authorization process has succeeded. The module can commit any decisions it has made, with third party systems like a database.
        Returns:
        Throws:
        AuthorizationException
      • initialize

        void initialize​(Subject subject,
                        CallbackHandler handler,
                        Map<String,​Object> sharedState,
                        Map<String,​Object> options,
                        RoleGroup roles)
        Initialize the module
        Parameters:
        subject - the authenticated subject
        handler - CallbackHandler
        sharedState - state shared with other configured modules
        options - options specified in the Configuration for this particular module
        roles - Roles of the subject
      • authorize

        int authorize​(Resource resource)
        Authorize the resource
        Parameters:
        resource -
        Returns:
        AuthorizationContext.PERMIT or AuthorizationContext.DENY
      • destroy

        boolean destroy()
        A final cleanup opportunity offered
        Returns:
        cleanup by the module passed or not