[Zope3-Users] Paste sending 'Authentication Required' popup

2009-06-11 Thread Simon Elbaz
Hi,
I am trying to set a session credentials plugins in an application. A
request on 'http://localhost:8080/' sends me to the login form as defined in
the plugin.
Whereas, a request on 'http://localhost:9030/++skin++Login/@@search.html'
triggers the 'Authentication Required' popup (realm Zope).

I have tried to debug with pdb and here are the lines just before the popup
appears:
(Pdb) r

/home/simon/.buildout/eggs/zope.app.wsgi-3.5.2-py2.5.egg/zope/app/wsgi/__init__.py(58)__call__()
- response = request.response
(Pdb) r
--Return--

/home/simon/.buildout/eggs/zope.app.wsgi-3.5.2-py2.5.egg/zope/app/wsgi/__init__.py(71)__call__()-('',)
- return response.consumeBodyIter()
(Pdb) r

/home/simon/.buildout/eggs/Paste-1.7.2-py2.5.egg/paste/httpserver.py(289)wsgi_execute()
- try:
(Pdb) r
--Return--

/home/simon/.buildout/eggs/Paste-1.7.2-py2.5.egg/paste/httpserver.py(297)wsgi_execute()-None
- result = None


browser/configure.zcml


page
  name=search.html
  for=zope.app.folder.interfaces.IFolder
  permission=cdcadama.View
  layer=cdcadama.layer.ICdcadamaBrowserLayer
  class=.login.SearchAddForm
/


Could someone tell me how to inhibate the HTTPBasicAuth popup ?

Thanks
Simon
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] Paste sending 'Authentication Required' popup

2009-06-11 Thread Simon Elbaz
Finally, I found where HTTPBasicAuthentication is triggered. It is in:


/home/simon/.buildout/eggs/zope.app.wsgi-3.5.2-py2.5.egg/zope/app/wsgi/__init__.py(57)__call__()
- request = publish(request, handle_errors=handle_errors)

/home/simon/.buildout/eggs/zope.publisher-3.8.0-py2.5.egg/zope/publisher/publish.py(142)publish()
- obj, request, sys.exc_info(), True)

/home/simon/.buildout/eggs/zope.app.publication-3.7.0-py2.5.egg/zope/app/publication/zopepublication.py(336)handleException()
- body = mapply(view, (), request)

/home/simon/.buildout/eggs/zope.publisher-3.8.0-py2.5.egg/zope/publisher/publish.py(108)mapply()
- return debug_call(obj, args)

/home/simon/.buildout/eggs/zope.publisher-3.8.0-py2.5.egg/zope/publisher/publish.py(114)debug_call()
- return obj(*args)
*
/home/simon/.buildout/eggs/zope.app.http-3.6.0-py2.5.egg/zope/app/http/exception/unauthorized.py(32)__call__()
- self.request.unauthorized('basic realm=Zope')
*

I wonder how zope gets into this piece of code and don't use
./zope.app.exception-3.5.0-py2.5.egg/zope/app/exception/browser/unauthorized.py

Thanks for your help
Simon



On Thu, Jun 11, 2009 at 4:48 PM, Simon Elbaz elbazsim...@gmail.com wrote:

 Hi,
 I am trying to set a session credentials plugins in an application. A
 request on 'http://localhost:8080/' sends me to the login form as defined
 in the plugin.
 Whereas, a request on 'http://localhost:9030/++skin++Login/@@search.html'
 triggers the 'Authentication Required' popup (realm Zope).

 I have tried to debug with pdb and here are the lines just before the popup
 appears:
 (Pdb) r
 
 /home/simon/.buildout/eggs/zope.app.wsgi-3.5.2-py2.5.egg/zope/app/wsgi/__init__.py(58)__call__()
 - response = request.response
 (Pdb) r
 --Return--
 
 /home/simon/.buildout/eggs/zope.app.wsgi-3.5.2-py2.5.egg/zope/app/wsgi/__init__.py(71)__call__()-('',)
 - return response.consumeBodyIter()
 (Pdb) r
 
 /home/simon/.buildout/eggs/Paste-1.7.2-py2.5.egg/paste/httpserver.py(289)wsgi_execute()
 - try:
 (Pdb) r
 --Return--
 
 /home/simon/.buildout/eggs/Paste-1.7.2-py2.5.egg/paste/httpserver.py(297)wsgi_execute()-None
 - result = None


 browser/configure.zcml
 

 page
   name=search.html
   for=zope.app.folder.interfaces.IFolder
   permission=cdcadama.View
   layer=cdcadama.layer.ICdcadamaBrowserLayer
   class=.login.SearchAddForm
 /


 Could someone tell me how to inhibate the HTTPBasicAuth popup ?

 Thanks
 Simon

___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users