File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -16,12 +16,17 @@ pub struct ProbeResult {
1616/// found.
1717///
1818/// This will only search known system locations.
19+ #[ doc( hidden) ]
20+ #[ deprecated( note = "use `candidate_cert_dirs` instead" ) ]
1921pub fn find_certs_dirs ( ) -> Vec < PathBuf > {
20- cert_dirs_iter ( ) . map ( Path :: to_path_buf) . collect ( )
22+ candidate_cert_dirs ( ) . map ( Path :: to_path_buf) . collect ( )
2123}
2224
23- // TODO: when we bump to 0.2, make this the `find_certs_dirs` function
24- fn cert_dirs_iter ( ) -> impl Iterator < Item = & ' static Path > {
25+ /// Probe the system for the directory in which CA certificates should likely be
26+ /// found.
27+ ///
28+ /// This will only search known system locations.
29+ pub fn candidate_cert_dirs ( ) -> impl Iterator < Item = & ' static Path > {
2530 // see http://gagravarr.org/writing/openssl-certs/others.shtml
2631 [
2732 "/var/ssl" ,
@@ -161,7 +166,7 @@ fn probe_from_env() -> ProbeResult {
161166/// The probe result is returned as a [`ProbeResult`] structure here.
162167pub fn probe ( ) -> ProbeResult {
163168 let mut result = probe_from_env ( ) ;
164- for certs_dir in cert_dirs_iter ( ) {
169+ for certs_dir in candidate_cert_dirs ( ) {
165170 // cert.pem looks to be an openssl 1.0.1 thing, while
166171 // certs/ca-certificates.crt appears to be a 0.9.8 thing
167172 let cert_filenames = [
You can’t perform that action at this time.
0 commit comments