You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@mcollina awesome, the selfsigned module is just what I was looking for. If you check out PR #2, you can see that I generate a new self-signed cert when the module is required for the fist time. This is different than on install as you suggested. How do you feel about that?
If generated on install time instead, where did you have in mind that the cert and private key should be stored? Inside the node_modules/https-pem folder somewhere?
I kind of like that it's self contained and that each installation will generate a new certificate. I've updated the PR to now generate them upon install. Thanks for your help 😃
Activity
watson commentedon Dec 3, 2017
This tool is only meant for testing and debugging and shouldn't be used in any production code.
That being said, I'd love if it was possible to just generate a key on the fly. Do you know of any way to do this?
mcollina commentedon Dec 7, 2017
You can use https://www.npmjs.com/package/pem or https://www.npmjs.com/package/selfsigned.
Generate selfsigned certificate on require
watson commentedon Dec 7, 2017
@mcollina awesome, the selfsigned module is just what I was looking for. If you check out PR #2, you can see that I generate a new self-signed cert when the module is required for the fist time. This is different than on install as you suggested. How do you feel about that?
mcollina commentedon Dec 7, 2017
That would slow startup down, but it will be very safe!
watson commentedon Dec 7, 2017
If generated on install time instead, where did you have in mind that the cert and private key should be stored? Inside the
node_modules/https-pemfolder somewhere?mcollina commentedon Dec 7, 2017
That’d be good, or maybe in ~/.config/https-pem/, so that’s stable across reinstalls.
watson commentedon Dec 7, 2017
I kind of like that it's self contained and that each installation will generate a new certificate. I've updated the PR to now generate them upon install. Thanks for your help 😃
Generate private key and self-signed certificate upon install (#2)
watson commentedon Dec 7, 2017
Released as v2.0.0