Skip to content

Randomize local server port#485

Draft
execjosh wants to merge 1 commit into
felixhageloh:masterfrom
execjosh:randomize-local-server-port
Draft

Randomize local server port#485
execjosh wants to merge 1 commit into
felixhageloh:masterfrom
execjosh:randomize-local-server-port

Conversation

@execjosh
Copy link
Copy Markdown
Contributor

@execjosh execjosh commented Aug 4, 2022

Make the port of the local server harder to guess, which will help prevent naïve exploitation of the privilege escalation threat of the /run/ endpoint. This can be circumvented by inspecting the command line of the process, or scanning all the local ports, to discover the correct port; however, it is better than nothing.

One concern is how to handle the CORS proxy. Making its port unpredictable is probably suboptimal. However, the server currently uses the provided port plus one for CORS, which would not be 41417 anyway if 41416 were to have already been in use when Übersicht started up. Randomizing the port would make such an edge case the normal case.

Make the port of the local server harder to guess, which will help prevent
naïve exploitation of the privilege escalation threat posed by the `/run/`
endpoint.  This can be circumvented by inspecting the command line of the
process, or scanning all the local ports, to discover the correct port;
however, it is better than nothing.
@execjosh execjosh force-pushed the randomize-local-server-port branch from e2e1db0 to a568b98 Compare August 5, 2022 03:09
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