GNUnet  0.11.x
Data Fields
EncryptedMessage Struct Reference

Encapsulation for encrypted messages exchanged between peers. More...

Collaboration diagram for EncryptedMessage:
[legend]

Data Fields

struct GNUNET_MessageHeader header
 Message type is GNUNET_MESSAGE_TYPE_CORE_ENCRYPTED_MESSAGE. More...
 
uint32_t iv_seed
 Random value used for IV generation. More...
 
struct GNUNET_HashCode hmac
 MAC of the encrypted message (starting at sequence_number), used to verify message integrity. More...
 
uint32_t sequence_number
 Sequence number, in network byte order. More...
 
uint32_t reserved
 Reserved, always zero. More...
 
struct GNUNET_TIME_AbsoluteNBO timestamp
 Timestamp. More...
 

Detailed Description

Encapsulation for encrypted messages exchanged between peers.

Followed by the actual encrypted data.

Definition at line 196 of file gnunet-service-core_kx.c.

Field Documentation

◆ header

struct GNUNET_MessageHeader EncryptedMessage::header

Message type is GNUNET_MESSAGE_TYPE_CORE_ENCRYPTED_MESSAGE.

Definition at line 201 of file gnunet-service-core_kx.c.

Referenced by check_encrypted(), and handle_encrypted().

◆ iv_seed

uint32_t EncryptedMessage::iv_seed

Random value used for IV generation.

Definition at line 206 of file gnunet-service-core_kx.c.

Referenced by GSC_KX_encrypt_and_transmit(), and handle_encrypted().

◆ hmac

struct GNUNET_HashCode EncryptedMessage::hmac

MAC of the encrypted message (starting at sequence_number), used to verify message integrity.

Everything after this value (excluding this value itself) will be encrypted and authenticated. ENCRYPTED_HEADER_SIZE must be set to the offset of the next field.

Definition at line 215 of file gnunet-service-core_kx.c.

Referenced by GSC_KX_encrypt_and_transmit(), and handle_encrypted().

◆ sequence_number

uint32_t EncryptedMessage::sequence_number

Sequence number, in network byte order.

This field must be the first encrypted/decrypted field

Definition at line 221 of file gnunet-service-core_kx.c.

Referenced by GSC_KX_encrypt_and_transmit(), and handle_encrypted().

◆ reserved

uint32_t EncryptedMessage::reserved

Reserved, always zero.

Definition at line 226 of file gnunet-service-core_kx.c.

◆ timestamp

struct GNUNET_TIME_AbsoluteNBO EncryptedMessage::timestamp

Timestamp.

Used to prevent replay of ancient messages (recent messages are caught with the sequence number).

Definition at line 232 of file gnunet-service-core_kx.c.

Referenced by handle_encrypted().


The documentation for this struct was generated from the following file: