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

Pastey, Let's Encrypt, & NodeJS builtin CAs #11

Closed
xurizaemon opened this issue Sep 10, 2018 · 4 comments
Closed

Pastey, Let's Encrypt, & NodeJS builtin CAs #11

xurizaemon opened this issue Sep 10, 2018 · 4 comments

Comments

@xurizaemon
Copy link
Owner

Aw heck. So http://paste.example.org now 301s to https://paste.example.org where SSL is via a Let's Encrypt cert, and Node uses a hardcoded list of certificate authorities. TIL.

I had a tutu with this to support an additional config option to pass in a CA for LE, but it was just going to add a bunch of code and make things more complicated ... and you'd need to do the same workaround for other Node apps anyway. So here's my fix:

sudo wget -O /etc/ssl/certs/lets-encrypt-x3-cross-signed.pem https://letsencrypt.org/certs/lets-encrypt-x3-cross-signed.pem.txt
export NODE_EXTRA_CA_CERTS=/etc/ssl/certs/lets-encrypt-x3-cross-signed.pem

You'll want the environment variable set appropriately ... I may not think this fix is sufficient if it means repeating the process on every server I use pastey on.

(Surely NodeJS isn't broken like this?!)

@xurizaemon
Copy link
Owner Author

Hmm, I think paste.example.org may have just used cert.pem not fullchain.pem, so I will ask the EXAMPLEORG sysadmins very nicely if they will have a look at that first.

@xurizaemon
Copy link
Owner Author

This was an issue with cert configuration on the server in question, and has been resolved. Yay!

@AdamMajer
Copy link

Node doesn't use hardcoded list of certs for a loooong time. Just FYI.

@xurizaemon
Copy link
Owner Author

xurizaemon commented Feb 8, 2019

Thanks! Yeah looks like I misled myself debugging, and it was actually cert chain issue if I recall.

Hecking exampleorg admins eh.

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