Skip to content

Security enhancement: Run web server with unprivileged user#5

Open
DrMurx wants to merge 4 commits intokonstantinj:masterfrom
DrMurx:master
Open

Security enhancement: Run web server with unprivileged user#5
DrMurx wants to merge 4 commits intokonstantinj:masterfrom
DrMurx:master

Conversation

@DrMurx
Copy link
Contributor

@DrMurx DrMurx commented Dec 2, 2016

Despite the level of isolation Docker provides, it's a bad idea to run a web server as root in a container:

Bugs in either the PHP builtin web server or the postfixadmin code may allow an intruder to modify container-local files (such as the postfixadmin sources itself) and eventually alter mailbox configurations.

Therefore the exposed web server now runs as user nobody on an unprivileged port. Consequently, the owner of the postfixadmin sources is assured to be root during container build time.

@DrMurx DrMurx force-pushed the master branch 6 times, most recently from 2e752aa to 868f948 Compare January 20, 2017 03:26
DrMurx added 4 commits June 25, 2018 00:27
* Fix ownership of application code
* Run webserver without root privileges
* Don't output any errors to the browser
* Use `exec` to ease docker process handling
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant