2
0

pinnedpubkey.d 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
  2. SPDX-License-Identifier: curl
  3. Long: pinnedpubkey
  4. Arg: <hashes>
  5. Help: FILE/HASHES Public key to verify peer against
  6. Protocols: TLS
  7. Category: tls
  8. Example: --pinnedpubkey keyfile $URL
  9. Example: --pinnedpubkey 'sha256//ce118b51897f4452dc' $URL
  10. Added: 7.39.0
  11. See-also: hostpubsha256
  12. Multi: single
  13. ---
  14. Tells curl to use the specified public key file (or hashes) to verify the
  15. peer. This can be a path to a file which contains a single public key in PEM
  16. or DER format, or any number of base64 encoded sha256 hashes preceded by
  17. 'sha256//' and separated by ';'.
  18. When negotiating a TLS or SSL connection, the server sends a certificate
  19. indicating its identity. A public key is extracted from this certificate and
  20. if it does not exactly match the public key provided to this option, curl
  21. aborts the connection before sending or receiving any data.
  22. This option is independent of option --insecure. If you use both options
  23. together then the peer is still verified by public key.
  24. PEM/DER support:
  25. OpenSSL and GnuTLS (added in 7.39.0), wolfSSL (added in 7.43.0), mbedTLS
  26. (added in 7.47.0), Secure Transport macOS 10.7+/iOS 10+ (7.54.1), Schannel
  27. (7.58.1)
  28. sha256 support:
  29. OpenSSL, GnuTLS and wolfSSL (added in 7.44.0), mbedTLS (added in 7.47.0),
  30. Secure Transport macOS 10.7+/iOS 10+ (7.54.1), Schannel (7.58.1)
  31. Other SSL backends not supported.