Page MenuHomeFreeBSD

rc.d/jail: avoid misinterpreting expr arguments
ClosedPublic

Authored by emaste on Feb 27 2018, 5:55 PM.
Tags
None
Referenced Files
F132099110: D14535.id39833.diff
Mon, Oct 13, 4:35 PM
Unknown Object (File)
Fri, Oct 3, 3:14 AM
Unknown Object (File)
Thu, Sep 18, 10:34 PM
Unknown Object (File)
Tue, Sep 16, 9:10 AM
Unknown Object (File)
Sep 13 2025, 11:03 AM
Unknown Object (File)
Sep 10 2025, 4:05 PM
Unknown Object (File)
Sep 9 2025, 4:19 PM
Unknown Object (File)
Sep 5 2025, 2:21 AM
Subscribers

Details

Summary

(Due to some misconfiguration) I ended up with _mask set to -v<something>, and /etc/rc.d/jail then failed with expr: illegal option -- v.

Use expr -- so that variable content is never interpreted as an option.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

emaste edited the summary of this revision. (Show Details)
This revision is now accepted and ready to land.Feb 28 2018, 5:06 PM
This revision was automatically updated to reflect the committed changes.