mirror of
https://github.com/servo/servo
synced 2026-05-05 06:32:13 +02:00
Update web-platform-tests to revision 0d318188757a9c996e20b82db201fd04de5aa255
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
def main(request, response):
|
||||
if request.auth.username == 'usr' and request.auth.password == 'secret':
|
||||
response.headers.set('Content-type', 'text/plain')
|
||||
content = ""
|
||||
else:
|
||||
response.status = 401
|
||||
response.headers.set('Status', '401 Authorization required')
|
||||
response.headers.set('WWW-Authenticate', 'Basic realm="test"')
|
||||
content = 'User name/password wrong or not given: '
|
||||
|
||||
content += "%s\n%s" % (request.auth.username,
|
||||
request.auth.password)
|
||||
return content
|
||||
Reference in New Issue
Block a user