tcpdump  4.99.1
About: tcpdump is a tool for network monitoring and data acquisition.
  Fossies Dox: tcpdump-4.99.1.tar.gz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

print-isakmp.c File Reference
#include "netdissect-stdinc.h"
#include <string.h>
#include "netdissect-ctype.h"
#include "netdissect.h"
#include "addrtoname.h"
#include "extract.h"
#include "ip.h"
#include "ip6.h"
#include "ipproto.h"
Include dependency graph for print-isakmp.c:

Go to the source code of this file.

Data Structures

struct  isakmp
 
struct  isakmp_gen
 
struct  isakmp_data
 
struct  ikev1_pl_sa
 
struct  ikev1_pl_p
 
struct  ikev1_pl_t
 
struct  ikev1_pl_ke
 
struct  ikev1_pl_id
 
struct  ikev1_pl_cert
 
struct  ikev1_pl_cr
 
struct  ikev1_pl_hash
 
struct  ikev1_pl_sig
 
struct  ikev1_pl_nonce
 
struct  ikev1_pl_n
 
struct  ikev1_pl_d
 
struct  ikev2_p
 
struct  ikev2_t
 
struct  ikev2_ke
 
struct  ikev2_id
 
struct  ikev2_n
 
struct  notify_messages
 
struct  ikev2_auth
 
struct  ipsecdoi_sa
 
struct  ipsecdoi_secrecy_h
 
struct  ipsecdoi_id
 
union  inaddr_u
 
struct  attrmap
 

Macros

#define PORT_ISAKMP   500
 
#define ISAKMP_VERS_MAJOR   0xf0
 
#define ISAKMP_VERS_MAJOR_SHIFT   4
 
#define ISAKMP_VERS_MINOR   0x0f
 
#define ISAKMP_VERS_MINOR_SHIFT   0
 
#define ISAKMP_NPTYPE_NONE   0 /* NONE*/
 
#define ISAKMP_NPTYPE_SA   1 /* Security Association */
 
#define ISAKMP_NPTYPE_P   2 /* Proposal */
 
#define ISAKMP_NPTYPE_T   3 /* Transform */
 
#define ISAKMP_NPTYPE_KE   4 /* Key Exchange */
 
#define ISAKMP_NPTYPE_ID   5 /* Identification */
 
#define ISAKMP_NPTYPE_CERT   6 /* Certificate */
 
#define ISAKMP_NPTYPE_CR   7 /* Certificate Request */
 
#define ISAKMP_NPTYPE_HASH   8 /* Hash */
 
#define ISAKMP_NPTYPE_SIG   9 /* Signature */
 
#define ISAKMP_NPTYPE_NONCE   10 /* Nonce */
 
#define ISAKMP_NPTYPE_N   11 /* Notification */
 
#define ISAKMP_NPTYPE_D   12 /* Delete */
 
#define ISAKMP_NPTYPE_VID   13 /* Vendor ID */
 
#define ISAKMP_NPTYPE_v2E   46 /* v2 Encrypted payload */
 
#define IKEv1_MAJOR_VERSION   1
 
#define IKEv1_MINOR_VERSION   0
 
#define IKEv2_MAJOR_VERSION   2
 
#define IKEv2_MINOR_VERSION   0
 
#define ISAKMP_FLAG_E   0x01 /* Encryption Bit */
 
#define ISAKMP_FLAG_C   0x02 /* Commit Bit */
 
#define ISAKMP_FLAG_extra   0x04
 
#define ISAKMP_FLAG_I   (1 << 3) /* (I)nitiator */
 
#define ISAKMP_FLAG_V   (1 << 4) /* (V)ersion */
 
#define ISAKMP_FLAG_R   (1 << 5) /* (R)esponse */
 
#define ISAKMP_NTYPE_INVALID_PAYLOAD_TYPE   1
 
#define ISAKMP_NTYPE_DOI_NOT_SUPPORTED   2
 
#define ISAKMP_NTYPE_SITUATION_NOT_SUPPORTED   3
 
#define ISAKMP_NTYPE_INVALID_COOKIE   4
 
#define ISAKMP_NTYPE_INVALID_MAJOR_VERSION   5
 
#define ISAKMP_NTYPE_INVALID_MINOR_VERSION   6
 
#define ISAKMP_NTYPE_INVALID_EXCHANGE_TYPE   7
 
#define ISAKMP_NTYPE_INVALID_FLAGS   8
 
#define ISAKMP_NTYPE_INVALID_MESSAGE_ID   9
 
#define ISAKMP_NTYPE_INVALID_PROTOCOL_ID   10
 
#define ISAKMP_NTYPE_INVALID_SPI   11
 
#define ISAKMP_NTYPE_INVALID_TRANSFORM_ID   12
 
#define ISAKMP_NTYPE_ATTRIBUTES_NOT_SUPPORTED   13
 
#define ISAKMP_NTYPE_NO_PROPOSAL_CHOSEN   14
 
#define ISAKMP_NTYPE_BAD_PROPOSAL_SYNTAX   15
 
#define ISAKMP_NTYPE_PAYLOAD_MALFORMED   16
 
#define ISAKMP_NTYPE_INVALID_KEY_INFORMATION   17
 
#define ISAKMP_NTYPE_INVALID_ID_INFORMATION   18
 
#define ISAKMP_NTYPE_INVALID_CERT_ENCODING   19
 
#define ISAKMP_NTYPE_INVALID_CERTIFICATE   20
 
#define ISAKMP_NTYPE_BAD_CERT_REQUEST_SYNTAX   21
 
#define ISAKMP_NTYPE_INVALID_CERT_AUTHORITY   22
 
#define ISAKMP_NTYPE_INVALID_HASH_INFORMATION   23
 
#define ISAKMP_NTYPE_AUTHENTICATION_FAILED   24
 
#define ISAKMP_NTYPE_INVALID_SIGNATURE   25
 
#define ISAKMP_NTYPE_ADDRESS_NOTIFICATION   26
 
#define IPSEC_DOI   1
 
#define IPSECDOI_SIT_IDENTITY_ONLY   0x00000001
 
#define IPSECDOI_SIT_SECRECY   0x00000002
 
#define IPSECDOI_SIT_INTEGRITY   0x00000004
 
#define IPSECDOI_PROTO_ISAKMP   1
 
#define IPSECDOI_KEY_IKE   1
 
#define IPSECDOI_PROTO_IPSEC_AH   2
 
#define IPSECDOI_AH_MD5   2
 
#define IPSECDOI_AH_SHA   3
 
#define IPSECDOI_AH_DES   4
 
#define IPSECDOI_AH_SHA2_256   5
 
#define IPSECDOI_AH_SHA2_384   6
 
#define IPSECDOI_AH_SHA2_512   7
 
#define IPSECDOI_PROTO_IPSEC_ESP   3
 
#define IPSECDOI_ESP_DES_IV64   1
 
#define IPSECDOI_ESP_DES   2
 
#define IPSECDOI_ESP_3DES   3
 
#define IPSECDOI_ESP_RC5   4
 
#define IPSECDOI_ESP_IDEA   5
 
#define IPSECDOI_ESP_CAST   6
 
