[Bug 217651] devfs: adding an improper ruleset, e.g. one that has improperly quoted globs, are hard to delete

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Mar 9 00:27:17 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=217651

            Bug ID: 217651
           Summary: devfs: adding an improper ruleset, e.g. one that has
                    improperly quoted globs, are hard to delete
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: kern
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: ngie at FreeBSD.org

Repro:

Run the following commands as root:

1. Add a bogus ruleset with improperly quoted paths for "/dev/pass*" and
"/dev/xpt*" (change 20/21 to another ruleset that's not currently taken):

# cat >> /etc/devfs.rules <<'EOF'
[devfsrules_modify_perms_for_wheel=20]
add path pass* mode 660 group wheel
add path xpt* mode 660 group wheel

[devfsrules_modify_perms_for_wheel=21]
add path "pass*" mode 660 group wheel
add path "xpt*" mode 660 group wheel
EOF

2. Run /etc/rc.d/devfs, e.g., "service devfs start".
3. Verify that the ruleset has been added:

# devfs rule showsets | egrep '^2[01]$'
20
21
#

4. Try deleting the newly added rulesets, e.g.,

# devfs rule -s 20 delset
# devfs rule -s 21 delset

5. Verify that they've been deleted by rerunning the command in 3.

Expected results:

Both rulesets should be deleted.

Actual results:

Ruleset 20 remains:

# devfs rule showsets | egrep '^2[01]$'
20

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list