Page MenuHomeFreeBSD

ficl pfopen: verify file
ClosedPublic

Authored by sjg on May 23 2019, 8:10 PM.
Tags
None
Referenced Files
F163571626: D20387.id57796.diff
Fri, Jul 24, 2:56 PM
F163567093: D20387.id57803.diff
Fri, Jul 24, 1:53 PM
F163509320: D20387.id57856.diff
Thu, Jul 23, 11:07 PM
F163499564: D20387.id57797.diff
Thu, Jul 23, 8:33 PM
Unknown Object (File)
Thu, Jul 23, 7:37 AM
Unknown Object (File)
Tue, Jul 21, 7:55 AM
Unknown Object (File)
Mon, Jul 20, 2:15 AM
Unknown Object (File)
Sun, Jul 19, 7:26 PM
Subscribers

Details

Summary

If the file is verified - do not allow write
otherwise do not allow read.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 24448
Build 23257: arc lint + arc unit

Event Timeline

stand/ficl/loader.c
509

I believe this should be written like so:
if ((mode & O_ACCMODE) != O_WRONLY) {

515

Similar thing here:
if ((mode & O_ACCMODE) != O_RDONLY) {

sjg marked 2 inline comments as done.May 23 2019, 9:33 PM

Good point

stand.h needs to define O_ACCMODE

Did some basic testing and it looks ok.

This revision is now accepted and ready to land.May 24 2019, 7:33 AM
This revision was automatically updated to reflect the committed changes.