Linux heracles.o2switch.net 4.18.0-553.62.1.lve.el8.x86_64 #1 SMP Mon Jul 21 17:50:35 UTC 2025 x86_64
/
opt
/
alt
/
ruby21
/
share
/
ri
/
2.1.0
/
system
/
OpenSSL
/
X509
/
Store
/
//opt/alt/ruby21/share/ri/2.1.0/system/OpenSSL/X509/Store/cdesc-Store.ri
U:RDoc::NormalClass[iI" Store:ETI"OpenSSL::X509::Store;TI"Object;To:RDoc::Markup::Document:@parts[o;;[o:RDoc::Markup::Paragraph;[I"MThe X509 certificate store holds trusted CA certificates used to verify ;TI"peer certificates.;To:RDoc::Markup::BlankLine o; ;[I"=The easiest way to create a useful certificate store is:;T@o:RDoc::Markup::Verbatim;[I"+cert_store = OpenSSL::X509::Store.new ;TI""cert_store.set_default_paths ;T:@format0o; ;[I"7This will use your system's built-in certificates.;T@o; ;[ I"HIf your system does not have a default set of certificates you can ;TI"Mobtain a set from Mozilla here: http://curl.haxx.se/docs/caextract.html ;TI"K(Note that this set does not have an HTTPS download option so you may ;TI"Jwish to use the firefox-db2pem.sh script to extract the certificates ;TI">from a local install to avoid man-in-the-middle attacks.);T@o; ;[I"JAfter downloading or generating a cacert.pem from the above link you ;TI"@can create a certificate store from the pem file like this:;T@o;;[I"+cert_store = OpenSSL::X509::Store.new ;TI"&cert_store.add_file 'cacert.pem' ;T;0o; ;[I"CThe certificate store can be used with an SSLSocket like this:;T@o;;[I"0ssl_context = OpenSSL::SSL::SSLContext.new ;TI")ssl_context.cert_store = cert_store ;TI" ;TI"4tcp_socket = TCPSocket.open 'example.com', 443 ;TI" ;TI"Essl_socket = OpenSSL::SSL::SSLSocket.new tcp_socket, ssl_context;T;0: @fileI"!ext/openssl/ossl_x509store.c;T:0@omit_headings_from_table_of_contents_below0; 0;0[ [ I" chain;TI"R;T:publicFI"!ext/openssl/ossl_x509store.c;T[ I" error;TI"R;T;F@<[ I"error_string;TI"R;T;F@<[ I"verify_callback;TI"R;T;F@<[ [ [[I" class;T[[;[[I"new;T@<[:protected[ [:private[ [I" instance;T[[;[[I" add_cert;T@<[I"add_crl;T@<[I" add_file;T@<[I" add_path;T@<[I"flags=;T@<[I" purpose=;T@<[I"set_default_paths;T@<[I" time=;T@<[I"trust=;T@<[I"verify;T@<[I"verify_callback=;T@<[;[ [;[ [ [U:RDoc::Context::Section[i 0o;;[ ; 0;0[I"#ext/openssl/ossl_ssl_session.c;TI"OpenSSL::X509;TcRDoc::NormalModule