Class: OutlineVpnApi::PinnedConnectionAdapter
- Inherits:
-
HTTParty::ConnectionAdapter
- Object
- HTTParty::ConnectionAdapter
- OutlineVpnApi::PinnedConnectionAdapter
- Defined in:
- lib/outline_vpn_api/pinned_connection_adapter.rb
Instance Method Summary collapse
Instance Method Details
#connection ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/outline_vpn_api/pinned_connection_adapter.rb', line 8 def connection http = super return http unless http.use_ssl? http.verify_mode = OpenSSL::SSL::VERIFY_PEER http.verify_hostname = false http.verify_callback = ->(_preverify_ok, store_context) { pinned?(store_context.current_cert) } http end |