Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Mar 2015 02:49:46 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-ports-bugs@FreeBSD.org
Subject:   [Bug 198678] devel/p4web can't take custom p4web_user
Message-ID:  <bug-198678-13@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=198678

            Bug ID: 198678
           Summary: devel/p4web can't take custom p4web_user
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: gordon@FreeBSD.org
          Reporter: dteske@FreeBSD.org
             Flags: maintainer-feedback?(gordon@FreeBSD.org)
          Assignee: gordon@FreeBSD.org

Trying to make devel/p4web run on port 80. The startup script
(/usr/local/etc/rc.d/p4web) has a hard-coded p4web_user which causes the
process to always be started as non-privileged user "p4admin" (which results in
the inability to bind to 0.0.0.0:80, permission denied).

It would be nice if one could do:

sysrc p4web_{enable=YES,listen=80,user=root,args="-U p4admin"}

Causing the following to be configured in rc.conf(5):

p4web_enable="YES"
p4web_listen="80"
p4web_user="root" # <-- not supported by current rc.d script
p4web_args="-U p4admin"

The net effect is that the p4web process will initially be run as root --
allowing it to bind to 0.0.0.0:80 -- but the addition of the "-U p4admin" args
will cause p4web to then become the p4admin user after performing the initial
listen.

Currently there seems to be no way to change the user that p4web is run as.

Since p4d has the same problem (hard-coded to use p4admin), it is not deemed a
good idea to simply make p4admin part of the wheel group (p4d does not need to
bind to a port below 1024 and thus doesn't need the elevated privileges).

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



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-198678-13>