summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: bf2d67b)
raw | patch | inline | side by side (parent: bf2d67b)
author | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Sat, 3 Nov 2001 01:26:55 +0000 (01:26 +0000) | ||
committer | richard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Sat, 3 Nov 2001 01:26:55 +0000 (01:26 +0000) |
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@358 57a73879-2fb5-44c3-a270-3262357dd7e2
roundup/cgi_client.py | patch | blob | history |
diff --git a/roundup/cgi_client.py b/roundup/cgi_client.py
index c04321ef0fd6e889ac925b2c66b9795d260bc468..2cafcd5b3bdf5915625408c82b125323b99e7a27 100644 (file)
--- a/roundup/cgi_client.py
+++ b/roundup/cgi_client.py
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
#
-# $Id: cgi_client.py,v 1.45 2001-11-01 22:04:37 richard Exp $
+# $Id: cgi_client.py,v 1.46 2001-11-03 01:26:55 richard Exp $
import os, cgi, pprint, StringIO, urlparse, re, traceback, mimetypes
-import base64, Cookie, time
+import binascii, Cookie, time
import roundupdb, htmltemplate, date, hyperdb, password
# construct the cookie
uid = self.db.user.lookup(self.user)
- user = base64.encodestring('%s:%s'%(self.user, password))[:-1]
+ user = binascii.b2a_base64('%s:%s'%(self.user, password)).strip()
path = '/'.join((self.env['SCRIPT_NAME'], self.env['INSTANCE_NAME'],
''))
self.header({'Set-Cookie': 'roundup_user=%s; Path=%s;'%(user, path)})
password = self.db.user.get(uid, 'password')
# construct the cookie
uid = self.db.user.lookup(self.user)
- user = base64.encodestring('%s:%s'%(self.user, password))[:-1]
+ user = binascii.b2a_base64('%s:%s'%(self.user, password)).strip()
path = '/'.join((self.env['SCRIPT_NAME'], self.env['INSTANCE_NAME'],
''))
self.header({'Set-Cookie': 'roundup_user=%s; Path=%s;'%(user, path)})
if (cookie.has_key('roundup_user') and
cookie['roundup_user'].value != 'deleted'):
cookie = cookie['roundup_user'].value
- user, password = base64.decodestring(cookie).split(':')
+ user, password = binascii.a2b_base64(cookie).split(':')
# make sure the user exists
try:
uid = self.db.user.lookup(user)
#
# $Log: not supported by cvs2svn $
+# Revision 1.45 2001/11/01 22:04:37 richard
+# Started work on supporting a pop3-fetching server
+# Fixed bugs:
+# . bug #477104 ] HTML tag error in roundup-server
+# . bug #477107 ] HTTP header problem
+#
# Revision 1.44 2001/10/28 23:03:08 richard
# Added more useful header to the classic schema.
#