Skip to content

abstract class OpenSSL::SSL::Socket
inherits IO

Included modules

IO::Buffered

Direct known subclasses

OpenSSL::SSL::Socket::Client OpenSSL::SSL::Socket::Server

Methods

#alpn_protocol

Returns the negotiated ALPN protocol (eg: "h2") of nil if no protocol was negotiated.

View source

#cipher : String

Returns the current cipher used by this socket.

View source

#closed? : Bool

Returns true if this IO is closed.

IO defines returns false, but including types may override.

View source

#finalize

View source

#hostname : String?

Returns the hostname provided through Server Name Indication (SNI)

View source

#local_address

View source

#read_timeout

View source

#read_timeout=(value)

View source

#remote_address

View source

#sync_close=(sync_close : Bool)

If #sync_close? is true, closing this socket will close the underlying IO.

View source

#sync_close? : Bool

If #sync_close? is true, closing this socket will close the underlying IO.

View source

#tls_version : String

Returns the name of the TLS protocol version used by this socket.

View source

#unbuffered_close

Closes the wrapped IO.

View source

#unbuffered_flush

Flushes the wrapped IO.

View source

#unbuffered_read(slice : Bytes)

Reads at most slice.size bytes from the wrapped IO into slice. Returns the number of bytes read.

View source

#unbuffered_rewind

Rewinds the wrapped IO.

View source

#unbuffered_write(slice : Bytes)

Writes at most slice.size bytes from slice into the wrapped IO. Returns the number of bytes written.

View source

#write_timeout

View source

#write_timeout=(value)

View source