svn path=/trunk/packages/sipb-xen-www/; revision=633
elif back == 'info':
machine = validation.Validate(username, state, machine_id=fields.getfirst('machine_id')).machine
return ({'Status': '303 See Other',
elif back == 'info':
machine = validation.Validate(username, state, machine_id=fields.getfirst('machine_id')).machine
return ({'Status': '303 See Other',
- 'Location': '/info?machine_id=%d' % machine.machine_id},
+ 'Location': 'info?machine_id=%d' % machine.machine_id},
"You shouldn't see this message.")
else:
raise InvalidInput('back', back, 'Not a known back page.')
"You shouldn't see this message.")
else:
raise InvalidInput('back', back, 'Not a known back page.')
return templates.unauth(searchList=[{'simple' : True}])
def overlord(username, state, path, fields):
return templates.unauth(searchList=[{'simple' : True}])
def overlord(username, state, path, fields):
+ if path == '':
+ return ({'Status': '303 See Other',
+ 'Location': 'overlord/'},
+ "You shouldn't see this message.")
if not username in getAfsGroupMembers('system:xvm', 'athena.mit.edu'):
raise InvalidInput('username', username, 'Not an overlord.')
newstate = State(username, overlord=True)
if not username in getAfsGroupMembers('system:xvm', 'athena.mit.edu'):
raise InvalidInput('username', username, 'Not an overlord.')
newstate = State(username, overlord=True)
fields = cgi.FieldStorage(fp=self.environ['wsgi.input'], environ=self.environ)
operation = self.environ.get('PATH_INFO', '')
if not operation:
fields = cgi.FieldStorage(fp=self.environ['wsgi.input'], environ=self.environ)
operation = self.environ.get('PATH_INFO', '')
if not operation:
- self.start("301 Moved Permanently", [('Location',
- self.environ['SCRIPT_NAME']+'/')])
+ self.start("301 Moved Permanently", [('Location', './')])
return
if self.username is None:
operation = 'unauth'
return
if self.username is None:
operation = 'unauth'