Security risk error for Cockpit in Brave browser

I was opening up Cockpit for the first time to try it out and I followed the steps provided here: https://en.opensuse.org/Main:Cockpit.

When I typed in my IP address followed by :9090 in my browser (I use Brave browser), I got this error.

Note that the white boxes are to hide my computer’s IP address (and other personal browsing items) for privacy reasons.

I don’t think I should be concerned about this given it is only accessed locally, but I wanted to be sure. Can anyone confirm/deny this?

The same behaviour was exhibited if I typed in my computer’s hostname followed by :9090.

I tried searching online before posting here but it was of no help.

Thank you, Jaymo

@jaymo_chicago2 Correct, localhost connection, but if connecting to other instances on the local network, you need to trust…

Try using it with http instead of https?

Self-signed certificates will cause this, and locally-installed web services that run over https will always use self-signed certificates that are not part of any valid trust chain. It’s expected and normal, nothing to be concerned about.

3 Likes

Cockpit redirects to https, as I recall, because the user has to submit credentials through an http form.


So, no,

Ah, OK, on localhost it doesn’t auto-redirect. On public interfaces, it absolutely does, and it will give the warning because of the self-signed certificate. I just tested that with a fresh install of Cockpit on TW, and that is the behavior.

ETA: https://cockpit-project.org/guide/latest/https documents this.

That makes sense, I guess, since a localhost connection is not likely to be sniffed. But regardless, the warning message is due to the certificate being self-signed, and generally isn’t a concern under those circumstances.

One could always set up their own CA, put it in the trust chain, and then sign your own certificates - or get an external domain and get a real certificate, but for admin tools run on a local network only, that’s generally going to be overkill unless those services are exposed on the public Internet.

Yep, I had already seen that.

And OP said they used their computer’s IP address (not localhost), so this redirect is the cause of their issue.

1 Like

I tested with local IP addresses:

and:


Apparently the OP used the network IP :smile:

Yes, that’s what they said.

And the page at https://en.opensuse.org/Main:Cockpit (which they referenced) indicates that as the first of two options (the second is to use localhost).

Hehehehe, I’m old. My computer’s IP address is 127.0.0.1 :rofl: But I get the point.

1 Like

Thanks for all the replies. I tried accessing cockpit by just typing in localhost:9090 and it worked without giving me that error.

I thought that, when the Cockpit page said “localhost”, I thought it meant the actual hostname on my computer (not the word “localhost”).

I realised I neglected to mention some information about this computer:

  • It is not public facing (or not intended to be). I have ssh disabled upon install and the firewall enabled with the default settings from the installer. I double checked this with:
sudo systemctl status sshd
[sudo] password for root: 
○ sshd.service - OpenSSH Daemon
     Loaded: loaded (/usr/lib/systemd/system/sshd.service; disabled; preset: disabled)
     Active: inactive (dead)
systemctl status sshd
○ sshd.service - OpenSSH Daemon
     Loaded: loaded (/usr/lib/systemd/system/sshd.service; disabled; preset: disabled)
     Active: inactive (dead)
  • The IP address is the one I took from Network Manager that it says is my computer’s IP address under IPv4. It’s the one I used then typed in :9090 after it.
  • I don’t intend to manage any other machines from this computer.

Given this, did I risk exposing myself to anything when I used the IP address from Network Manager to access cockpit?

I don’t know anything about networking so I try to keep very conservative and minimise what can communicate with my computer (I only need standard Internet access, but no ssh, no hosting anything, etc.).

I’ll have to search what sniffing means too in the sense of networking.

Always something new to learn everyday. :smiley:

Thanks for the help!

Nope, the firewall was blocked, but the IP address of your network interface is still accessible from the local machine.

For information about network sniffing, have a look at the information for a program called Wireshark. It’s a very good piece of software for that, and if you can find a good explainer, you’ll get a solid foundation in what it is and how it works.

Basically, though, any traffic from your machine to another machine on a network can be listened to (some networking devices) by a device sitting between the source and destination. Encryption with SSL/TLS certificate means the contents of the traffic can’t be read unless the certificate’s private key (which should be kept private) is used to decrypt it.

So using an SSL connection - even with a self-signed certificate - means that the username/password cannot be easily decrypted in transit using a tool like Wireshark - unless the attacker also has the private key for the certificate.

So even if the external port was open and someone would have been able to sniff the data on your network (meaning they were on your network and using a device that could actually listen in - an ethernet hub, a switch with specific functionality to allow it (sometimes called a “monitor” port or setting), or a wifi connection - the use of the certificate would have prevented them from being able to actually see your local username and password.

2 Likes

Sounds good, thank you @hendersj for your help and the information about network sniffing and network traffic.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.