#define IPSECDOI_ESP_BLOWFISH   7
 
#define IPSECDOI_ESP_3IDEA   8
 
#define IPSECDOI_ESP_DES_IV32   9
 
#define IPSECDOI_ESP_RC4   10
 
#define IPSECDOI_ESP_NULL   11
 
#define IPSECDOI_ESP_RIJNDAEL   12
 
#define IPSECDOI_ESP_AES   12
 
#define IPSECDOI_PROTO_IPCOMP   4
 
#define IPSECDOI_IPCOMP_OUI   1
 
#define IPSECDOI_IPCOMP_DEFLATE   2
 
#define IPSECDOI_IPCOMP_LZS   3
 
#define IPSECDOI_ATTR_SA_LTYPE   1 /* B */
 
#define IPSECDOI_ATTR_SA_LTYPE_DEFAULT   1
 
#define IPSECDOI_ATTR_SA_LTYPE_SEC   1
 
#define IPSECDOI_ATTR_SA_LTYPE_KB   2
 
#define IPSECDOI_ATTR_SA_LDUR   2 /* V */
 
#define IPSECDOI_ATTR_SA_LDUR_DEFAULT   28800 /* 8 hours */
 
#define IPSECDOI_ATTR_GRP_DESC   3 /* B */
 
#define IPSECDOI_ATTR_ENC_MODE   4 /* B */
 
#define IPSECDOI_ATTR_ENC_MODE_TUNNEL   1
 
#define IPSECDOI_ATTR_ENC_MODE_TRNS   2
 
#define IPSECDOI_ATTR_AUTH   5 /* B */
 
#define IPSECDOI_ATTR_AUTH_HMAC_MD5   1
 
#define IPSECDOI_ATTR_AUTH_HMAC_SHA1   2
 
#define IPSECDOI_ATTR_AUTH_DES_MAC   3
 
#define IPSECDOI_ATTR_AUTH_KPDK   4 /*RFC-1826(Key/Pad/Data/Key)*/
 
#define IPSECDOI_ATTR_KEY_LENGTH   6 /* B */
 
#define IPSECDOI_ATTR_KEY_ROUNDS   7 /* B */
 
#define IPSECDOI_ATTR_COMP_DICT_SIZE   8 /* B */
 
#define IPSECDOI_ATTR_COMP_PRIVALG   9 /* V */
 
#define IPSECDOI_ID_IPV4_ADDR   1
 
#define IPSECDOI_ID_FQDN   2
 
#define IPSECDOI_ID_USER_FQDN   3
 
#define IPSECDOI_ID_IPV4_ADDR_SUBNET   4
 
#define IPSECDOI_ID_IPV6_ADDR   5
 
#define IPSECDOI_ID_IPV6_ADDR_SUBNET   6
 
#define IPSECDOI_ID_IPV4_ADDR_RANGE   7
 
#define IPSECDOI_ID_IPV6_ADDR_RANGE   8
 
#define IPSECDOI_ID_DER_ASN1_DN   9
 
#define IPSECDOI_ID_DER_ASN1_GN   10
 
#define IPSECDOI_ID_KEY_ID   11
 
#define IPSECDOI_NTYPE_RESPONDER_LIFETIME   24576
 
#define IPSECDOI_NTYPE_REPLAY_STATUS   24577
 
#define IPSECDOI_NTYPE_INITIAL_CONTACT   24578
 
#define DECLARE_PRINTER(func)
 
#define MAXINITIATORS   20
 
#define STR_OR_ID(x, tab)    (((x) < sizeof(tab)/sizeof(tab[0]) && tab[(x)]) ? tab[(x)] : numstr(x))
 
#define PROTOIDSTR(x)   STR_OR_ID(x, protoidstr)
 
#define NPSTR(x)   STR_OR_ID(x, npstr)
 
#define ETYPESTR(x)   STR_OR_ID(x, etypestr)
 
#define CHECKLEN(p, np)
 
#define NPFUNC(x)
 
#define cookie_isinitiator(ndo, x, y)   cookie_sidecheck(ndo, (x), (y), 1)
 
#define cookie_isresponder(ndo, x, y)   cookie_sidecheck(ndo, (x), (y), 0)
 
#define USE_IPSECDOI_IN_PHASE1   1
 
#define NOTIFY_ERROR_STR(x)    STR_OR_ID((x), notify_error_str)
 
#define IPSEC_NOTIFY_ERROR_STR(x)    STR_OR_ID((u_int)((x) - 8192), ipsec_notify_error_str)
 
#define NOTIFY_STATUS_STR(x)    STR_OR_ID((u_int)((x) - 16384), notify_status_str)
 
#define IPSEC_NOTIFY_STATUS_STR(x)    STR_OR_ID((u_int)((x) - 24576), ipsec_notify_status_str)
 

Typedefs

typedef nd_byte cookie_t[8]
 
typedef nd_byte msgid_t[4]
 

Enumerations

enum  ikev2_t_type {
  IV2_T_ENCR = 1 , IV2_T_PRF = 2 , IV2_T_INTEG = 3 , IV2_T_DH = 4 ,
  IV2_T_ESN = 5
}
 
enum  ikev2_id_type {
  ID_IPV4_ADDR =1 , ID_FQDN =2 , ID_RFC822_ADDR =3 , ID_IPV6_ADDR =5 ,
  ID_DER_ASN1_DN =9 , ID_DER_ASN1_GN =10 , ID_KEY_ID =11
}
 
enum  ikev2_n_type {
  IV2_NOTIFY_UNSUPPORTED_CRITICAL_PAYLOAD = 1 , IV2_NOTIFY_INVALID_IKE_SPI = 4 , IV2_NOTIFY_INVALID_MAJOR_VERSION = 5 , IV2_NOTIFY_INVALID_SYNTAX = 7 ,
  IV2_NOTIFY_INVALID_MESSAGE_ID = 9 , IV2_NOTIFY_INVALID_SPI =11 , IV2_NOTIFY_NO_PROPOSAL_CHOSEN =14 , IV2_NOTIFY_INVALID_KE_PAYLOAD =17 ,
  IV2_NOTIFY_AUTHENTICATION_FAILED =24 , IV2_NOTIFY_SINGLE_PAIR_REQUIRED =34 , IV2_NOTIFY_NO_ADDITIONAL_SAS =35 , IV2_NOTIFY_INTERNAL_ADDRESS_FAILURE =36 ,
  IV2_NOTIFY_FAILED_CP_REQUIRED =37 , IV2_NOTIFY_INVALID_SELECTORS =39 , IV2_NOTIFY_INITIAL_CONTACT =16384 , IV2_NOTIFY_SET_WINDOW_SIZE =16385 ,
  IV2_NOTIFY_ADDITIONAL_TS_POSSIBLE =16386 , IV2_NOTIFY_IPCOMP_SUPPORTED =16387 , IV2_NOTIFY_NAT_DETECTION_SOURCE_IP =16388 , IV2_NOTIFY_NAT_DETECTION_DESTINATION_IP =16389 ,
  IV2_NOTIFY_COOKIE =16390 , IV2_NOTIFY_USE_TRANSPORT_MODE =16391 , IV2_NOTIFY_HTTP_CERT_LOOKUP_SUPPORTED =16392 , IV2_NOTIFY_REKEY_SA =16393 ,
  IV2_NOTIFY_ESP_TFC_PADDING_NOT_SUPPORTED =16394 , IV2_NOTIFY_NON_FIRST_FRAGMENTS_ALSO =16395
}
 
