Hi Jan Thanks for your reply.
I'm not doing anything else. Basically I listen for a request parameter and would like to login a certain known magnolia user based on that. The user has based on it's role further access than anonymous. I do not get a stacktrace since no Exception is thrown. What happens is: - I access the page with anonymous user and trigger the mentioned code. - Thereby I loose the read right to everything and get presented the magnolia login form When calling System.out.println(MgnlContext.getUser().getName()); I can see the desired username, so basically it seems to have worked but still no access to the content is granted. (Users access right are tested through normal login). Any further help is appreciated. Cheers, Thomas On 05.03.2012, at 11:17, Jan Haderka wrote: > Hi Thomas, > > This way you get user logged in the context, that doesn't mean user is set in > session and it has all ACLs resolved. What else are you (not) doing? Can you > provide full stacktrace from the error you get? > > Cheers, > Jan > > On Mar 5, 2012, at 12:33 AM, Thomas Martin wrote: > >> Dear List >> >> I need a simple way to react on an external login mechanism. >> >> While digging through various requests to the list I found this gem, which >> would do exactly what I need: >> >> MgnlUser mgnlUser = (MgnlUser) >> SecuritySupport.Factory.getInstance().getUserManager().getUser(userIdToLogin); >> MgnlContext.login(mgnlUser); >> >> >> Unfortunately it seems that the returned User is not fully instantiated and >> thus cannot login. >> Can someone give me a hint how to solve this? >> >> Thanks for any pointers! >> Cheers, Thomas >> >> >> >> ---------------------------------------------------------------- >> For list details, see >> http://www.magnolia-cms.com/community/mailing-lists.html >> Alternatively, use our forums: http://forum.magnolia-cms.com/ >> To unsubscribe, E-mail to: <[email protected]> >> ---------------------------------------------------------------- > > > > > ---------------------------------------------------------------- > For list details, see http://www.magnolia-cms.com/community/mailing-lists.html > Alternatively, use our forums: http://forum.magnolia-cms.com/ > To unsubscribe, E-mail to: <[email protected]> > ---------------------------------------------------------------- > ---------------------------------------------------------------- For list details, see http://www.magnolia-cms.com/community/mailing-lists.html Alternatively, use our forums: http://forum.magnolia-cms.com/ To unsubscribe, E-mail to: <[email protected]> ----------------------------------------------------------------
