Hmm, that is an interesting quandary. I think the best solution might
be to use AOP around the DAO. Although we usually don't do aop around
those... I'm not a huge fan of moving the HibernateUserContextDAO logic
to the UserService, but perhaps after the reworking of the business
logic (in that ticket you mentioned) it makes more sense.
Ben
Mario Perez wrote:
> Hello everyone,
>
> We are students from California State University, Long Beach. We are
> currently working on a module that will externalize user
> management through an LDAP server.
>
> As stated in Ticket #623, our first thought was to use AOP to "intercept"
> the current authentication.
> That is not possible because authenticate() does not exist in UserService.
> Everything goes through the UserContext.authenticate()
> and ContextDAO.authenticate(). Therefore, there is no point to add an
> advisor that will let the
> module use an LDAP server to authenticate users.
>
> Moreover, Ticket #1748 (Move business logic for authentication into
> service layer) modify the current way the authentication is done. We know
> it's not a easy decision as major worries have to be
> considered such as security and modification of the core code.
>
> The only point I see to wrap a unique service method (such as
> UserService.authenticate(username, password, contextDAO) is now between
> Context.authenticate(username,password) and
> UserContext.authenticate(username, password, contextDAO).
> Through AOP we could replace the ContextDAO implementation to one that
> connects to LDAP instead of the database.
>
> In sum, we are inquiring about information on a potential solution to this
> problem. Has anyone worked
> with this problem who can point us down the right path for solving the
> authentication issue?
>
> You can see our profiles here:
>
http://openmrs.org/wiki/User:Apoulet>
http://openmrs.org/wiki/User:Flexapec>
http://openmrs.org/wiki/User:MiguelSpain>
http://openmrs.org/wiki/User:Mperez"
>
_________________________________________
To unsubscribe from OpenMRS Developers' mailing list, send an e-mail to
[hidden email] with "SIGNOFF openmrs-devel-l" in the body (not the subject) of your e-mail.
[mailto:
[hidden email]?body=SIGNOFF%20openmrs-devel-l]