enum  ikev2_auth_type { IV2_RSA_SIG = 1 , IV2_SHARED = 2 , IV2_DSS_SIG = 3 }
 

Functions

static const u_char * ikev1_sa_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_p_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_t_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_ke_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_id_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_cert_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_cr_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_sig_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_hash_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_nonce_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_n_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_d_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev1_vid_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_sa_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_ke_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_ID_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_cert_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_cr_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_auth_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_nonce_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_n_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_d_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_vid_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_TS_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_cp_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_eap_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ikev2_e_print (netdissect_options *ndo, const struct isakmp *base, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const u_char * ike_sub0_print (netdissect_options *ndo, u_char, const struct isakmp_gen *, const u_char *, uint32_t, uint32_t, uint32_t, int)
 
static const u_char * ikev1_sub_print (netdissect_options *ndo, u_char, const struct isakmp_gen *, const u_char *, uint32_t, uint32_t, uint32_t, int)
 
static const u_char * ikev2_sub_print (netdissect_options *ndo, const struct isakmp *base, u_char np, const struct isakmp_gen *ext, const u_char *ep, uint32_t phase, uint32_t doi, uint32_t proto, int depth)
 
static char * numstr (u_int)
 
static void ikev1_print (netdissect_options *ndo, const u_char *bp, u_int length, const u_char *bp2, const struct isakmp *base)
 
static int iszero (const u_char *p, size_t l)
 
static int cookie_find (const cookie_t *in)
 
static void cookie_record (netdissect_options *ndo, const cookie_t *in, const u_char *bp2)
 
static int cookie_sidecheck (netdissect_options *ndo, int i, const u_char *bp2, int initiator)
 
static void hexprint (netdissect_options *ndo, const uint8_t *loc, size_t len)
 
static int rawprint (netdissect_options *ndo, const uint8_t *loc, size_t len)
 
static int ike_show_somedata (netdissect_options *ndo, const u_char *cp, const u_char *ep)
 
static const u_char * ikev1_attrmap_print (netdissect_options *ndo, const u_char *p, const u_char *ep2, const struct attrmap *map, size_t nmap)
 
static const u_char * ikev1_attr_print (netdissect_options *ndo, const u_char *p, const u_char *ep2)
 
static void ikev2_pay_print (netdissect_options *ndo, const char *payname, uint8_t critical)
 
static const u_char * ikev2_gen_print (netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len)
 
static const u_char * ikev2_t_print (netdissect_options *ndo, int tcount, const struct isakmp_gen *ext, u_int item_len, const u_char *ep)
 
static const u_char * ikev2_p_print (netdissect_options *ndo, u_char tpay, int pcount, const struct isakmp_gen *ext, u_int oprop_length, const u_char *ep, int depth)
 
static const u_char * ikev2_sub0_print (netdissect_options *ndo, const struct isakmp *base, u_char np, const struct isakmp_gen *ext, const u_char *ep, uint32_t phase, uint32_t doi, uint32_t proto, int depth)
 
static void ikev2_print (netdissect_options *ndo, const u_char *bp, u_int length, const u_char *bp2, const struct isakmp *base)
 
void isakmp_print (netdissect_options *ndo, const u_char *bp, u_int length, const u_char *bp2)
 
void isakmp_rfc3948_print (netdissect_options *ndo, const u_char *bp, u_int length, const u_char *bp2, int ver, int fragmented, u_int ttl_hl)
 

Variables

static int ninitiator = 0
 
struct {
   cookie_t   initiator
 
   u_int   version
 
   union inaddr_u   iaddr
 
   union inaddr_u   raddr
 
cookiecache [20]
 
static const char * protoidstr []
 
static const char * npstr []
 
static const u_char *(* npfunc [])(netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
 
static const char * etypestr []
 
static const char * ikev1_p_map []
 
static const char * ikev2_t_type_map []
 
static const char * ah_p_map []
 
static const char * prf_p_map []
 
static const char * integ_p_map []
 
static const char * esn_p_map []
 
static const char * dh_p_map []
 
static const char * esp_p_map []
 
static const char * ipcomp_p_map []
 
static const struct attrmap ipsec_t_map []
 
static const struct attrmap encr_t_map []
 
static const struct attrmap oakley_t_map []
 

Macro Definition Documentation

◆ CHECKLEN

#define CHECKLEN (   p,
  np 
)
Value:
if (ep < (const u_char *)(p)) { \
ND_PRINT(" [|%s]", NPSTR(np)); \
goto done; \
}
#define NPSTR(x)
Definition: print-isakmp.c:729

Definition at line 732 of file print-isakmp.c.

◆ cookie_isinitiator

#define cookie_isinitiator (   ndo,
  x,
 
)    cookie_sidecheck(ndo, (x), (y), 1)

Definition at line 807 of file print-isakmp.c.

◆ cookie_isresponder

#define cookie_isresponder (   ndo,
  x,
 
)    cookie_sidecheck(ndo, (x), (y), 0)

Definition at line 808 of file print-isakmp.c.

◆ DECLARE_PRINTER

#define DECLARE_PRINTER (   func)
Value:
static const u_char *ike##func##_print( \
netdissect_options *ndo, u_char tpay, \
const struct isakmp_gen *ext, \
u_int item_len, \
const u_char *end_pointer, \
uint32_t phase,\
uint32_t doi0, \
uint32_t proto0, int depth)

Definition at line 569 of file print-isakmp.c.

◆ ETYPESTR

#define ETYPESTR (   x)    STR_OR_ID(x, etypestr)

Definition at line 730 of file print-isakmp.c.

◆ IKEv1_MAJOR_VERSION

#define IKEv1_MAJOR_VERSION   1

Definition at line 113 of file print-isakmp.c.

◆ IKEv1_MINOR_VERSION

#define IKEv1_MINOR_VERSION   0

Definition at line 114 of file print-isakmp.c.

◆ IKEv2_MAJOR_VERSION

#define IKEv2_MAJOR_VERSION   2

Definition at line 116 of file print-isakmp.c.

◆ IKEv2_MINOR_VERSION

#define IKEv2_MINOR_VERSION   0

Definition at line 117 of file print-isakmp.c.

◆ IPSEC_DOI

#define IPSEC_DOI   1

Definition at line 454 of file print-isakmp.c.

◆ IPSEC_NOTIFY_ERROR_STR

#define IPSEC_NOTIFY_ERROR_STR (   x)     STR_OR_ID((u_int)((x) - 8192), ipsec_notify_error_str)

◆ IPSEC_NOTIFY_STATUS_STR

#define IPSEC_NOTIFY_STATUS_STR (   x)     STR_OR_ID((u_int)((x) - 24576), ipsec_notify_status_str)

◆ IPSECDOI_AH_DES

