diff options
author | Martin Pool <mbp@samba.org> | 2002-04-08 05:19:41 +0000 |
---|---|---|
committer | Martin Pool <mbp@samba.org> | 2002-04-08 05:19:41 +0000 |
commit | c81a32f071400c0edac42e00264718eec593e081 (patch) | |
tree | 1bb98bd9b80527012f1c26da85b62762a4f08da7 /testsuite/unsafe-byname.test | |
parent | 6f2623fd69f41978c79e7bc38cabe45d677f2853 (diff) | |
download | rsync-c81a32f071400c0edac42e00264718eec593e081.tar.gz rsync-c81a32f071400c0edac42e00264718eec593e081.tar.bz2 rsync-c81a32f071400c0edac42e00264718eec593e081.zip |
Add more test cases.
Diffstat (limited to 'testsuite/unsafe-byname.test')
-rw-r--r-- | testsuite/unsafe-byname.test | 26 |
1 files changed, 24 insertions, 2 deletions
diff --git a/testsuite/unsafe-byname.test b/testsuite/unsafe-byname.test index 2c199720..a4d24368 100644 --- a/testsuite/unsafe-byname.test +++ b/testsuite/unsafe-byname.test @@ -16,5 +16,27 @@ test_unsafe() { set -x -test_unsafe foo foo safe -test_unsafe ../foo foo unsafe +test_unsafe file from safe +test_unsafe dir/file from safe +test_unsafe dir/./file from safe +test_unsafe dir/. from safe +test_unsafe dir/ from safe + +test_unsafe /etc/passwd from unsafe +test_unsafe //../etc/passwd from unsafe +test_unsafe //./etc/passwd from unsafe + +test_unsafe ./foo from safe +test_unsafe ../foo from unsafe +test_unsafe ../dest from/dir safe + +# Based on tests from unsafe-links by Vladimír Michl +test_unsafe ../../unsafe/unsafefile from/safe unsafe +test_unsafe ../files/file1 from/safe safe + +test_unsafe ../../unsafe/unsafefile safe unsafe +test_unsafe ../files/file1 safe unsafe + +test_unsafe ../../unsafe/unsafefile `pwd`/from/safe safe +test_unsafe ../files/file1 `pwd`/from/safe safe + |