Bug 17155 - Add mount(8) check to /etc/security
Summary: Add mount(8) check to /etc/security
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: 3.4-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: Sheldon Hearn
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2000-03-03 21:10 UTC by Crist J. Clark
Modified: 2000-08-06 20:46 UTC (History)
1 user (show)

See Also:


Attachments
file.diff (780 bytes, patch)
2000-03-03 21:10 UTC, Crist J. Clark
no flags Details | Diff
file.diff (754 bytes, patch)
2000-03-03 21:10 UTC, Crist J. Clark
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Crist J. Clark 2000-03-03 21:10:00 UTC
	The other day I had to change the way a filesystem was mounted
to do some administrative tasks (specifically, I turned off the nosuid
option). I guess I became distracted because I never re-enabled it
until just noticing it recently.

	I was surprised and a little bit peeved that my /etc/security
script would not notice a change in the way filesystems were
mounted. Rather than just complain, I modified my own /etc/security's
accordingly and decided the modification was something that no one
could really argue against, so I'm submitting it here.

Fix: The structure of the added commands parallels the existing
'dmesg' check currently in place. Frankly, it's almost exactly the
same, just different filenames and another command generating the
initial output.

	The only thing I am unsure of is which is more asthetically
pleasing, using 'mount -p' output or taking 'mount' output and running
it through a quick sed script to clean out the "writes:"
information. At this point, I perfer the more verbose mount-sed 
combo. Both patches are included.

	Any contructive comments or criticisms appreciated.

	The mount-sed combo,

Now for the mount-p version,
How-To-Repeat: 
	Do anything to your filesystem mounts. /etc/security won't
notice.
Comment 1 dhagan 2000-04-06 02:32:00 UTC
This seems like a good idea.  There aren't any objections logged in the PR,
so is someone interested in committing this?

http://www.freebsd.org/cgi/query-pr.cgi?pr=17155

Daniel
Comment 2 Sheldon Hearn freebsd_committer freebsd_triage 2000-04-06 11:37:58 UTC
Responsible Changed
From-To: freebsd-bugs->sheldonh

I'll take this one. :-) 
Comment 3 Sheldon Hearn freebsd_committer freebsd_triage 2000-04-06 11:47:11 UTC
State Changed
From-To: open->analyzed

I've committed the mount -p version of your patch in rev 1.38.  I 
chose this version because its output is more useful for  
cut and paste operations on /etc/fstab. :-) 

While I'm convinced that there are no problems with this, I'm 
still going to stick to the rule of thumb that only critical 
bug fixes should be merged to stable branches immediately. 
Bug me in a month if I haven't merged this yet. ;-) 
Comment 4 nbm freebsd_committer freebsd_triage 2000-08-06 20:45:39 UTC
State Changed
From-To: analyzed->closed

MFC'd by asmodai in rev 1.36.2.2 of src/security