Hi Henk,

this is a good way with the current authentication architecture. However, ideally you should just be able to assemble the managers without changing any source code. This is part of the re-architecting that Steven Grim has been talking about. There's no ETA on when that will be done though.

Best regards,

Geert

On 05 Sep 2006, at 15:33, henk wrote:

Hi,

I want to use my own credentialsmanager and I solved by creating a subclass of PurgingDatabaseAuthenticated and set the credentialsmanager in the initializeAuthentication() method.
I was wondering if this is best way to achieve this.

Thanks

Henk


The class :

public class WebserviceAuthenticated extends PurgingDatabaseAuthenticated{ private static final Log logger = LogFactory.getLog (WebserviceAuthenticated.class);
        
        @Override
        protected void initializeAuthentication() {
                super.initializeAuthentication();
                logger.debug("Initializing authentication");
                logger.info(getCookieValue("lang"));
setTemplateName(getPropertyString("template_name") +"_"+getCookieValue("lang")); getSessionValidator().setCredentialsManager (WebserviceUsersFactory.getInstance(getElementInfo ().getPropertyTyped("datasource",
                                Datasource.class)));
        }

        public WebserviceAuthenticated()
        {
        }
        
        @Override
        protected void validatedCredentials(Credentials arg0) {
                logger.info("validatedCredentials : ");
                super.validatedCredentials(arg0);
        }

        public void doLangChange() {
                setOutput("lang_id", getParameter("lang_id"));
                exit("lang_choice");
        }
}
_______________________________________________
Rife-users mailing list
[email protected]
http://lists.uwyn.com/mailman/listinfo/rife-users


--
Geert Bevin
Uwyn "Use what you need" - http://uwyn.com
RIFE Java application framework - http://rifers.org
Music and words - http://gbevin.com


_______________________________________________
Rife-users mailing list
[email protected]
http://lists.uwyn.com/mailman/listinfo/rife-users

Reply via email to