Hi,
I'm trying to set up BASIC auth using orbeon-auth and am having a few problems. I'm running orbeon 4.7 with the matching orbeon-auth under tomcat6. I've set up a virtual host (xforms.york.ac.uk) and am calling my app using https://xforms.york.ac.uk/orbeon/console-reg/ below are the appropriate config bits and log outputs. If someone could point me in the right direction I'd be grateful. If I try running https://xforms.york.ac.uk/orbeon-auth/console-reg/ then I get a login prompt and the logs say I've successfully authenticted with a valid role. If I try using auth via my xforms app, then I get an Unauthorised page appearing. Config and logs Tomcat6
orbeon properties-local.xml
orbeon-auth/WEB-INF/web.xml <security-constraint> <web-resource-collection> <web-resource-name>Console Reg</web-resource-name> <url-pattern>/console-reg/*</url-pattern> </web-resource-collection> <auth-constraint> <role-name>orbeon-service</role-name> </auth-constraint> </security-constraint> <security-constraint> <web-resource-collection> <web-resource-name>Everything else</web-resource-name> <url-pattern>/*</url-pattern> </web-resource-collection> <!-- Make sure there is an empty auth-constraint to require authentication. But since there are no constraints specified, authentication will always fail. --> <auth-constraint/> </security-constraint> When I try authenticating from my app, tomcat6 gives me the following , the important bit being "Failed authenticate() test"
and orbeon.log shows
When I try connecting to https://xforms.york.ac.uk/orbeon-auth/console-reg/ I get the following and can authenticate successfully :- 7-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase invoke FINE: Security checking request GET /orbeon-auth/console-reg/ 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase findSecurityConstraints FINE: Checking constraint 'SecurityConstraint[Console Reg]' against GET /console-reg/ --> true 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase findSecurityConstraints FINE: Checking constraint 'SecurityConstraint[Everything else]' against GET /console-reg/ --> true 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase findSecurityConstraints FINE: Checking constraint 'SecurityConstraint[Console Reg]' against GET /console-reg/ --> true 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase findSecurityConstraints FINE: Checking constraint 'SecurityConstraint[Everything else]' against GET /console-reg/ --> true 17-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase invoke FINE: Calling hasUserDataPermission() 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase hasUserDataPermission FINE: User data constraint has no restrictions 17-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase invoke FINE: Calling authenticate() 17-Oct-2014 10:12:37 org.apache.catalina.realm.MemoryRealm authenticate FINE: Username orbeonadmin successfully authenticated 17-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase register FINE: Authenticated 'orbeonadmin' with type 'BASIC' 17-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase invoke FINE: Calling accessControl() 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase hasResourcePermission FINE: Checking roles GenericPrincipal[orbeonadmin(orbeon-admin,orbeon-service,)] 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase hasRole FINE: Username orbeonadmin has role orbeon-service 17-Oct-2014 10:12:37 org.apache.catalina.realm.RealmBase hasResourcePermission FINE: Role found: orbeon-service 17-Oct-2014 10:12:37 org.apache.catalina.authenticator.AuthenticatorBase invoke FINE: Successfully passed all security constraints Rgds Alex You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Been a while since I sent this out, any chance of a response from someone?
Rgds A
-- On 17 Oct 2014, at 10:16, alex sharaz wrote:
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Administrator
|
Hi Alex,
You're saying: If I try running https://xforms.york.ac.uk/orbeon-auth/console-reg/ then I get a login prompt and the logs say I've successfully authenticted with a valid role. If I try using auth via my xforms app, then I get an Unauthorised page appearing. I am not following: after you log into the BASIC auth dialog, can you see the page fine, any page? What do you mean by "auth via my xforms app"? Is this something different than BASIC auth? Alex
--
Follow Orbeon on Twitter: @orbeon Follow me on Twitter: @avernet |
On 20 Oct 2014, at 18:33, Alessandro Vernet wrote:
The tomcat6 logs ahow
A
-- You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Administrator
|
Hi Alex,
Okay, got it. Now it is unclear to me whether authentication is failing at the Tomcat level or Orbeon Forms level: - If at the Tomcat level: maybe the browser is sending an incorrect Authorization header? If it does, it's possible you get an error from the server and don't get ask for the password again. Do you get the prompt again after restarting your browser? If you are, after logging in, are you still getting the authentication error? - If at the Orbeon Form level: do you have any XForms code in your app doing authentication? Would you get the same problem if using your web.xml on the vanilla Orbeon Forms? Alex
--
Follow Orbeon on Twitter: @orbeon Follow me on Twitter: @avernet |
In reply to this post by Alessandro Vernet
Not sure if my reply to this appeared on the list.
Didn't phrase it properly. When I try running https://xforms.york.ac.uk/orbeon/console-reg/ I don't get a login dialogue box prompt, I just get redirected to an orbeon unauthorised page. Looking in the tomcat6 logs I see
Where can I get the source of orbeon-auth ? Rgds A On 20 Oct 2014, at 18:33, Alessandro Vernet wrote:
You received this message because you are subscribed to the Google Groups "Orbeon Forms" group. To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email]. To post to this group, send email to [hidden email]. |
Administrator
|
Hi Alex,
This even after restarting the browser? Tomcat should ask you to enter a password if you access https://xforms.york.ac.uk/orbeon/console-reg/ and in your web.xml have: <security-constraint> <web-resource-collection> <web-resource-name>Console Reg</web-resource-name> <url-pattern>/console-reg/*</url-pattern> </web-resource-collection> <auth-constraint> <role-name>orbeon-service</role-name> </auth-constraint> </security-constraint> BTW, as I understand it, this isn't related to Orbeon Forms: it is Tomcat that should ask the user to authenticate based on what you have in the web.xml, or am I missing something? Alex
--
Follow Orbeon on Twitter: @orbeon Follow me on Twitter: @avernet |
Free forum by Nabble | Edit this page |