|
wired
libc-free QUIC/HTTP3 SDK in C for x86_64-linux
|
RFC 9000 17. More...
#include "common/platform/sys/syscall.h"Go to the source code of this file.
Data Structures | |
| struct | wired_header |
| Parsed invariant (version-independent) packet header fields. More... | |
Functions | |
| usz | wired_header_parse (const u8 *buf, usz n, wired_header *h) |
| Parse the invariant (version-independent) part of a packet header. | |
| usz | wired_header_build_long (u8 *buf, usz cap, const wired_header *h) |
| Build the invariant part of a long header into buf (cap bytes). | |
RFC 9000 17.
Packet header form is the high bit of byte 0.
| usz wired_header_build_long | ( | u8 * | buf, |
| usz | cap, | ||
| const wired_header * | h ) |
Build the invariant part of a long header into buf (cap bytes).
| buf | destination buffer |
| cap | capacity of buf in bytes |
| h | the header fields to encode |
| usz wired_header_parse | ( | const u8 * | buf, |
| usz | n, | ||
| wired_header * | h ) |
Parse the invariant (version-independent) part of a packet header.
For a short header the caller must preset h->dcid_len to the local CID length.
| buf | the packet bytes |
| n | length of buf in bytes |
| h | receives the parsed header fields |