Adding the ability to move the API from HTTP to HTTPS over TLS. #7573
Replies: 5 comments 8 replies
-
The lotus team may consider accepting a well-written and self-contained patch adding this feature, but it's not going to be a priority for the core team and there are some significant security concerns. Users should use something like nginx as a reverse proxy to handle HTTPs as these tools are very carefully written to:
The lotus API endpoint simply isn't designed to be exposed to the public internet unprotected. We're going to add some documentation to make that clear. While this can be difficult to setup, exposing the lotus API to the internet without having the expertise to deploy something like this is a bad idea. Lotus nodes are a very juicy target. |
Beta Was this translation helpful? Give feedback.
-
@Stebalien , I agree with you completely. Myself I run it behind a Hardware Fortigate firewall with IPS,DOS and deep-inspection. But it doesn't change the fact that within the network if a malicious attacker was sniffing traffic (man-in-the -middle) the API key would have been exposed in plain text when the Market node was communicating to the Miner node. Therefore I think it should be possible and leave the choice up to the person implementation the Lotus solution within there network/infrastructure if they want http or http connecivity between Lotus, Market, Miner ... Also, a little side note. I noticed that there are a lot of people that run Lotus routed over the internet with only a Linux firewall on the machine itself filtering ports but don't have anything that protects them against : (Handle network DoS attacks (slow loris, rate limit, etc..) - Like you mentioned. @jennijuju @Stefaan-V , I think it's really imported to have a look on how people build there infrastructure with security in mind. Like we already discussed potentially setting up a workshop of some kind around security. @Stebalien , thanks for you reply and insights 👍 |
Beta Was this translation helpful? Give feedback.
-
you can always offload the TLS to a proxy - on both ends. in the end its just http traffic we access lotus on the miners via vpn/ssh tunnels for example. that would work network internally too |
Beta Was this translation helpful? Give feedback.
-
@f8-ptrk , I agree that works too. I'm just trying to create awareness around that. It does involve a more complex setup on the infrastructure side running a proxy / vpn tunnel / or other between hosts for host-to-host http encryption. Would be nice if it's available in the software we are using ... |
Beta Was this translation helpful? Give feedback.
-
Yes, like we discussed on slack, Let's encrypt would help on the public side, internally that would involve self signed certs (more admin like you mentioned) or a way to use a wildcard Let's encrypt cert and distribute that (that's what I do sometimes for other app's (not lotus) - have a node request the wilcard cert publicly and then distribute to other nodes ). (All nodes internally have to be reachable on fqdn that way) |
Beta Was this translation helpful? Give feedback.
-
Design summary
The reasoning behind this is make sure no API data/commands are being read during a man-in-de-middle attack
Just an idea because the other day when I was migrating my market node on a separate machine and started the dagstore migration I saw the miner API key going through my network in clear text. TLS/HTTPS would have protected my key in that case.
Beta Was this translation helpful? Give feedback.
All reactions