Show More
@@ -304,11 +304,11 b' class AuthenticatedFileHandler(IPythonHandler, web.StaticFileHandler):' | |||
|
304 | 304 | |
|
305 | 305 | # check UF_HIDDEN on any location up to root |
|
306 | 306 | path = absolute_path |
|
307 | while path and path.startswith(absolute_root): | |
|
307 | while path and path.startswith(absolute_root) and path != absolute_root: | |
|
308 | 308 | st = os.stat(path) |
|
309 | 309 | if getattr(st, 'st_flags', 0) & UF_HIDDEN: |
|
310 | 310 | raise web.HTTPError(403) |
|
311 |
path |
|
|
311 | path = os.path.dirname(path) | |
|
312 | 312 | |
|
313 | 313 | return absolute_path |
|
314 | 314 |
General Comments 0
You need to be logged in to leave comments.
Login now