#define IPSECDOI_AH_DES   4

Definition at line 471 of file print-isakmp.c.

◆ IPSECDOI_AH_MD5

#define IPSECDOI_AH_MD5   2

Definition at line 469 of file print-isakmp.c.

◆ IPSECDOI_AH_SHA

#define IPSECDOI_AH_SHA   3

Definition at line 470 of file print-isakmp.c.

◆ IPSECDOI_AH_SHA2_256

#define IPSECDOI_AH_SHA2_256   5

Definition at line 472 of file print-isakmp.c.

◆ IPSECDOI_AH_SHA2_384

#define IPSECDOI_AH_SHA2_384   6

Definition at line 473 of file print-isakmp.c.

◆ IPSECDOI_AH_SHA2_512

#define IPSECDOI_AH_SHA2_512   7

Definition at line 474 of file print-isakmp.c.

◆ IPSECDOI_ATTR_AUTH

#define IPSECDOI_ATTR_AUTH   5 /* B */

Definition at line 512 of file print-isakmp.c.

◆ IPSECDOI_ATTR_AUTH_DES_MAC

#define IPSECDOI_ATTR_AUTH_DES_MAC   3

Definition at line 516 of file print-isakmp.c.

◆ IPSECDOI_ATTR_AUTH_HMAC_MD5

#define IPSECDOI_ATTR_AUTH_HMAC_MD5   1

Definition at line 514 of file print-isakmp.c.

◆ IPSECDOI_ATTR_AUTH_HMAC_SHA1

#define IPSECDOI_ATTR_AUTH_HMAC_SHA1   2

Definition at line 515 of file print-isakmp.c.

◆ IPSECDOI_ATTR_AUTH_KPDK

#define IPSECDOI_ATTR_AUTH_KPDK   4 /*RFC-1826(Key/Pad/Data/Key)*/

Definition at line 517 of file print-isakmp.c.

◆ IPSECDOI_ATTR_COMP_DICT_SIZE

#define IPSECDOI_ATTR_COMP_DICT_SIZE   8 /* B */

Definition at line 527 of file print-isakmp.c.

◆ IPSECDOI_ATTR_COMP_PRIVALG

#define IPSECDOI_ATTR_COMP_PRIVALG   9 /* V */

Definition at line 528 of file print-isakmp.c.

◆ IPSECDOI_ATTR_ENC_MODE

#define IPSECDOI_ATTR_ENC_MODE   4 /* B */

Definition at line 508 of file print-isakmp.c.

◆ IPSECDOI_ATTR_ENC_MODE_TRNS

#define IPSECDOI_ATTR_ENC_MODE_TRNS   2

Definition at line 511 of file print-isakmp.c.

◆ IPSECDOI_ATTR_ENC_MODE_TUNNEL

#define IPSECDOI_ATTR_ENC_MODE_TUNNEL   1

Definition at line 510 of file print-isakmp.c.

◆ IPSECDOI_ATTR_GRP_DESC

#define IPSECDOI_ATTR_GRP_DESC   3 /* B */

Definition at line 507 of file print-isakmp.c.

◆ IPSECDOI_ATTR_KEY_LENGTH

#define IPSECDOI_ATTR_KEY_LENGTH   6 /* B */

Definition at line 525 of file print-isakmp.c.

◆ IPSECDOI_ATTR_KEY_ROUNDS

#define IPSECDOI_ATTR_KEY_ROUNDS   7 /* B */

Definition at line 526 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LDUR

#define IPSECDOI_ATTR_SA_LDUR   2 /* V */

Definition at line 505 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LDUR_DEFAULT

#define IPSECDOI_ATTR_SA_LDUR_DEFAULT   28800 /* 8 hours */

Definition at line 506 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LTYPE

#define IPSECDOI_ATTR_SA_LTYPE   1 /* B */

Definition at line 501 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LTYPE_DEFAULT

#define IPSECDOI_ATTR_SA_LTYPE_DEFAULT   1

Definition at line 502 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LTYPE_KB

#define IPSECDOI_ATTR_SA_LTYPE_KB   2

Definition at line 504 of file print-isakmp.c.

◆ IPSECDOI_ATTR_SA_LTYPE_SEC

#define IPSECDOI_ATTR_SA_LTYPE_SEC   1

Definition at line 503 of file print-isakmp.c.

◆ IPSECDOI_ESP_3DES

#define IPSECDOI_ESP_3DES   3

Definition at line 481 of file print-isakmp.c.

◆ IPSECDOI_ESP_3IDEA

#define IPSECDOI_ESP_3IDEA   8

Definition at line 486 of file print-isakmp.c.

◆ IPSECDOI_ESP_AES

#define IPSECDOI_ESP_AES   12

Definition at line 491 of file print-isakmp.c.

◆ IPSECDOI_ESP_BLOWFISH

#define IPSECDOI_ESP_BLOWFISH   7

Definition at line 485 of file print-isakmp.c.

◆ IPSECDOI_ESP_CAST

#define IPSECDOI_ESP_CAST   6

Definition at line 484 of file print-isakmp.c.

◆ IPSECDOI_ESP_DES

#define IPSECDOI_ESP_DES   2

Definition at line 480 of file print-isakmp.c.

◆ IPSECDOI_ESP_DES_IV32

#define IPSECDOI_ESP_DES_IV32   9

Definition at line 487 of file print-isakmp.c.

◆ IPSECDOI_ESP_DES_IV64

#define IPSECDOI_ESP_DES_IV64   1

Definition at line 479 of file print-isakmp.c.

◆ IPSECDOI_ESP_IDEA

#define IPSECDOI_ESP_IDEA   5

Definition at line 483 of file print-isakmp.c.

◆ IPSECDOI_ESP_NULL

#define IPSECDOI_ESP_NULL   11

Definition at line 489 of file print-isakmp.c.

◆ IPSECDOI_ESP_RC4

#define IPSECDOI_ESP_RC4   10

Definition at line 488 of file print-isakmp.c.

◆ IPSECDOI_ESP_RC5

#define IPSECDOI_ESP_RC5   4

Definition at line 482 of file print-isakmp.c.

◆ IPSECDOI_ESP_RIJNDAEL

#define IPSECDOI_ESP_RIJNDAEL   12

Definition at line 490 of file print-isakmp.c.

◆ IPSECDOI_ID_DER_ASN1_DN

#define IPSECDOI_ID_DER_ASN1_DN   9

Definition at line 559 of file print-isakmp.c.

◆ IPSECDOI_ID_DER_ASN1_GN

#define IPSECDOI_ID_DER_ASN1_GN   10

Definition at line 560 of file print-isakmp.c.

◆ IPSECDOI_ID_FQDN

#define IPSECDOI_ID_FQDN   2

Definition at line 552 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV4_ADDR

#define IPSECDOI_ID_IPV4_ADDR   1

Definition at line 551 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV4_ADDR_RANGE

#define IPSECDOI_ID_IPV4_ADDR_RANGE   7

Definition at line 557 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV4_ADDR_SUBNET

#define IPSECDOI_ID_IPV4_ADDR_SUBNET   4

Definition at line 554 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV6_ADDR

