Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix up privileged port exposure #192

Merged
merged 1 commit into from
Nov 12, 2020

Conversation

rhatdan
Copy link
Contributor

@rhatdan rhatdan commented Nov 11, 2020

This error is showing up looking like

podman run -p 80:80 fedora echo hello
Error: failed to expose ports via rootlessport: "cannot expose privileged port 80, you might need to add "net.ipv4.ip_unprivileged_port_start=0" (currently 1024) to /etc/sysctl.conf, or choose a larger port number (>= 1024): listen tcp 0.0.0.0:80: bind: permission denied\n"

When run in Podman, trying to clean it up a little so the special chars " to
not show up, and I think it makes more senset to tell users to start have priv
port, at least from a security point of view. Users probably want to keep this above port 22.

net.ipv4.ip_unprivileged_port_start=80

Rather then
net.ipv4.ip_unprivileged_port_start=0

Signed-off-by: Daniel J Walsh [email protected]

This error is showing up looking like

podman run -p 80:80 fedora echo hello
Error: failed to expose ports via rootlessport: "cannot expose privileged port 80, you might need to add \"net.ipv4.ip_unprivileged_port_start=0\" (currently 1024) to /etc/sysctl.conf, or choose a larger port number (>= 1024): listen tcp 0.0.0.0:80: bind: permission denied\n"

When run in Podman, trying to clean it up a little so the special chars \" to
not show up, and I think it makes more senset to tell users to start have priv
port, at least from a security point of view.  Users probably want to keep this above port 22.

net.ipv4.ip_unprivileged_port_start=80

Rather then
net.ipv4.ip_unprivileged_port_start=0

Signed-off-by: Daniel J Walsh <[email protected]>
Copy link
Member

@AkihiroSuda AkihiroSuda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@AkihiroSuda AkihiroSuda merged commit 0a22b0d into rootless-containers:master Nov 12, 2020
@AkihiroSuda
Copy link
Member

Released v0.11.1 with this

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.

2 participants