Mercurial > hg > FileServer
comparison tests/doctest.txt @ 17:27bd18f0a359
fix up security hole
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Wed, 29 Feb 2012 16:01:38 -0800 |
parents | 4f26df21dc12 |
children | 76c939271534 |
comparison
equal
deleted
inserted
replaced
16:4f26df21dc12 | 17:27bd18f0a359 |
---|---|
78 >>> response.body == file(filename).read() | 78 >>> response.body == file(filename).read() |
79 True | 79 True |
80 | 80 |
81 Ensure you can't get to non-allowed resources:: | 81 Ensure you can't get to non-allowed resources:: |
82 | 82 |
83 >>> response = testapp.get('/../exampleBADBADBAD') | 83 >>> response = testapp.get('/../exampleBADBADBAD', status=404) |
84 >>> response.status # Not Found: we do not want to give away these resources | 84 >>> response.status # Not Found: we do not want to give away these resources |
85 404 | 85 404 |
86 |