/* * Active Router Transport Protocol (ARTP) implementation * Copyright (c) 2004, Tomas Rebok * All rights reserved. * * This program is free software; you can redistribute it and/or * modify it under the terms of the "BSD License" which is * distributed with the software in the file LICENSE. * * This program is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the BSD * License for more details. */ /** @file * @c ARTP datagram's types. * @author Tomas Rebok * @date 2004 */ #ifndef ARTP_TYPES_H #define ARTP_TYPES_H 1 /** option identification type (options sent in headers of packets) */ #define OPTS_OPTID_TYPE uint16_t /** option size type (options sent in headers of packets) */ #define OPTS_SZ_TYPE uint16_t /** signed packet payload size type */ #define SIGSZ_TYPE uint32_t /** encrypted packet payload size type */ #define ENCDATA_SIZE_TYPE uint32_t /** packet data sequence type */ #define DSEQ_TYPE uint32_t /** control packet option identifier type */ #define CTRL_OPTID_TYPE uint8_t /** one control item size type */ #define CTRL_SZ_TYPE uint16_t /** control value size type */ #define CTRL_VALUE_SZ_TYPE int /** session identification type */ #define SID_TYPE uint8_t /** session identification max value */ #define SID_MAX UINT8_MAX /** sequence numbers type */ #define SEQ_TYPE uint32_t /** sequence numbers maximal value */ #define SEQ_MAX UINT32_MAX /** packet timestamps type */ #define TS_TYPE uint32_t /** packet option size type */ #define OPTSZ_TYPE uint16_t /** packet fragments count type */ #define FRAGMENTS_TYPE uint16_t /** packet option - maximum segment size */ #define MSS_TYPE uint16_t /** packet option - maximum datagram length */ #define MAX_DGRAM_LEN_TYPE uint32_t /** packet option - retransmits timeout */ #define RETR_TIMEOUT_TYPE uint16_t #endif /* vim: set ts=4 : */