[Grok-dev] Session based auth in Grok 1.1rc1

Jeffrey D Peterson bgpete at gmail.com
Tue Apr 6 15:19:13 EDT 2010


All,

 

I have been trying to replicate a working pattern for authentication in Grok
1.1 and I have hit a wall.  

 

Everything seems to work as expected but for two things:

 

1)      I can't seem to get the app to redirect to the login page, (which I
can type myself to)

2)      Once I type myself to the login page and enter credentials, it flows
through fine, redirects to the index page and drops this exception:

 

2010-04-06 14:01:51,729 ERROR [SiteError]
http://portal-dev.craryindustries.com/@@index

Traceback (most recent call last):

  File
"/home/zope/.buildout/eggs/zope.publisher-3.12.0-py2.5.egg/zope/publisher/pu
blish.py", line 131, in publish

    obj = request.traverse(obj)

  File
"/home/zope/.buildout/eggs/zope.publisher-3.12.0-py2.5.egg/zope/publisher/br
owser.py", line 556, in traverse

    ob, add_steps = publication.getDefaultTraversal(self, ob)

  File
"/home/zope/.buildout/eggs/grok-1.1rc1-py2.5.egg/grok/publication.py", line
103, in getDefaultTraversal

    request, ob)

  File
"/home/zope/.buildout/eggs/zope.app.publication-3.10.2-py2.5.egg/zope/app/pu
blication/browser.py", line 36, in getDefaultTraversal

    return ob.browserDefault(request)

  File
"/home/zope/.buildout/eggs/zope.securitypolicy-3.6.1-py2.5.egg/zope/security
policy/zopepolicy.py", line 277, in checkPermission

    object, principal.id, self._groupsFor(principal), permission,

  File
"/home/zope/.buildout/eggs/zope.securitypolicy-3.6.1-py2.5.egg/zope/security
policy/zopepolicy.py", line 314, in _groupsFor

    groups = self._findGroupsFor(principal, getPrincipal, [])

  File
"/home/zope/.buildout/eggs/zope.securitypolicy-3.6.1-py2.5.egg/zope/security
policy/zopepolicy.py", line 295, in _findGroupsFor

    group = getPrincipal(group_id)

  File
"/home/zope/.buildout/eggs/zope.pluggableauth-1.0.1-py2.5.egg/zope/pluggable
auth/authentication.py", line 89, in getPrincipal

    principal = interfaces.IFoundPrincipalFactory(info)(self)

TypeError: ('Could not adapt',
PrincipalInfo('83864CA7855EE435E040007F01002753'), <InterfaceClass
zope.pluggableauth.interfaces.IFoundPrincipalFactory>)

 

The Authenticator Plugin is supposed to return an implementation of
IPrincipalInfo which PrincipalInfo('83864CA7855EE435E040007F01002753') is
and I am not sure why it's having this issue.

 

Any insight would be appreciated. BTW.this worked with Grok 1.0 and all the
zope.app dependencies.

 

TIA,

 

Jeff Peterson

Webmaster

Crary Industries, Inc.

 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/grok-dev/attachments/20100406/56b5b746/attachment.html 


More information about the Grok-dev mailing list