#define IPSECDOI_ID_IPV6_ADDR   5

Definition at line 555 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV6_ADDR_RANGE

#define IPSECDOI_ID_IPV6_ADDR_RANGE   8

Definition at line 558 of file print-isakmp.c.

◆ IPSECDOI_ID_IPV6_ADDR_SUBNET

#define IPSECDOI_ID_IPV6_ADDR_SUBNET   6

Definition at line 556 of file print-isakmp.c.

◆ IPSECDOI_ID_KEY_ID

#define IPSECDOI_ID_KEY_ID   11

Definition at line 561 of file print-isakmp.c.

◆ IPSECDOI_ID_USER_FQDN

#define IPSECDOI_ID_USER_FQDN   3

Definition at line 553 of file print-isakmp.c.

◆ IPSECDOI_IPCOMP_DEFLATE

#define IPSECDOI_IPCOMP_DEFLATE   2

Definition at line 497 of file print-isakmp.c.

◆ IPSECDOI_IPCOMP_LZS

#define IPSECDOI_IPCOMP_LZS   3

Definition at line 498 of file print-isakmp.c.

◆ IPSECDOI_IPCOMP_OUI

#define IPSECDOI_IPCOMP_OUI   1

Definition at line 496 of file print-isakmp.c.

◆ IPSECDOI_KEY_IKE

#define IPSECDOI_KEY_IKE   1

Definition at line 464 of file print-isakmp.c.

◆ IPSECDOI_NTYPE_INITIAL_CONTACT

#define IPSECDOI_NTYPE_INITIAL_CONTACT   24578

Definition at line 567 of file print-isakmp.c.

◆ IPSECDOI_NTYPE_REPLAY_STATUS

#define IPSECDOI_NTYPE_REPLAY_STATUS   24577

Definition at line 566 of file print-isakmp.c.

◆ IPSECDOI_NTYPE_RESPONDER_LIFETIME

#define IPSECDOI_NTYPE_RESPONDER_LIFETIME   24576

Definition at line 565 of file print-isakmp.c.

◆ IPSECDOI_PROTO_IPCOMP

#define IPSECDOI_PROTO_IPCOMP   4

Definition at line 494 of file print-isakmp.c.

◆ IPSECDOI_PROTO_IPSEC_AH

#define IPSECDOI_PROTO_IPSEC_AH   2

Definition at line 467 of file print-isakmp.c.

◆ IPSECDOI_PROTO_IPSEC_ESP

#define IPSECDOI_PROTO_IPSEC_ESP   3

Definition at line 477 of file print-isakmp.c.

◆ IPSECDOI_PROTO_ISAKMP

#define IPSECDOI_PROTO_ISAKMP   1

Definition at line 463 of file print-isakmp.c.

◆ IPSECDOI_SIT_IDENTITY_ONLY

#define IPSECDOI_SIT_IDENTITY_ONLY   0x00000001

Definition at line 457 of file print-isakmp.c.

◆ IPSECDOI_SIT_INTEGRITY

#define IPSECDOI_SIT_INTEGRITY   0x00000004

Definition at line 459 of file print-isakmp.c.

◆ IPSECDOI_SIT_SECRECY

#define IPSECDOI_SIT_SECRECY   0x00000002

Definition at line 458 of file print-isakmp.c.

◆ ISAKMP_FLAG_C

#define ISAKMP_FLAG_C   0x02 /* Commit Bit */

Definition at line 121 of file print-isakmp.c.

◆ ISAKMP_FLAG_E

#define ISAKMP_FLAG_E   0x01 /* Encryption Bit */

Definition at line 120 of file print-isakmp.c.

◆ ISAKMP_FLAG_extra

#define ISAKMP_FLAG_extra   0x04

Definition at line 122 of file print-isakmp.c.

◆ ISAKMP_FLAG_I

#define ISAKMP_FLAG_I   (1 << 3) /* (I)nitiator */

Definition at line 125 of file print-isakmp.c.

◆ ISAKMP_FLAG_R

#define ISAKMP_FLAG_R   (1 << 5) /* (R)esponse */

Definition at line 127 of file print-isakmp.c.

◆ ISAKMP_FLAG_V

#define ISAKMP_FLAG_V   (1 << 4) /* (V)ersion */

Definition at line 126 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_CERT

#define ISAKMP_NPTYPE_CERT   6 /* Certificate */

Definition at line 103 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_CR

#define ISAKMP_NPTYPE_CR   7 /* Certificate Request */

Definition at line 104 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_D

#define ISAKMP_NPTYPE_D   12 /* Delete */

Definition at line 109 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_HASH

#define ISAKMP_NPTYPE_HASH   8 /* Hash */

Definition at line 105 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_ID

#define ISAKMP_NPTYPE_ID   5 /* Identification */

Definition at line 102 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_KE

#define ISAKMP_NPTYPE_KE   4 /* Key Exchange */

Definition at line 101 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_N

#define ISAKMP_NPTYPE_N   11 /* Notification */

Definition at line 108 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_NONCE

#define ISAKMP_NPTYPE_NONCE   10 /* Nonce */

Definition at line 107 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_NONE

#define ISAKMP_NPTYPE_NONE   0 /* NONE*/

Definition at line 97 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_P

#define ISAKMP_NPTYPE_P   2 /* Proposal */

Definition at line 99 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_SA

#define ISAKMP_NPTYPE_SA   1 /* Security Association */

Definition at line 98 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_SIG

#define ISAKMP_NPTYPE_SIG   9 /* Signature */

Definition at line 106 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_T

#define ISAKMP_NPTYPE_T   3 /* Transform */

Definition at line 100 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_v2E

#define ISAKMP_NPTYPE_v2E   46 /* v2 Encrypted payload */

Definition at line 111 of file print-isakmp.c.

◆ ISAKMP_NPTYPE_VID

#define ISAKMP_NPTYPE_VID   13 /* Vendor ID */

Definition at line 110 of file print-isakmp.c.

◆ ISAKMP_NTYPE_ADDRESS_NOTIFICATION

#define ISAKMP_NTYPE_ADDRESS_NOTIFICATION   26

Definition at line 311 of file print-isakmp.c.

◆ ISAKMP_NTYPE_ATTRIBUTES_NOT_SUPPORTED

#define ISAKMP_NTYPE_ATTRIBUTES_NOT_SUPPORTED   13

Definition at line 298 of file print-isakmp.c.

◆ ISAKMP_NTYPE_AUTHENTICATION_FAILED

#define ISAKMP_NTYPE_AUTHENTICATION_FAILED   24

Definition at line 309 of file print-isakmp.c.

◆ ISAKMP_NTYPE_BAD_CERT_REQUEST_SYNTAX

#define ISAKMP_NTYPE_BAD_CERT_REQUEST_SYNTAX   21

Definition at line 306 of file print-isakmp.c.

◆ ISAKMP_NTYPE_BAD_PROPOSAL_SYNTAX

#define ISAKMP_NTYPE_BAD_PROPOSAL_SYNTAX   15

Definition at line 300 of file print-isakmp.c.

◆ ISAKMP_NTYPE_DOI_NOT_SUPPORTED

