You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The cloudflared service install creates a service file that runs the cloudflared process as root. Unless some privileged operation is required (e.g. raw sockets), the service should run as a non-privileged user, such as cloudflared. Even with trusted processes, bugs that allow privilege escalation can appear.
To Reproduce
Steps to reproduce the behavior:
Run cloudflared service install;
A service file that starts the cloudflared process as root is created;
Expected behavior
The cloudflare service runs as a non-privileged user, such as cloudflared. Additional restrictions, such as SELinux policies (e.g., similar to nginx), should also improve security.
Environment and versions
OS: Centos Stream 8
Architecture: AMD64 (should not be architecture-dependent)
Version: 2022.6.2
Additional context
The issue may be resolved by adding User=cloudflared to the Service section of the configuration file. The user would have to be created, likely as a system user.
Describe the bug
The
cloudflared service installcreates a service file that runs thecloudflaredprocess as root. Unless some privileged operation is required (e.g. raw sockets), the service should run as a non-privileged user, such ascloudflared. Even with trusted processes, bugs that allow privilege escalation can appear.To Reproduce
Steps to reproduce the behavior:
cloudflared service install;cloudflaredprocess as root is created;Expected behavior
The cloudflare service runs as a non-privileged user, such as
cloudflared. Additional restrictions, such as SELinux policies (e.g., similar tonginx), should also improve security.Environment and versions
Additional context
The issue may be resolved by adding
User=cloudflaredto theServicesection of the configuration file. The user would have to be created, likely as a system user.