Mercurial > hg
comparison tests/test-audit-path.out @ 5158:d316124ebbea
Make audit_path more stringent.
The following properties of a path are now checked for:
- under top-level .hg
- starts at the root of a windows drive
- contains ".."
- traverses a symlink (e.g. a/symlink_here/b)
- inside a nested repository
If any of these is true, the path is rejected.
The check for traversing a symlink is arguably stricter than necessary;
perhaps we should be checking for symlinks that point outside the
repository.
author | Bryan O'Sullivan <bos@serpentine.com> |
---|---|
date | Fri, 10 Aug 2007 10:46:03 -0700 |
parents | |
children | 11a4eb81fb4f |
comparison
equal
deleted
inserted
replaced
5157:f6c520fd70cf | 5158:d316124ebbea |
---|---|
1 % should fail | |
2 abort: path contains illegal component: .hg/00changelog.i | |
3 adding a/a | |
4 % should fail | |
5 abort: path 'b/b' traverses symbolic link 'b' | |
6 % should succeed | |
7 % should still fail - maybe | |
8 abort: path 'b/b' traverses symbolic link 'b' |