diff options
author | Jameson Graef Rollins <jrollins@finestructure.net> | 2009-06-29 11:29:52 -0400 |
---|---|---|
committer | Jameson Graef Rollins <jrollins@finestructure.net> | 2009-06-29 11:29:52 -0400 |
commit | 9d0eb248fd7965df843665dbd179bb6493f8d9c3 (patch) | |
tree | bd2e6299109e360ce14fd1013566b9a68a2080f0 /src/share | |
parent | 867506b457402f2e4510ccd3ef50154b6e28b489 (diff) |
resolve symlinks when checking path permissions
Thanks to Silvio Rhatto for the patch. This should close MS bug #917
Diffstat (limited to 'src/share')
-rw-r--r-- | src/share/common | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/share/common b/src/share/common index 11e7969..bd887d3 100644 --- a/src/share/common +++ b/src/share/common @@ -425,6 +425,12 @@ check_key_file_permissions() { log debug "checking path permission '$path'..." + # rewrite path if it points to a symlink + if [ -h "$path" ] ; then + path=$(readlink -f "$path") + log debug "checking path symlink '$path'..." + fi + # return 255 if cannot stat file if ! stat=$(ls -ld "$path" 2>/dev/null) ; then log error "could not stat path '$path'." |