Skip to content

Commit

Permalink
Use non-suid permissions when logind is used
Browse files Browse the repository at this point in the history
When systemd-logind and its D-Bus API is used to actual change the
brightness of devices the binary does not have to be suid, which is
desired for security reasons.

This is a cherry-pick of: 7504b58 that
was partially reverted by: 052e56c.

Signed-off-by: Antoine Damhet <[email protected]>
  • Loading branch information
gicmo authored and Hummer12007 committed Feb 2, 2020
1 parent 914a740 commit 2fe7b1f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ INSTALL_UDEV_RULES = 1
INSTALL_UDEV_1 = install_udev_rules
UDEVDIR ?= /lib/udev/rules.d

MODE_0 = 4711
MODE_1 = 0755
MODE = ${MODE_${INSTALL_UDEV_RULES}}

ifdef ENABLE_SYSTEMD
CFLAGS += ${shell pkg-config --cflags libsystemd}
LDLIBS += ${shell pkg-config --libs libsystemd}
CPPFLAGS += -DENABLE_SYSTEMD
INSTALL_UDEV_RULES=0
MODE = 0755
endif

MODE_0 = 4711
MODE_1 = 0755
MODE = ${MODE_${INSTALL_UDEV_RULES}}


all: brightnessctl brightnessctl.1

install: all ${INSTALL_UDEV_${INSTALL_UDEV_RULES}}
Expand Down

0 comments on commit 2fe7b1f

Please sign in to comment.