NetSim Source Code Help
Loading...
Searching...
No Matches
OSPF_Msg.c File Reference
#include "main.h"
#include "OSPF.h"
#include "OSPF_Msg.h"
#include "OSPF_Interface.h"
Include dependency graph for OSPF_Msg.c:

Go to the source code of this file.

Data Structures

struct  stru_ospf_msg_database
 

Typedefs

typedef struct stru_ospf_msg_database OSPFMSG_DATABASE
 

Functions

static char * OSPFMSG_TO_STR (OSPFMSG type)
 
ptrOSPFPACKETHDR OSPF_HDR_NEW ()
 
ptrOSPFPACKETHDR OSPF_HDR_COPY (ptrOSPFPACKETHDR hdr)
 
void OSPF_HDR_FREE (ptrOSPFPACKETHDR hdr)
 
void OSPF_HDR_SET_MSG (ptrOSPFPACKETHDR hdr, OSPFMSG type, void *msg, UINT16 len)
 
void OSPF_HDR_INCREASE_LEN (NetSim_PACKET *packet, UINT16 len)
 
static void ospf_packet_update_src (NetSim_PACKET *packet, NETSIM_ID d, NETSIM_ID in)
 
static ptrOSPFPACKETHDR ospf_get_new_hdr (OSPFMSG type)
 
NetSim_PACKETOSPF_PACKET_NEW (double time, OSPFMSG type, NETSIM_ID d, NETSIM_ID in)
 
void OSPF_SEND_PACKET (NetSim_PACKET *packet)
 
static bool validate_areaid (NetSim_PACKET *packet)
 
bool validate_ospf_packet (NetSim_PACKET *packet, NETSIM_ID d, NETSIM_ID in)
 

Variables

static OSPFMSG_DATABASE pstruOSPFMsgCallback []
 

Typedef Documentation

◆ OSPFMSG_DATABASE

Function Documentation

◆ ospf_get_new_hdr()

static ptrOSPFPACKETHDR ospf_get_new_hdr ( OSPFMSG  type)
static

Definition at line 98 of file OSPF_Msg.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ OSPF_HDR_COPY()

ptrOSPFPACKETHDR OSPF_HDR_COPY ( ptrOSPFPACKETHDR  hdr)

Definition at line 48 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_HDR_FREE()

void OSPF_HDR_FREE ( ptrOSPFPACKETHDR  hdr)

Definition at line 59 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_HDR_INCREASE_LEN()

void OSPF_HDR_INCREASE_LEN ( NetSim_PACKET packet,
UINT16  len 
)

Definition at line 80 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_HDR_NEW()

ptrOSPFPACKETHDR OSPF_HDR_NEW ( )

Definition at line 40 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_HDR_SET_MSG()

void OSPF_HDR_SET_MSG ( ptrOSPFPACKETHDR  hdr,
OSPFMSG  type,
void *  msg,
UINT16  len 
)

Definition at line 70 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_PACKET_NEW()

NetSim_PACKET * OSPF_PACKET_NEW ( double  time,
OSPFMSG  type,
NETSIM_ID  d,
NETSIM_ID  in 
)

Definition at line 106 of file OSPF_Msg.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ospf_packet_update_src()

static void ospf_packet_update_src ( NetSim_PACKET packet,
NETSIM_ID  d,
NETSIM_ID  in 
)
static

Definition at line 90 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPF_SEND_PACKET()

void OSPF_SEND_PACKET ( NetSim_PACKET packet)

Definition at line 136 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ OSPFMSG_TO_STR()

static char * OSPFMSG_TO_STR ( OSPFMSG  type)
static

Definition at line 35 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ validate_areaid()

static bool validate_areaid ( NetSim_PACKET packet)
static

Definition at line 160 of file OSPF_Msg.c.

Here is the caller graph for this function:

◆ validate_ospf_packet()

bool validate_ospf_packet ( NetSim_PACKET packet,
NETSIM_ID  d,
NETSIM_ID  in 
)

Definition at line 202 of file OSPF_Msg.c.

Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ pstruOSPFMsgCallback

OSPFMSG_DATABASE pstruOSPFMsgCallback[]
static
Initial value:
= {
{"UNKNOWN"},
}
void OSPF_DD_MSG_NEW(ptrOSPFPACKETHDR hdr)
Definition: OSPF_DD.c:23
ptrOSPFDD OSPF_DD_MSG_COPY(ptrOSPFDD dd)
Definition: OSPF_DD.c:32
void OSPF_DD_MSG_FREE(ptrOSPFDD dd)
Definition: OSPF_DD.c:44
void OSPF_HELLO_MSG_NEW(ptrOSPFPACKETHDR hdr)
Definition: OSPF_Hello.c:24
ptrOSPFHELLO OSPF_HELLO_MSG_COPY(ptrOSPFHELLO hello)
Definition: OSPF_Hello.c:33
void OSPF_HELLO_MSG_FREE(ptrOSPFHELLO hello)
Definition: OSPF_Hello.c:45
void OSPF_LSACK_NEW(ptrOSPFPACKETHDR hdr)
Definition: OSPF_LSAACK.c:45
ptrOSPFLSACK OSPF_LSACK_COPY(ptrOSPFLSACK ack)
Definition: OSPF_LSAACK.c:23
void OSPF_LSACK_FREE(ptrOSPFLSACK ack)
Definition: OSPF_LSAACK.c:37
ptrOSPFLSREQ OSPF_LSREQ_MSG_COPY(ptrOSPFLSREQ lsr)
Definition: OSPF_LSREQ.c:39
void OSPF_LSREQ_MSG_FREE(ptrOSPFLSREQ lsr)
Definition: OSPF_LSREQ.c:54
void OSPF_LSREQ_MSG_NEW(ptrOSPFPACKETHDR hdr)
Definition: OSPF_LSREQ.c:30
ptrOSPFLSUPDATE OSPF_LSUPDATE_MSG_COPY(ptrOSPFLSUPDATE lsu)
Definition: OSPF_LSUPDATE.c:32
void OSPF_LSUPDATE_MSG_NEW(ptrOSPFPACKETHDR hdr)
Definition: OSPF_LSUPDATE.c:23
void OSPF_LSUPDATE_MSG_FREE(ptrOSPFLSUPDATE lsu)
Definition: OSPF_LSUPDATE.c:44

Definition at line 26 of file OSPF_Msg.c.