diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-05-21 15:11:47 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-05-21 15:11:47 +0000 |
commit | 4afac524e43575794769df175dfcbd4a4f6a8f44 (patch) | |
tree | 582d0f11655c10b7fa30810e006926aca75496f4 /sys | |
parent | fdacd90f92ccc960e1ff7fc07eb25e2e86712026 (diff) |
by default, files were made executable. that does not make sense today.
noone should be executing a binary from a msdos filesystem, considering
the mountpoint tracking permission mode model
ok natano krw
Diffstat (limited to 'sys')
-rw-r--r-- | sys/msdosfs/msdosfs_vnops.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/msdosfs/msdosfs_vnops.c b/sys/msdosfs/msdosfs_vnops.c index 534b0827d69..c97a219f24f 100644 --- a/sys/msdosfs/msdosfs_vnops.c +++ b/sys/msdosfs/msdosfs_vnops.c @@ -1,4 +1,4 @@ -/* $OpenBSD: msdosfs_vnops.c,v 1.109 2016/03/19 12:04:16 natano Exp $ */ +/* $OpenBSD: msdosfs_vnops.c,v 1.110 2016/05/21 15:11:46 deraadt Exp $ */ /* $NetBSD: msdosfs_vnops.c,v 1.63 1997/10/17 11:24:19 ws Exp $ */ /*- @@ -222,7 +222,7 @@ msdosfs_access(void *v) struct msdosfsmount *pmp = dep->de_pmp; mode_t dosmode; - dosmode = (S_IXUSR|S_IXGRP|S_IXOTH) | (S_IRUSR|S_IRGRP|S_IROTH); + dosmode = (S_IRUSR|S_IRGRP|S_IROTH); if ((dep->de_Attributes & ATTR_READONLY) == 0) dosmode |= (S_IWUSR|S_IWGRP|S_IWOTH); dosmode &= pmp->pm_mask; @@ -303,7 +303,7 @@ msdosfs_getattr(void *v) } vap->va_fileid = fileid; - vap->va_mode = (S_IXUSR|S_IXGRP|S_IXOTH) | (S_IRUSR|S_IRGRP|S_IROTH) | + vap->va_mode = (S_IRUSR|S_IRGRP|S_IROTH) | ((dep->de_Attributes & ATTR_READONLY) ? 0 : (S_IWUSR|S_IWGRP|S_IWOTH)); vap->va_mode &= dep->de_pmp->pm_mask; if (dep->de_Attributes & ATTR_DIRECTORY) { |