I added some debug to web2py: in _CAS_login:
print print self.cas_login_url print self.cas_my_url print self.ticket I get: http://10.1.1.1:10000/cas/login http://10.1.1.1:9000/myapp/default/user/login None redirecting http://10.1.1.1:10000/cas/login http://10.1.1.1:9000/myapp/default/user/login ST-WFIMvjxwlEaSmUHP2rCtG4p89KQyi Got ticket http://10.1.1.1:10000/cas/login http://10.1.1.1:9000/myapp/default/user/login None redirecting So it gets the ticket from the CAS provider, but it still thinks it has to login again and redirects. Hmm. On Apr 29, 1:29 pm, Stodge <sto...@gmail.com> wrote: > I'm trying to get web2py to authenticate against a Django CAS > provider. The CAS provider is athttp://10.1.1.1:10000/cas. The CAS > provider works for Django based CAS consumers. > > I commented out the existing auth code in my db.py and added this as > per the instructions onhttp://web2py.com/cas: > > from gluon.contrib.login_methods.cas_auth import > CasAuth > auth.define_tables(username=True) > auth.settings.login_form=CasAuth( > > globals(), > urlbase = "http://10.1.1.1:10000/ > cas", > actions=['login','check','logout']) > > web2py is available at:http://10.1.1.1:9000/myapp/default. When I > visithttp://10.1.1.1:9000/myapp/default/user/login, I get redirected > to the CAS provider at: > > http://10.1.1.1:10000/cas/login/?service=http://10.1.1.1:9000/myapp/d... > > I can submit the login form but I get an error in Firefox: > > "The page isn't redirecting properly" > > Is the CAS provider redirecting back to the correct place? Did I miss > something silly? Thanks