[Libwebsockets] Default port 80/443
andy at warmcat.com
Wed May 5 08:10:12 CEST 2021
On 5/5/21 2:30 AM, Jacky Bek wrote:
> I read that the default port for web sockets is either 80 or 443.
> However when I execute libwebsockets, it uses 7681.
The examples explicitly default to use 7681, because they are examples.
If I instead put 80 or 443 in the examples, you have to run them as root
to listen on those low ports, and you may already be running some other
server on that machine on 80 or 443 so they conflict.
> Can this be changed programmatically ?
If you just look at the sources for any of the server examples, you can
see what is going on with that
More information about the Libwebsockets