Hi, Does the anonymous role have read access to the JCR data in question?
If not, give the anonymous role read access and see if it works then... Another solution might be to do your JCR reads within in a doInSystemContext() call. Then you'll be accessing JCR with the admin session, but this should be done with care, as ACLs set for the anonymous user won't be used in this case. Regards from Vienna, Richard > -----Ursprüngliche Nachricht----- > Von: [email protected] [mailto:user-list-owner@magnolia- > cms.com] Im Auftrag von Eric Renteria (via Magnolia Forums) > Gesendet: Dienstag, 24. März 2015 22:37 > An: Magnolia User List > Betreff: [magnolia-user] Re: Custom Servlet Security, Remove > Authentication? > > > Actually, I think I spoke to soon. I took approach #2 and the endpoint is now > accessible to anyone, but it seems like the JCR content is not accessible if > the > user is not logged in. If I hit the endpoint in a browser with a logged-in > session, I am able to find the JCR data and > MgnlContext.getJCRSession("website") returns a session whose toString > method returns "session-admin-305". If I hit the endpoint in a private > browser, I not able to find the JCR data and > MgnlContext.getJCRSession("website") returns a session whose toString > method returns "session-anonymous-306". Is there a way to allow the > anonymous JCR session read-access to the JCR data? > > My servlet is running a JCR query that returns Nodes when logged-in, but > returns no Nodes when logged-out. > > -- > Context is everything: http://forum.magnolia- > cms.com/forum/thread.html?threadId=73331a82-9847-481f-a642- > 202433555eef > > > ---------------------------------------------------------------- > Alternatively, use our forums: http://forum.magnolia-cms.com/ > To unsubscribe, E-mail to: <[email protected]> > ---------------------------------------------------------------- ---------------------------------------------------------------- Alternatively, use our forums: http://forum.magnolia-cms.com/ To unsubscribe, E-mail to: <[email protected]> ----------------------------------------------------------------
