Changeset 2032 for pykota/trunk/cgi-bin/printquota.cgi
- Timestamp:
- 01/19/05 09:49:41 (20 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
pykota/trunk/cgi-bin/printquota.cgi
r2028 r2032 24 24 # 25 25 # $Log$ 26 # Revision 1.44 2005/01/19 08:49:41 jalet 27 # Now dumpykota.cgi behaves like printquota.cgi wrt the REMOTE_USER environment 28 # variables if the script is username+password protected. 29 # Small fix in printquota.cgi wrt ldap auth with Apache : the workaround was 30 # not used everywhere. 31 # 26 32 # Revision 1.43 2005/01/17 08:44:24 jalet 27 33 # Modified copyright years … … 255 261 """Main function""" 256 262 printers = ugmask = isgroup = None 263 remuser = os.environ.get("REMOTE_USER", "root") 264 # special hack to accomodate mod_auth_ldap Apache module 265 try : 266 remuser = remuser.split("=")[1].split(",")[0] 267 except IndexError : 268 pass 257 269 self.body = "<p>%s</p>\n" % _("Please click on the above button") 258 270 if self.form.has_key("report") : … … 264 276 else : 265 277 printers = self.storage.getMatchingPrinters("*") 266 remuser = os.environ.get("REMOTE_USER", "root")267 268 # special hack to accomodate mod_auth_ldap Apache module269 try :270 remuser = remuser.split("=")[1].split(",")[0]271 except IndexError :272 pass273 274 278 if remuser == "root" : 275 279 if self.form.has_key("ugmask") : … … 300 304 self.body += "%s" % self.reportingtool.generateReport() 301 305 else : 302 remuser = os.environ.get("REMOTE_USER", "root")303 306 if remuser != "root" : 304 307 username = remuser