allinurl/goaccess

Unable to authenticate WebSocket.

Closed this issue · 10 comments

I upgraded from version 1.7 to 1.9.4, and the following picture appears, showing
Unable to authenticate WebSocket.
, the configuration file used has not changed, and it can be started successfully in version 1.7. Could you tell me what might be the problem? The direct output html file looks like this
Image

It seems like there’s an issue connecting to the websocket server. Are you seeing any errors in the browser's console?

It seems like there’s an issue connecting to the websocket server. Are you seeing any errors in the browser's console?

Image

Image
These are the errors reported by console and my configurations, that may help

Can you post how you are running goaccess websocket connection? It seems you are behind a proxied nginx, so your goaccess ws-url connection should attempt to connect to the proxied Nginx endpoint, not directly to port 7880.

Can you post how you are running goaccess websocket connection? It seems you are behind a proxied nginx, so your goaccess ws-url connection should attempt to connect to the proxied Nginx endpoint, not directly to port 7880.

Image

I don’t set the ws-url actually , what shall i do

Can you post how you are running goaccess websocket connection? It seems you are behind a proxied nginx, so your goaccess ws-url connection should attempt to connect to the proxied Nginx endpoint, not directly to port 7880.

I tried to set the ws-url to wss://goaccess.1.xyz/ws (assuming my root domain is 1.xyz), but on the web side I can see that ws still tries to connect to wss://goaccess.1.xyz:7880/ws, that is weird!

I found a way, change wss://goaccess.1.xyz/ws to wss://goaccess.1.xyz:443/ws and it works, I always thought that wss not writing the port meant to use 80 or 443, my bad.

Great to hear that it’s been resolved. I’ll close this now, but feel free to reopen if anything else comes up.

Great to hear that it’s been resolved. I’ll close this now, but feel free to reopen if anything else comes up.

Image
I noticed that when I hover over certain information, a pop-up window appears centered around the mouse cursor to display details. Would it be possible to adjust the positioning so that the pop-up appears in the lower-right corner of the cursor instead? I’d really appreciate it!

I am facing the same issue. I ran the following command but unable to authenticate to wss when trying to access the report through which is configured with nginx and certbot:

goaccess /var/log/nginx/access.log -c -o /usr/share/nginx/html/<mydomain>/index.html --log-format=COMBINED --real-time-html

I am facing the same issue. I ran the following command but unable to authenticate to wss when trying to access the report through which is configured with nginx and certbot:

goaccess /var/log/nginx/access.log -c -o /usr/share/nginx/html/<mydomain>/index.html --log-format=COMBINED --real-time-html

If you're using WSS, you'll need to configure GoAccess with the SSL certificate and key generated by Certbot. You can do this by passing the certificate and key paths using the --ssl-cert and --ssl-key options, like this: --ssl-cert=<path/cert.crt> and --ssl-key=<path/priv.key>. Additionally, make sure to load the report using HTTPS, e.g., https://myurl.com/report.html