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

Support servername https option #2320

Open
1 task done
fholzer opened this issue Jan 8, 2024 · 0 comments
Open
1 task done

Support servername https option #2320

fholzer opened this issue Jan 8, 2024 · 0 comments

Comments

@fholzer
Copy link

fholzer commented Jan 8, 2024

What problem are you trying to solve?

Support servername https option. This alows user to send requests to servers that don't have a proper domain name, but use a certificate with a known CN/SAN that should be verified.

Describe the feature

Tells node's tls module what domain name to expect in the certificate returned by the server. No login needs to be added to got.

To support this, the only change needed to got is to add servername: undefined to the https object of defaultInternals in options.js. Without this, the set https(value) setter throws. Maybe a string type assertion in the setter would be good too.

Checklist

  • I have read the documentation and made sure this feature doesn't already exist.
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

1 participant