[Zope-dev] Incorrect Padding?

Martijn Pieters mj@digicool.com
Mon, 24 Jul 2000 20:43:23 +0200


On Mon, Jul 24, 2000 at 08:36:26PM +0200, Martijn Pieters wrote:
> > I also checked, and this version of the patch *should* work:
> > 
> >         # Only do basic authentication
> >         if lower(auth[:6])!='basic ':
> >             return None
> >         name,password=tuple(split(decodestring(strip(auth[6:])), ':',
> > 1))
> > 
> > 
> > The "strip" is in there just in case a client responds with
> > 
> > "basic  base64blah" instead of
> > "basic base64blah".

Oops. You took out the strip. But IIRC, base64 does a strip as well.

-- 
Martijn Pieters
| Software Engineer            mailto:mj@digicool.com
| Digital Creations          http://www.digicool.com/
| Creators of Zope               http://www.zope.org/
| ZopeStudio: http://www.zope.org/Products/ZopeStudio
-----------------------------------------------------