Problems with user authentication - DAO


I am trying to move the jasper server user authentication to a custom database which already exists. Now the problem is I found out thanks to the documentation on this site and the acegi security documentation that the hook point is the security provider, respectively, UserDetailService dao.
The problem is, if I replace the userdetail service with my implementation or a custom in memory implementation, with my own users in it, the authentication fails.
The problem in memory might be related to unencrypted passwords in the config files, but I am not sure
(I know security etc....)

Is there an example on how to hook custom user databases into the jasper server or is this not possible unless the users exist already in the jasper server database?
senton9999's picture
Joined: Aug 29 2006 - 12:12am
Last seen: 16 years 9 months ago

3 Answers:

Your custom DAO or in-memory implementation is fine. The authenticationManager can be configured to use a list of authentication services, and you can have several services try to authenticate the user name/password.

How does the authentication fail? You need to give more details, like a stack trace, log files etc

swood's picture
Joined: Jun 21 2006 - 12:48pm
Last seen: 10 years 7 months ago
Ok, first of all, thanks for the quick answer.
I am in fact already one step further.
I implemented an authenticationprovider and an authentication service.
The provider basically ignores all authentication checks as a first step and the service generates a user with predefined roles from the request. So far so good, the jasper server now accepts the login, also it writes that the user is authenticated but the forward to the main page still does not work, it still is stuck in the login page.

The affect server log says:

WARN LoggerListener,http-8080-Processor25:55 - Authentication event InteractiveAuthenticationSuccessEvent: lexow; details: org.acegisecurity.ui.WebAuthenticationDetails@fffc7f0c: RemoteIpAddress:; SessionId: 9C0EB6BDE4FB115FFE87811F5BADD8BA
16:30:05,238 WARN UserAuthorityServiceImpl,http-8080-Processor25:500 - Added following external roles to: lexow

16:30:05,247 WARN UserAuthorityServiceImpl,http-8080-Processor25:536 - Updated user: lexow. Roles are now:

16:30:05,292 WARN UserAuthorityServiceImpl,http-8080-Processor25:542 - Updated user: lexow. Roles are now:

Well as it seems the server accepts the authentication for the foreign datasources now, but does not do anything afterwards.
Attached are the two source files, the authentication provider and the user
DetailService: (packed zip file due to upload restrictions) [file size=3041]
Post edited by: senton9999, at: 2006/08/30 14:38
senton9999's picture
Joined: Aug 29 2006 - 12:12am
Last seen: 16 years 9 months ago


I am Working with Jasper Report developement for the past 3 years, Now i am in the position to give solution for user authendication from existing database(Application) Not from Jasper DB.

I hope you have solultion, could you please share the same.  My Question is how to impliment this java code in Jasper Application.

Note:I am expert in varios reporting solution but a beginner to jasper j2ee coading . So it would be appriciated to give me solution in detail.



Post Edited by shivasakthi18 at 03/22/2011 06:09
shivasakthi18's picture
Joined: Feb 25 2011 - 4:09am
Last seen: 2 years 6 months ago