]> git.saurik.com Git - apt.git/blobdiff - test/integration/test-apt-get-install-deb
do not use _apt for file/copy sources if it isn't world-accessible
[apt.git] / test / integration / test-apt-get-install-deb
index c41713a923a0a26103ed13bb2b056c7602ea4dc1..3f1aee5a0cf5dc0f330d42adc856d2878016575e 100755 (executable)
@@ -103,3 +103,14 @@ createpkg 'trailing-newline' '' '
 testsuccess aptget install ./incoming/pkg-as-it-should-be_0_all.deb
 testsuccess aptget install ./incoming/pkg-leading-newline_0_all.deb
 testsuccess aptget install ./incoming/pkg-trailing-newline_0_all.deb
+
+# see if permission dropping is checked before usage
+if [ "$(id -u)" = '0' ]; then
+       apt clean
+       chmod 711 ./incoming
+       testsuccess aptget install -y --allow-downgrades ./incoming/pkg-as-it-should-be_0_all.deb -q=0
+       chmod 710 ./incoming
+       testsuccesswithnotice aptget install -y --allow-downgrades ./incoming/pkg-as-it-should-be_0_all.deb -q=0
+       chmod 700 ./incoming
+       testsuccesswithnotice aptget install -y --allow-downgrades ./incoming/pkg-as-it-should-be_0_all.deb -q=0
+fi