File tree Expand file tree Collapse file tree 3 files changed +9
-9
lines changed
Expand file tree Collapse file tree 3 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -47,10 +47,10 @@ use macos as platform;
4747///
4848/// ## Environment Variables
4949///
50- /// | Env. Var. | Description |
51- /// |---------------- |---------------------------------------------------------------------------------------|
52- /// | SSL_CERT_FILE | File containing an arbitrary number of certificates in PEM format. |
53- /// | SSL_CERT_DIR | Colon separated list of directories containing certificate files. |
50+ /// | Env. Var. | Description |
51+ /// |---------------|---------------------------------------------------------------------------------------|
52+ /// | SSL_CERT_FILE | File containing an arbitrary number of certificates in PEM format. |
53+ /// | SSL_CERT_DIR | Colon separated list of directories containing certificate files. |
5454///
5555/// If **either** (or **both**) are set, certificates are only loaded from
5656/// the locations specified via environment variables and not the platform-
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ pub fn load_native_certs() -> CertificateResult {
1414 //
1515 // So we collect the certificates in this order; as a map of
1616 // their DER encoding to what we'll do with them. We don't
17- // overwrite existing elements, which mean User settings
17+ // overwrite existing elements, which means User settings
1818 // trump Admin trump System, as desired.
1919
2020 let mut result = CertificateResult :: default ( ) ;
@@ -40,11 +40,11 @@ pub fn load_native_certs() -> CertificateResult {
4040 let der = cert. to_der ( ) ;
4141
4242 // If there are no specific trust settings, the default
43- // is to trust the certificate as a root cert. Weird API but OK.
43+ // is to trust the certificate as a root cert. Weird API but OK.
4444 // The docs say:
4545 //
46- // "Note that an empty Trust Settings array means " always trust this cert,
47- // with a resulting kSecTrustSettingsResult of kSecTrustSettingsResultTrustRoot".
46+ // "Note that an empty Trust Settings array means ' always trust this cert,
47+ // with a resulting kSecTrustSettingsResult of kSecTrustSettingsResultTrustRoot'."
4848 let trusted = match ts. tls_trust_settings_for_certificate ( & cert) {
4949 Ok ( trusted) => trusted. unwrap_or ( TrustSettingsForCertificate :: TrustRoot ) ,
5050 Err ( err) => {
Original file line number Diff line number Diff line change 11use std:: env;
22
3- /// Cargo, at least sometimes, sets SSL_CERT_FILE and SSL_CERT_DIR internally,
3+ /// Cargo, at least sometimes, sets SSL_CERT_FILE and SSL_CERT_DIR internally, as
44/// it uses OpenSSL. So, always unset both at the beginning of a test even if
55/// the test doesn't use either.
66///
You can’t perform that action at this time.
0 commit comments