struct Crabbit::TLSConfig

Overview

TLS settings shared by Stream connections.

Defined in:

crabbit/configuration.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(context : OpenSSL::SSL::Context::Client = OpenSSL::SSL::Context::Client.new, verify_hostname : Bool = true) #

Creates TLS settings.

Hostname verification should only be disabled in controlled development environments. Configure custom trust roots and client certificates on context before opening the environment.


[View source]

Instance Method Detail

def context : OpenSSL::SSL::Context::Client #

Returns the OpenSSL client context used for certificate verification and optional client certificates.


[View source]
def verify_hostname : Bool #

Returns whether the advertised endpoint hostname is verified.


[View source]