java.lang.Object
org.miaixz.bus.http.secure.CertificatePinner.Builder
- Enclosing class:
CertificatePinner
A builder for creating a
CertificatePinner.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionPins certificates for a given hostname pattern.build()Builds theCertificatePinnerwith the configured pins.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
add
Pins certificates for a given hostname pattern.- Parameters:
pattern- A lowercase hostname or wildcard pattern (e.g.,*.example.com).pins- One or more SHA-256 or SHA-1 hashes. Each pin is a base64-encoded hash of a certificate's Subject Public Key Info, prefixed withsha256/orsha1/.- Returns:
- This builder instance.
-
build
Builds theCertificatePinnerwith the configured pins.- Returns:
- A new
CertificatePinnerinstance.
-