aboutsummaryrefslogtreecommitdiffstats
path: root/doc/manual/tls.rst
diff options
context:
space:
mode:
Diffstat (limited to 'doc/manual/tls.rst')
-rw-r--r--doc/manual/tls.rst30
1 files changed, 15 insertions, 15 deletions
diff --git a/doc/manual/tls.rst b/doc/manual/tls.rst
index aa075141d..32f6c5fb2 100644
--- a/doc/manual/tls.rst
+++ b/doc/manual/tls.rst
@@ -36,7 +36,7 @@ Starting in 1.11.31, the application callbacks are encapsulated as the class
mandatory for using TLS, all others are optional and provide additional
information about the connection.
- .. cpp:function:: void tls_emit_data(const byte data[], size_t data_len)
+ .. cpp:function:: void tls_emit_data(const uint8_t data[], size_t data_len)
Mandatory. The TLS stack requests that all bytes of *data* be queued up to send to the
counterparty. After this function returns, the buffer containing *data* will
@@ -50,7 +50,7 @@ information about the connection.
For TLS all writes must occur *in the order requested*.
For DTLS this ordering is not strictly required, but is still recommended.
- .. cpp:function:: void tls_record_received(uint64_t rec_no, const byte data[], size_t data_len)
+ .. cpp:function:: void tls_record_received(uint64_t rec_no, const uint8_t data[], size_t data_len)
Mandatory. Called once for each application_data record which is received, with the
matching (TLS level) record sequence number.
@@ -165,8 +165,8 @@ available:
.. cpp:class:: TLS::Channel
- .. cpp:function:: size_t received_data(const byte buf[], size_t buf_size)
- .. cpp:function:: size_t received_data(const std::vector<byte>& buf)
+ .. cpp:function:: size_t received_data(const uint8_t buf[], size_t buf_size)
+ .. cpp:function:: size_t received_data(const std::vector<uint8_t>& buf)
This function is used to provide data sent by the counterparty
(eg data that you read off the socket layer). Depending on the
@@ -179,9 +179,9 @@ available:
the data fell exactly on a message boundary, in which case it
will return 0 instead.
- .. cpp:function:: void send(const byte buf[], size_t buf_size)
+ .. cpp:function:: void send(const uint8_t buf[], size_t buf_size)
.. cpp:function:: void send(const std::string& str)
- .. cpp:function:: void send(const std::vector<byte>& vec)
+ .. cpp:function:: void send(const std::vector<uint8_t>& vec)
Create one or more new TLS application records containing the
provided data and send them. This will eventually result in at
@@ -650,7 +650,7 @@ information about that session:
Returns ``true`` if the connection was negotiated with the
correct extensions to prevent the renegotiation attack.
- .. cpp:function:: std::vector<byte> encrypt(const SymmetricKey& key, \
+ .. cpp:function:: std::vector<uint8_t> encrypt(const SymmetricKey& key, \
RandomNumberGenerator& rng)
Encrypts a session using a symmetric key *key* and returns a raw
@@ -660,14 +660,14 @@ information about that session:
Currently the implementation encrypts the session using AES-256
in GCM mode with a random nonce.
- .. cpp:function:: static Session decrypt(const byte ciphertext[], \
+ .. cpp:function:: static Session decrypt(const uint8_t ciphertext[], \
size_t length, \
const SymmetricKey& key)
Decrypts a session that was encrypted previously with ``encrypt`` and
``key``, or throws an exception if decryption fails.
- .. cpp:function:: secure_vector<byte> DER_encode() const
+ .. cpp:function:: secure_vector<uint8_t> DER_encode() const
Returns a serialized version of the session.
@@ -693,12 +693,12 @@ implementation to the ``TLS::Client`` or ``TLS::Server`` constructor.
ID will replicate a session ID already stored, in which case the
new session information should overwrite the previous information.
- .. cpp:function:: void remove_entry(const std::vector<byte>& session_id)
+ .. cpp:function:: void remove_entry(const std::vector<uint8_t>& session_id)
Remove the session identified by *session_id*. Future attempts
at resumption should fail for this session.
- .. cpp:function:: bool load_from_session_id(const std::vector<byte>& session_id, \
+ .. cpp:function:: bool load_from_session_id(const std::vector<uint8_t>& session_id, \
Session& session)
Attempt to resume a session identified by *session_id*. If
@@ -923,7 +923,7 @@ policy settings from a file.
Default: false
- .. cpp:function:: std::vector<byte> compression() const
+ .. cpp:function:: std::vector<uint8_t> compression() const
Return the list of compression methods we are willing to use, in order of
preference. Default is null compression only.
@@ -1073,7 +1073,7 @@ TLS Ciphersuites
.. cpp:class:: TLS::Ciphersuite
- .. cpp:function:: u16bit ciphersuite_code() const
+ .. cpp:function:: uint16_t ciphersuite_code() const
Return the numerical code for this ciphersuite
@@ -1141,11 +1141,11 @@ The ``TLS::Protocol_Version`` class represents a specific version:
Create a specific version
- .. cpp:function:: byte major_version() const
+ .. cpp:function:: uint8_t major_version() const
Returns major number of the protocol version
- .. cpp:function:: byte minor_version() const
+ .. cpp:function:: uint8_t minor_version() const
Returns minor number of the protocol version