Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 492374 Details for
Bug 629914
<mail-filter/opendkim-2.10.3-r8: privilege escalation via PID file manipulation
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
opendkim.init.r4
opendkim.init.r4 (text/plain), 2.15 KB, created by
Michael Orlitzky
on 2017-09-04 20:47:43 UTC
(
hide
)
Description:
opendkim.init.r4
Filename:
MIME Type:
Creator:
Michael Orlitzky
Created:
2017-09-04 20:47:43 UTC
Size:
2.15 KB
patch
obsolete
>#!/sbin/openrc-run ># Copyright 1999-2017 Gentoo Foundation ># Distributed under the terms of the GNU General Public License v2 > >CONFFILE="/etc/opendkim/${RC_SVCNAME}.conf" >required_files="${CONFFILE}" > >command="/usr/sbin/opendkim" >pidfile="/run/${RC_SVCNAME}.pid" >command_args="-P ${pidfile} -x ${CONFFILE} -p ${OPENDKIM_SOCKET}" > >depend() { > use dns logger net > before mta >} > >check_cfg() { > # > # The opendkim.conf man page says, > # > # For parameters that are Boolean in nature, only the first byte > # of the value is processed... For negative values, the following > # are accepted: "F", "f", "N", "n", "0".' > # > if grep --quiet '^[[:space:]]*Background[[:space:]]\+[FfNn0]' \ > "${CONFFILE}"; then > eerror "${RC_SVCNAME} cannot run in the foreground!" > return 1 > fi >} > >start_pre() { > # If this isn't a restart, make sure that the user's config isn't > # busted before we try to start the daemon (this will produce > # better error messages than if we just try to start it blindly). > # > # If, on the other hand, this *is* a restart, then the stop_pre > # action will have ensured that the config is usable and we don't > # need to do that again. > if [ "${RC_CMD}" != "restart" ]; then > check_cfg || return $? > fi > > if [ -S "${OPENDKIM_SOCKET}" ] && ! fuser -s "${OPENDKIM_SOCKET}"; then > # Remove stalled Unix socket if no other process is > # using it > if ! rm "${UNIX_SOCKET}"; then > eerror "failed to remove stale unix socket ${OPENDKIM_SOCKET}" > return 2 > fi > fi > > # This relies on the "local:" prefix being there, but the conf.d > # file explicitly states that it's not optional (contrary to what > # the opendkim(8) man page says). > if [ "${OPENDKIM_SOCKET#local:}" != "${OPENDKIM_SOCKET}" ]; then > # The socket begins with "local:" > OPENDKIM_SOCKET_PATH="${OPENDKIM_SOCKET#local:}" > OPENDKIM_SOCKET_DIR="${OPENDKIM_SOCKET_PATH%/*}" > > # This is dangerous, but there's a big warning about it > # in the conf.d file. > checkpath --directory --owner opendkim "${OPENDKIM_SOCKET_DIR}" > fi >} > >stop_pre() { > # If this is a restart, check to make sure the user's config > # isn't busted before we stop the running daemon. > if [ "${RC_CMD}" = "restart" ]; then > check_cfg || return $? > fi >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 629914
:
492370
|
492372
| 492374 |
492376
|
492378