path: root/regress/
diff options
authorDamien Miller <>2016-02-23 16:12:13 +1100
committerDamien Miller <>2016-02-23 17:40:16 +1100
commit1acc058d0a7913838c830ed998a1a1fb5b7864bf (patch)
tree14ece3b75d64372c430198b0f36a8c0a124a585a /regress/
parent39f303b1f36d934d8410b05625f25c7bcb75db4d (diff)
Disable tests where fs perms are incorrect
Some tests have strict requirements on the filesystem permissions for certain files and directories. This adds a regress/check-perm tool that copies the relevant logic from sshd to exactly test the paths in question. This lets us skip tests when the local filesystem doesn't conform to our expectations rather than continuing and failing the test run. ok dtucker@
Diffstat (limited to 'regress/')
1 files changed, 7 insertions, 0 deletions
diff --git a/regress/ b/regress/
index b90a8cf2..c0be7e74 100644
--- a/regress/
+++ b/regress/
@@ -24,6 +24,13 @@ _EOF
test $? -eq 0 || fatal "couldn't prepare principals command"
$SUDO chmod 0755 "$PRINCIPALS_CMD"
+if ! $OBJ/check-perm -m keys-command $PRINCIPALS_CMD ; then
+ echo "skipping: $PRINCIPALS_CMD is unsuitable as " \
+ "AuthorizedPrincipalsCommand"
+ exit 0
# Create a CA key and a user certificate.
${SSHKEYGEN} -q -N '' -t ed25519 -f $OBJ/user_ca_key || \
fatal "ssh-keygen of user_ca_key failed"