I am trying to use the http in node to get from an https server with a
self signed certificate, but can't work out exactly what to do. I used
Julian's excellent script [0] (many thanks for that Julian) to create
the stuff for the server and that is working well when I fetch using
the browser (having installed the the certificate
my-private-root-ca.crt in the browser. I am having difficulty doing
the same thing using the http in node though.
I have put the url as https and enabled tls, but in the tls config it
wants a certificate, private key and ca certificate, whereas for the
browser I just needed the ca certificate. I tried filling in just the
ca but I just get 'self signed certificate in chain'. The other files
the script makes for the client are chain.pem and server-pubkey.pem
but those don't seem to fit the field names in the tls config.
Can someone point me in the right direction?
Colin
[0]
https://github.com/TotallyInformation/SelfSigned-Cert-Creator