Function

SSLWrite

Performs a typical application-level write operation.

Declaration

OSStatus SSLWrite(SSLContextRef context, const void *data, size_t dataLength, size_t *processed);

Parameters

context

An SSL session context reference.

data

A pointer to the buffer of data to write.

dataLength

The amount, in bytes, of data to write.

processed

On return, the length, in bytes, of the data actually written.

Return Value

A result code. See Secure Transport Result Codes.

Discussion

The SSLWrite function might call the SSLWriteFunc function that you provide (see SSLSetIOFuncs). Because you may configure the underlying connection to operate in a no-blocking manner, a write operation might return errSSLWouldBlock, indicating that less data than requested was actually transferred. In this case, you should repeat the call to SSLWrite until some other result is returned.

See Also

Write Operations

SSLGetDatagramWriteSize

Provides the largest packet that the OS guarantees it can send without fragmentation.

Deprecated
SSLGetMaxDatagramRecordSize

Obtains the maximum datagram record size allowed by the application for a given context.

Deprecated
SSLSetMaxDatagramRecordSize

Sets the maximum datagram record size allowed by the application for a given context.

Deprecated
SSLSetDatagramHelloCookie

Sets the cookie value used in the Datagram Transport Layer Security (DTLS) hello message.

Deprecated

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software