ttalvitie / browservice

Browservice: Browse the modern web on historical browsers
MIT License
1.11k stars 32 forks source link

HTTP Server fails to start #61

Closed gothickitty93 closed 2 years ago

gothickitty93 commented 2 years ago

Using a raspberry pi 3, i can't get the server to run. Appimage, or compile from source always results in the same error.

pi@[REDACTED]:~/browservice/release/bin $ ./brow* --http-listen-addr=10.0.0.210:80 --vice-opt-http-auth=[REDACTED]:[REDACTED]

WARNING @ src/config.cpp:241 -- The command line option --http-listen-addr is a deprecated alias for --vice-opt-http-listen-addr INFO @ src/main.cpp:200 -- Loading vice plugin retrojsvice.so INFO @ src/main.cpp:207 -- Initializing vice plugin retrojsvice.so INFO @ retrojsvice.so src/context.cpp:281 -- Creating retrojsvice plugin context INFO @ src/xvfb.cpp:64 -- Starting Xvfb X server as child process INFO @ src/xvfb.cpp:135 -- Xvfb X server :0 successfully started INFO @ retrojsvice.so src/context.cpp:331 -- Starting plugin INFO @ retrojsvice.so src/http.cpp:620 -- Starting HTTP server (listen address: 10.0.0.210:80) PANIC @ retrojsvice.so src/http.cpp:625: Starting Poco HTTP server failed with exception: I/O error: Permission denied Aborted

Any idea what I might be doing wrong?

H4xX0r1337 commented 2 years ago

same issue on raspberry pi 2

ttalvitie commented 2 years ago

You get the error because by default, only root can listen to privileged ports (that is, ports in range 1-1023). This is why all the examples use port 8080 instead (for security reasons, you should never run browservice as root). If you really want to use port 80 for Browservice, there are a few options:

H4xX0r1337 commented 2 years ago

@ttalvitie I tried using authbind with this command authbind --deep ./browservice-v0.9.4.0-armhf.AppImage --vice-opt-http-listen-addr=0.0.0.0:666 (also tried to manually set the depth), and got the same error with no difference). higher ports work fine though, so thanks for helping me already

gothickitty93 commented 2 years ago

You get the error because by default, only root can listen to privileged ports (that is, ports in range 1-1023). This is why all the examples use port 8080 instead (for security reasons, you should never run browservice as root). If you really want to use port 80 for Browservice, there are a few options:

  • You can use authbind to give your user permission to listen to that port.
  • You can listen to a non-privileged port and forward port 80 to it (for example by using iptables).

Thanks for clarifying this. Marking as closed.