Skip to content

Instantly share code, notes, and snippets.

@udhos
Created December 10, 2018 20:09
Show Gist options
  • Save udhos/81159cf41f43b40397124b5d41acd300 to your computer and use it in GitHub Desktop.
Save udhos/81159cf41f43b40397124b5d41acd300 to your computer and use it in GitHub Desktop.
How can I listen on ports 80 and 443? Do I have to run as root?
On Linux, you can use setcap to grant your binary the permission to bind low ports:
$ sudo setcap cap_net_bind_service=+ep /path/to/your/binary
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment