4.4 KiB
4.4 KiB
eac-openrc-compat
Lets the Easy Anti-Cheat Linux v2 setup install and run its service on an
OpenRC host. It provides only what the setup (EasyAntiCheat_EOS_Setup, 0.1.7)
calls; nothing here talks to systemd or pretends a systemd boot to other
software (/run/systemd/system stays absent, sd_booted() returns 0).
What the EAC setup does
On the first protected launch the game writes the setup to
/tmp/EasyAntiCheat_EOS_Setup.XXXXXX/ and runs verify-and-install <product>:
- Proton has set no_new_privs, so the setup re-runs itself with
systemd-run --user --wait --pipe --collect --quiet --setenv=... <setup> .... - Outside Proton it runs
pkexec <setup> install <product>(polkit prompt). - As root it writes
/usr/local/bin/easyanticheat_eos,/usr/lib/systemd/system/easyanticheat_eos.{socket,service},/var/lib/easyanticheat_eos/(state,authorizedusers/<uid>), then runssystemctl --version(needs systemd >= 249),daemon-reload,enable --quiet easyanticheat_eos.socketandstart. - The game connects to the abstract socket
@easyanticheat_eos; the service starts with that socket (LISTEN_FDS) andEAC_MODE_SERVICE=1, and stops when the game exits.
Logs: ~/.cache/com.epicgames.easyanticheat/service.log (setup),
/var/log/socket-activate.easyanticheat_eos.log (service), syslog tags
systemctl-compat and systemd-run-agent.
Files
| File | Role |
|---|---|
/usr/lib64/libsystemd.so.0 |
link to elogind's library, which exports the same LIBSYSTEMD_* symbols the setup uses (sd_listen_fds, sd_is_socket_unix, sd_notify) |
/usr/bin/systemd-run |
the --user form only, forwarded to systemd-run-agent; anything else fails as on a host without a user manager |
/usr/libexec/eac-openrc-compat/systemd-run-agent |
runs those commands in the graphical session, with the session's environment, outside the caller's process tree |
/usr/bin/systemctl |
units NAME.socket/NAME.service map to the OpenRC service socket-activate.NAME when it exists; other units fail as on a host not booted with systemd |
/usr/libexec/eac-openrc-compat/socket-activate |
socket-activate [-n] {stream|seqpacket} ADDRESS COMMAND [ARGS...]: listens on ADDRESS (@NAME = abstract) and starts COMMAND with the socket as fd 3 for each burst of connections, like Accept=no |
/etc/init.d/socket-activate |
OpenRC service family; instances are links socket-activate.NAME |
/etc/conf.d/socket-activate.easyanticheat_eos |
the EAC instance |
Instance settings (/etc/conf.d/socket-activate.NAME)
| Variable | Meaning |
|---|---|
socket_type |
stream (default) or seqpacket |
socket_address |
@NAME for an abstract socket, else a path |
socket_nonblocking |
yes: O_NONBLOCK on the socket (systemd NonBlocking=yes) |
socket_command |
the service binary and its arguments |
socket_env |
space-separated KEY=VALUE pairs for the service |
systemctl mapping
| systemctl | OpenRC |
|---|---|
--version |
prints systemd 257 |
daemon-reload, reset-failed |
nothing |
start |
rc-service -N socket-activate.NAME start |
stop NAME.service |
restarts the listener, which ends the running service; the socket keeps listening |
stop NAME.socket, stop NAME.* |
rc-service -s ... stop |
restart |
rc-service ... restart |
enable [--now], disable [--now] |
rc-update add/del ... default |
is-enabled |
enabled/disabled from the default runlevel; static for a .service |
is-active, status |
rc-service ... status |
Setup
- Start the agent in the graphical session, e.g. Hyprland:
hl.exec_cmd("/usr/libexec/eac-openrc-compat/systemd-run-agent"). - Run a session-wide polkit authentication agent in that session
(hyprpolkitagent, polkit-gnome, lxqt-policykit, ...).
pkttyagentdoes not work: without--processit registers only for its parent shell, so polkit finds no agent for the setup and pkexec fails at once ("pkexec auth failed" in the setup's log). Check withsystemd-run --user --wait --pipe pkexec --disable-internal-agent /usr/bin/true: "No authentication agent found" means none is registered for the session. - Launch the game and accept the service installation. The setup enables
socket-activate.easyanticheat_eosin the default runlevel itself.
Remove EAC's files again with pkexec /usr/local/bin/easyanticheat_eos uninstall standalone, then rc-update del socket-activate.easyanticheat_eos.