php8.5
Home/ Manual/ event / eventbufferevent/ EventBufferEvent::sslSocket

EventBufferEvent::sslSocket

PHP function Edit on GitHub ✎

(PECL event >= 1.2.6-beta)

Creates a new SSL buffer event to send its data over an SSL on a socket

Description

EventBufferEvent::sslSocket(EventBase $base, mixed $socket, EventSslContext $ctx, int $state, [int $options]): EventBufferEvent

Creates a new SSL buffer event to send its data over an SSL on a socket.

Parameters

base

Associated event base.

socket

Socket to use for this SSL. Can be stream or socket resource, numeric file descriptor, or null. If socket is null, it is assumed that the file descriptor for the socket will be assigned later, for instance, by means of EventBufferEvent::connectHost method.

ctx

Object of EventSslContext class.

state

The current state of SSL connection: EventBufferEvent::SSL_OPEN, EventBufferEvent::SSL_ACCEPTING or EventBufferEvent::SSL_CONNECTING.

options

The buffer event options.

Return Values

Returns EventBufferEvent object.

See Also

  • EventBufferEvent::sslFilter

Source: reference/event/eventbufferevent/sslsocket.xml · from the official PHP manual (php/doc-en)