#define ISAKMP_NTYPE_DOI_NOT_SUPPORTED   2

Definition at line 287 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_CERT_AUTHORITY

#define ISAKMP_NTYPE_INVALID_CERT_AUTHORITY   22

Definition at line 307 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_CERT_ENCODING

#define ISAKMP_NTYPE_INVALID_CERT_ENCODING   19

Definition at line 304 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_CERTIFICATE

#define ISAKMP_NTYPE_INVALID_CERTIFICATE   20

Definition at line 305 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_COOKIE

#define ISAKMP_NTYPE_INVALID_COOKIE   4

Definition at line 289 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_EXCHANGE_TYPE

#define ISAKMP_NTYPE_INVALID_EXCHANGE_TYPE   7

Definition at line 292 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_FLAGS

#define ISAKMP_NTYPE_INVALID_FLAGS   8

Definition at line 293 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_HASH_INFORMATION

#define ISAKMP_NTYPE_INVALID_HASH_INFORMATION   23

Definition at line 308 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_ID_INFORMATION

#define ISAKMP_NTYPE_INVALID_ID_INFORMATION   18

Definition at line 303 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_KEY_INFORMATION

#define ISAKMP_NTYPE_INVALID_KEY_INFORMATION   17

Definition at line 302 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_MAJOR_VERSION

#define ISAKMP_NTYPE_INVALID_MAJOR_VERSION   5

Definition at line 290 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_MESSAGE_ID

#define ISAKMP_NTYPE_INVALID_MESSAGE_ID   9

Definition at line 294 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_MINOR_VERSION

#define ISAKMP_NTYPE_INVALID_MINOR_VERSION   6

Definition at line 291 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_PAYLOAD_TYPE

#define ISAKMP_NTYPE_INVALID_PAYLOAD_TYPE   1

Definition at line 286 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_PROTOCOL_ID

#define ISAKMP_NTYPE_INVALID_PROTOCOL_ID   10

Definition at line 295 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_SIGNATURE

#define ISAKMP_NTYPE_INVALID_SIGNATURE   25

Definition at line 310 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_SPI

#define ISAKMP_NTYPE_INVALID_SPI   11

Definition at line 296 of file print-isakmp.c.

◆ ISAKMP_NTYPE_INVALID_TRANSFORM_ID

#define ISAKMP_NTYPE_INVALID_TRANSFORM_ID   12

Definition at line 297 of file print-isakmp.c.

◆ ISAKMP_NTYPE_NO_PROPOSAL_CHOSEN

#define ISAKMP_NTYPE_NO_PROPOSAL_CHOSEN   14

Definition at line 299 of file print-isakmp.c.

◆ ISAKMP_NTYPE_PAYLOAD_MALFORMED

#define ISAKMP_NTYPE_PAYLOAD_MALFORMED   16

Definition at line 301 of file print-isakmp.c.

◆ ISAKMP_NTYPE_SITUATION_NOT_SUPPORTED

#define ISAKMP_NTYPE_SITUATION_NOT_SUPPORTED   3

Definition at line 288 of file print-isakmp.c.

◆ ISAKMP_VERS_MAJOR

#define ISAKMP_VERS_MAJOR   0xf0

Definition at line 86 of file print-isakmp.c.

◆ ISAKMP_VERS_MAJOR_SHIFT

#define ISAKMP_VERS_MAJOR_SHIFT   4

Definition at line 87 of file print-isakmp.c.

◆ ISAKMP_VERS_MINOR

#define ISAKMP_VERS_MINOR   0x0f

Definition at line 88 of file print-isakmp.c.

◆ ISAKMP_VERS_MINOR_SHIFT

#define ISAKMP_VERS_MINOR_SHIFT   0

Definition at line 89 of file print-isakmp.c.

◆ MAXINITIATORS

#define MAXINITIATORS   20

Definition at line 637 of file print-isakmp.c.

◆ NOTIFY_ERROR_STR

#define NOTIFY_ERROR_STR (   x)     STR_OR_ID((x), notify_error_str)

◆ NOTIFY_STATUS_STR

#define NOTIFY_STATUS_STR (   x)     STR_OR_ID((u_int)((x) - 16384), notify_status_str)

◆ NPFUNC

#define NPFUNC (   x)
Value:
(((x) < sizeof(npfunc)/sizeof(npfunc[0]) && npfunc[(x)]) \
? npfunc[(x)] : NULL)
static const u_char *(* npfunc[])(netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth)
Definition: print-isakmp.c:671

Definition at line 739 of file print-isakmp.c.

◆ NPSTR

#define NPSTR (   x)    STR_OR_ID(x, npstr)

Definition at line 729 of file print-isakmp.c.

◆ PORT_ISAKMP

#define PORT_ISAKMP   500

Definition at line 63 of file print-isakmp.c.

◆ PROTOIDSTR

#define PROTOIDSTR (   x)    STR_OR_ID(x, protoidstr)

Definition at line 728 of file print-isakmp.c.

◆ STR_OR_ID

#define STR_OR_ID (   x,
  tab 
)     (((x) < sizeof(tab)/sizeof(tab[0]) && tab[(x)]) ? tab[(x)] : numstr(x))

Definition at line 726 of file print-isakmp.c.

◆ USE_IPSECDOI_IN_PHASE1

#define USE_IPSECDOI_IN_PHASE1   1

Typedef Documentation

◆ cookie_t

typedef nd_byte cookie_t[8]

Definition at line 60 of file print-isakmp.c.

◆ msgid_t

typedef nd_byte msgid_t[4]

Definition at line 61 of file print-isakmp.c.

Enumeration Type Documentation

◆ ikev2_auth_type

Enumerator
IV2_RSA_SIG 
IV2_SHARED 
IV2_DSS_SIG 

Definition at line 429 of file print-isakmp.c.

◆ ikev2_id_type

Enumerator
ID_IPV4_ADDR 
ID_FQDN 
ID_RFC822_ADDR 
ID_IPV6_ADDR 
ID_DER_ASN1_DN 
ID_DER_ASN1_GN 
ID_KEY_ID 

Definition at line 361 of file print-isakmp.c.

◆ ikev2_n_type

Enumerator
IV2_NOTIFY_UNSUPPORTED_CRITICAL_PAYLOAD 
IV2_NOTIFY_INVALID_IKE_SPI 
IV2_NOTIFY_INVALID_MAJOR_VERSION 
IV2_NOTIFY_INVALID_SYNTAX 
IV2_NOTIFY_INVALID_MESSAGE_ID 
IV2_NOTIFY_INVALID_SPI 
IV2_NOTIFY_NO_PROPOSAL_CHOSEN 
IV2_NOTIFY_INVALID_KE_PAYLOAD 
IV2_NOTIFY_AUTHENTICATION_FAILED 
IV2_NOTIFY_SINGLE_PAIR_REQUIRED 
IV2_NOTIFY_NO_ADDITIONAL_SAS 
IV2_NOTIFY_INTERNAL_ADDRESS_FAILURE 
IV2_NOTIFY_FAILED_CP_REQUIRED 
IV2_NOTIFY_INVALID_SELECTORS 
IV2_NOTIFY_INITIAL_CONTACT 
IV2_NOTIFY_SET_WINDOW_SIZE 
IV2_NOTIFY_ADDITIONAL_TS_POSSIBLE 
IV2_NOTIFY_IPCOMP_SUPPORTED 
IV2_NOTIFY_NAT_DETECTION_SOURCE_IP 
IV2_NOTIFY_NAT_DETECTION_DESTINATION_IP 
IV2_NOTIFY_COOKIE 
IV2_NOTIFY_USE_TRANSPORT_MODE 
IV2_NOTIFY_HTTP_CERT_LOOKUP_SUPPORTED 
IV2_NOTIFY_REKEY_SA 
IV2_NOTIFY_ESP_TFC_PADDING_NOT_SUPPORTED 
IV2_NOTIFY_NON_FIRST_FRAGMENTS_ALSO 

Definition at line 387 of file print-isakmp.c.

◆ ikev2_t_type

Enumerator
IV2_T_ENCR 
IV2_T_PRF 
IV2_T_INTEG 
IV2_T_DH 
IV2_T_ESN 

Definition at line 343 of file print-isakmp.c.

Function Documentation

◆ cookie_find()

static int cookie_find ( const cookie_t in)
static

Definition at line 757 of file print-isakmp.c.

References cookiecache, initiator, and MAXINITIATORS.

Referenced by cookie_record(), and ikev1_print().

◆ cookie_record()

static void cookie_record ( netdissect_options ndo,
const cookie_t in,
const u_char *  bp2 
)
static

◆ cookie_sidecheck()

static int cookie_sidecheck ( netdissect_options ndo,
int  i,
const u_char *  bp2,
int  initiator 
)
static

Definition at line 810 of file print-isakmp.c.

References cookiecache, initiator, ip6_hdr::ip6_src, ip::ip_src, IP_V, UNALIGNED_MEMCMP, and version.

◆ hexprint()

static void hexprint ( netdissect_options ndo,
const uint8_t *  loc,
size_t  len 
)
static

Definition at line 848 of file print-isakmp.c.

References ND_PRINT.

Referenced by isakmp_print(), and rawprint().

◆ ike_show_somedata()

static int ike_show_somedata ( netdissect_options ndo,
const u_char *  cp,
const u_char *  ep 
)
static

◆ ike_sub0_print()

static const u_char * ike_sub0_print ( netdissect_options ndo,
u_char  np,
const struct isakmp_gen ext,
const u_char *  ep,
uint32_t  phase,
uint32_t  doi,
uint32_t  proto,
int  depth 
)
static

◆ ikev1_attr_print()

static const u_char* ikev1_attr_print ( netdissect_options ndo,
const u_char *  p,
const u_char *  ep2 
)
static

Definition at line 959 of file print-isakmp.c.

References GET_BE_U_2, GET_U_1, ND_PRINT, and rawprint().

Referenced by ikev1_t_print(), and ikev2_t_print().

◆ ikev1_attrmap_print()

static const u_char* ikev1_attrmap_print ( netdissect_options ndo,
const u_char *  p,
const u_char *  ep2,
const struct attrmap map,
size_t  nmap 
)
static

Definition at line 910 of file print-isakmp.c.

References GET_BE_U_2, GET_U_1, ND_PRINT, and rawprint().

Referenced by ikev1_n_print(), ikev1_t_print(), and ikev2_t_print().

◆ ikev1_cert_print()

static const u_char * ikev1_cert_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_cr_print()

static const u_char * ikev1_cr_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_d_print()

static const u_char * ikev1_d_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_hash_print()

static const u_char * ikev1_hash_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_id_print()

◆ ikev1_ke_print()

static const u_char * ikev1_ke_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_n_print()

static const u_char * ikev1_n_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_nonce_print()

static const u_char * ikev1_nonce_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_p_print()

static const u_char * ikev1_p_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_print()

◆ ikev1_sa_print()

static const u_char * ikev1_sa_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_sig_print()

static const u_char * ikev1_sig_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_sub_print()

static const u_char * ikev1_sub_print ( netdissect_options ndo,
u_char  np,
const struct isakmp_gen ext,
const u_char *  ep,
uint32_t  phase,
uint32_t  doi,
uint32_t  proto,
int  depth 
)
static

◆ ikev1_t_print()

static const u_char * ikev1_t_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev1_vid_print()

static const u_char * ikev1_vid_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_auth_print()

static const u_char * ikev2_auth_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_cert_print()

static const u_char * ikev2_cert_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2283 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_cp_print()

static const u_char * ikev2_cp_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2715 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_cr_print()

static const u_char * ikev2_cr_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2293 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_d_print()

static const u_char * ikev2_d_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2576 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_e_print()

static const u_char * ikev2_e_print ( netdissect_options ndo,
const struct isakmp base,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_eap_print()

static const u_char * ikev2_eap_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2725 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_gen_print()

static const u_char* ikev2_gen_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len 
)
static

◆ ikev2_ID_print()

static const u_char * ikev2_ID_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_ke_print()

static const u_char * ikev2_ke_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_n_print()

◆ ikev2_nonce_print()

static const u_char * ikev2_nonce_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_p_print()

static const u_char* ikev2_p_print ( netdissect_options ndo,
u_char  tpay,
int  pcount,
const struct isakmp_gen ext,
u_int  oprop_length,
const u_char *  ep,
int  depth 
)
static

◆ ikev2_pay_print()

static void ikev2_pay_print ( netdissect_options ndo,
const char *  payname,
uint8_t  critical 
)
static

◆ ikev2_print()

static void ikev2_print ( netdissect_options ndo,
const u_char *  bp,
u_int  length,
const u_char *  bp2,
const struct isakmp base 
)
static

◆ ikev2_sa_print()

static const u_char * ikev2_sa_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ ikev2_sub0_print()

static const u_char* ikev2_sub0_print ( netdissect_options ndo,
const struct isakmp base,
u_char  np,
const struct isakmp_gen ext,
const u_char *  ep,
uint32_t  phase,
uint32_t  doi,
uint32_t  proto,
int  depth 
)
static

◆ ikev2_sub_print()

static const u_char * ikev2_sub_print ( netdissect_options ndo,
const struct isakmp base,
u_char  np,
const struct isakmp_gen ext,
const u_char *  ep,
uint32_t  phase,
uint32_t  doi,
uint32_t  proto,
int  depth 
)
static

◆ ikev2_t_print()

static const u_char* ikev2_t_print ( netdissect_options ndo,
int  tcount,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  ep 
)
static

◆ ikev2_TS_print()

static const u_char * ikev2_TS_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 2624 of file print-isakmp.c.

References ikev2_gen_print().

◆ ikev2_vid_print()

static const u_char * ikev2_vid_print ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

◆ isakmp_print()

◆ isakmp_rfc3948_print()

void isakmp_rfc3948_print ( netdissect_options ndo,
const u_char *  bp,
u_int  length,
const u_char *  bp2,
int  ver,
int  fragmented,
u_int  ttl_hl 
)

◆ iszero()

static int iszero ( const u_char *  p,
size_t  l 
)
static

Definition at line 744 of file print-isakmp.c.

