Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reverseproxy: feature request: certificate pinning for use with tls_insecure_skip_verify #6330

Open
akovalenko opened this issue May 20, 2024 · 1 comment

Comments

@akovalenko
Copy link
Contributor

Unfortunately there are times where you need tls_insecure_skip_verify in production, like reverse proxying to old, outdated devices, with awfully wrong self-signed certificates that might be expired and never updated.

I propose an option for pinning fixed certificates to such endpoints, like a PR #6329 that I use in my own setup.

First, we get SHA256 fingerprint of the certificate:
openssl x509 -in .lnd/tls.cert -noout -fingerprint -sha256

Then we add a directive alongside tls_insecure_skip_verify:
tls_server_cert_sha256 "07:E9:E5:E8:50:54:26:CE:7D:37:A4:4F:71:15:0B:3A:53:B3:65:A6:9E:B8:D9:20:93:54:94:16:2D:48:23:01"

Now our security exception doesn't allow an easy MITM attack.

@mholt
Copy link
Member

mholt commented May 29, 2024

Thanks for the issue (and the PR) -- I'll look into this after the 2.8 release!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants