[Bug 221417] pw usermod silently ignores -G ""

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Aug 11 11:54:41 UTC 2017


            Bug ID: 221417
           Summary: pw usermod silently ignores -G ""
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Keywords: patch, regression, security
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: fk at fabiankeil.de
             Flags: mfc-stable10?, mfc-stable11?

Created attachment 185283
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=185283&action=edit
pw usermod: Properly deal with empty secondary group lists

"pw usermod blafasel -G ''" is supposed to make sure that blafasel
doesn't have any secondary group memberships.

Since the pw refactoring in 2015 pw usermod treats -G "" as if no
secondary group membership modification was requested, though.
As a result, any existing memberships are kept.

The attached patch fixes the issue and adds a test for it.

Obtained from: ElectroBSD

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

More information about the freebsd-bugs mailing list