Referenced by ikev1_print().

◆ numstr()

static char * numstr ( u_int  x)
static

Definition at line 2814 of file print-isakmp.c.

References snprintf().

Referenced by ikev1_n_print().

◆ rawprint()

Variable Documentation

◆ ah_p_map

const char* ah_p_map[]
static
Initial value:
= {
NULL, "(reserved)", "md5", "sha", "1des",
"sha2-256", "sha2-384", "sha2-512",
}

Definition at line 1099 of file print-isakmp.c.

Referenced by ikev1_t_print().

◆ 

cookiecache[ 20 ] { ... } struct

◆ dh_p_map

const char* dh_p_map[]
static
Initial value:
= {
NULL, "modp768",
"modp1024",
"EC2N 2^155",
"EC2N 2^185",
"modp1536",
"iana-grp06", "iana-grp07",
"iana-grp08", "iana-grp09",
"iana-grp10", "iana-grp11",
"iana-grp12", "iana-grp13",
"modp2048",
"modp3072",
"modp4096",
"modp6144",
"modp8192",
}

Definition at line 1118 of file print-isakmp.c.

Referenced by ikev2_ke_print(), and ikev2_t_print().

◆ encr_t_map

const struct attrmap encr_t_map[]
static
Initial value:
= {
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ NULL, 0, { NULL } }, { NULL, 0, { NULL } },
{ "keylen", 14, { NULL }},
}

Definition at line 1140 of file print-isakmp.c.

Referenced by ikev2_t_print().

◆ esn_p_map

const char* esn_p_map[]
static
Initial value:
= {
"no-esn", "esn"
}

Definition at line 1114 of file print-isakmp.c.

Referenced by ikev2_t_print().

◆ esp_p_map

const char* esp_p_map[]
static
Initial value:
= {
NULL, "1des-iv64", "1des", "3des", "rc5", "idea", "cast",
"blowfish", "3idea", "1des-iv32", "rc4", "null", "aes"
}

Definition at line 1135 of file print-isakmp.c.

Referenced by ikev1_t_print(), and ikev2_t_print().

◆ etypestr

const char* etypestr[]
static
Initial value:
= {
"none", "base", "ident", "auth", "agg", "inf", NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
"oakley-quick", "oakley-newgroup",
"ikev2_init", "ikev2_auth", "child_sa", "inf2"
}

Definition at line 715 of file print-isakmp.c.

◆ iaddr

union inaddr_u iaddr

Definition at line 645 of file print-isakmp.c.

Referenced by cookie_record().

◆ ikev1_p_map

const char* ikev1_p_map[]
static
Initial value:
= {
NULL, "ike",
}

Definition at line 1091 of file print-isakmp.c.

Referenced by ikev1_t_print().

◆ ikev2_t_type_map

const char* ikev2_t_type_map[]
static
Initial value:
={
NULL, "encr", "prf", "integ", "dh", "esn"
}

Definition at line 1095 of file print-isakmp.c.

Referenced by ikev2_t_print().

◆ initiator

cookie_t initiator

Definition at line 644 of file print-isakmp.c.

Referenced by cookie_find(), cookie_record(), and cookie_sidecheck().

◆ integ_p_map

const char* integ_p_map[]
static
Initial value:
= {
NULL, "hmac-md5", "hmac-sha", "dec-mac",
"kpdk-md5", "aes-xcbc"
}

Definition at line 1109 of file print-isakmp.c.

Referenced by ikev2_t_print().

◆ ipcomp_p_map

const char* ipcomp_p_map[]
static
Initial value:
= {
NULL, "oui", "deflate", "lzs",
}

Definition at line 1140 of file print-isakmp.c.

Referenced by ikev1_t_print().

◆ ipsec_t_map

const struct attrmap ipsec_t_map[]
static
Initial value:
= {
{ NULL, 0, { NULL } },
{ "lifetype", 3, { NULL, "sec", "kb", }, },
{ "life", 0, { NULL } },
{ "group desc", 18, { NULL, "modp768",
"modp1024",
"EC2N 2^155",
"EC2N 2^185",
"modp1536",
"iana-grp06", "iana-grp07",
"iana-grp08", "iana-grp09",
"iana-grp10", "iana-grp11",
"iana-grp12", "iana-grp13",
"modp2048",
"modp3072",
"modp4096",
"modp6144",
"modp8192",
}, },
{ "enc mode", 3, { NULL, "tunnel", "transport", }, },
{ "auth", 5, { NULL, "hmac-md5", "hmac-sha1", "1des-mac", "keyed", }, },
{ "keylen", 0, { NULL } },
{ "rounds", 0, { NULL } },
{ "dictsize", 0, { NULL } },
{ "privalg", 0, { NULL } },
}

Definition at line 1140 of file print-isakmp.c.

Referenced by ikev1_t_print().

◆ ninitiator

int ninitiator = 0
static

Definition at line 638 of file print-isakmp.c.

Referenced by cookie_record().

◆ npfunc

const u_char*(* npfunc[])(netdissect_options *ndo, u_char tpay, const struct isakmp_gen *ext, u_int item_len, const u_char *end_pointer, uint32_t phase, uint32_t doi0, uint32_t proto0, int depth) ( netdissect_options ndo,
u_char  tpay,
const struct isakmp_gen ext,
u_int  item_len,
const u_char *  end_pointer,
uint32_t  phase,
uint32_t  doi0,
uint32_t  proto0,
int  depth 
)
static

Definition at line 671 of file print-isakmp.c.

Referenced by ike_sub0_print(), and ikev2_sub0_print().

◆ npstr

const char* npstr[]
static
Initial value:
= {
"none", "sa", "p", "t", "ke", "id", "cert", "cr", "hash",
"sig", "nonce", "n", "d", "vid",
"pay14", "pay15", "pay16", "pay17", "pay18",
"pay19", "pay20", "pay21", "pay22", "pay23",
"pay24", "pay25", "pay26", "pay27", "pay28",
"pay29", "pay30", "pay31", "pay32",
"v2sa", "v2ke", "v2IDi", "v2IDr", "v2cert",
"v2cr", "v2auth","v2nonce", "v2n", "v2d",
"v2vid", "v2TSi", "v2TSr", "v2e", "v2cp",
"v2eap",
}

Definition at line 656 of file print-isakmp.c.

◆ oakley_t_map

const struct attrmap oakley_t_map[]
static

Definition at line 1140 of file print-isakmp.c.

Referenced by ikev1_n_print(), and ikev1_t_print().

◆ prf_p_map

const char* prf_p_map[]
static
Initial value:
= {
NULL, "hmac-md5", "hmac-sha", "hmac-tiger",
"aes128_xcbc"
}

Definition at line 1104 of file print-isakmp.c.

Referenced by ikev2_t_print().

◆ protoidstr

const char* protoidstr[]
static
Initial value:
= {
NULL, "isakmp", "ipsec-ah", "ipsec-esp", "ipcomp",
}

Definition at line 651 of file print-isakmp.c.

◆ raddr

union inaddr_u raddr

Definition at line 645 of file print-isakmp.c.

Referenced by cookie_record().

◆ version