OpenHIP 0.9svn1
Classes | Defines | Functions | Variables
/home/tomh/svn/openhip/hip/trunk/src/include/hip/hip_usermode.h File Reference
#include <sys/socket.h>

Go to the source code of this file.

Classes

struct  ip_esp_hdr
struct  ip_esp_padinfo
struct  eth_hdr
struct  arp_hdr
struct  arp_req_data

Defines

#define RETNULL   NULL;
#define CONFIG_HIP
#define HIP_TAP_INTERFACE_MTU   1400
#define DNS_PORT   53
#define HIP_DNS_SUFFIX   ".hip"
#define IS_LSI32(a)   ((a & htonl(0xFF000000)) == htonl(0x01000000))
#define NIPQUAD(addr)
#define NIP6(addr)
#define TRUE   1
#define FALSE   0
#define ARPOP_REQUEST   1
#define ARPOP_REPLY   2

Functions

void * hip_esp_output (void *arg)
void * hip_esp_input (void *arg)
void * tunreader (void *arg)
void * hip_dns (void *arg)
void * hipd_main (void *arg)
void * hip_netlink (void *arg)
void * hip_status (void *arg)
void * hip_mobile_router (void *arg)
int init_esp_input (int family, int type, int proto, int port, char *msg)
int main_loop (int argc, char **argv)
int str_to_addr (unsigned char *data, struct sockaddr *addr)
struct eth_hdr __attribute__ ((packed))

Variables

__u64 g_tap_mac
int g_state
__u8 dst [6]
__u8 src [6]
__u16 type
__u16 ar_hrd
__u16 ar_pro
__u8 ar_hln
__u8 ar_pln
__u16 ar_op
__u8 src_mac [6]
__u32 src_ip
__u8 dst_mac [6]
__u32 dst_ip

Define Documentation

#define ARPOP_REPLY   2

Referenced by handle_arp().

#define ARPOP_REQUEST   1

Referenced by handle_arp().

#define CONFIG_HIP
#define DNS_PORT   53
#define FALSE   0
#define HIP_DNS_SUFFIX   ".hip"
#define HIP_TAP_INTERFACE_MTU   1400

Referenced by post_init_tap().

#define IS_LSI32 (   a)    ((a & htonl(0xFF000000)) == htonl(0x01000000))
#define NIP6 (   addr)
Value:
ntohs((addr).s6_addr16[0]), \
  ntohs((addr).s6_addr16[1]), \
  ntohs((addr).s6_addr16[2]), \
  ntohs((addr).s6_addr16[3]), \
  ntohs((addr).s6_addr16[4]), \
  ntohs((addr).s6_addr16[5]), \
  ntohs((addr).s6_addr16[6]), \
  ntohs((addr).s6_addr16[7])
#define NIPQUAD (   addr)
Value:
((unsigned char *)&addr)[0], \
  ((unsigned char *)&addr)[1], \
  ((unsigned char *)&addr)[2], \
  ((unsigned char *)&addr)[3]
#define RETNULL   NULL;
#define TRUE   1

Function Documentation

struct eth_hdr __attribute__ ( (packed)  )
void* hip_dns ( void *  arg)
void* hip_esp_input ( void *  arg)
void* hip_esp_output ( void *  arg)
void * hip_mobile_router ( void *  arg)
void* hip_netlink ( void *  arg)
void* hip_status ( void *  arg)
void* hipd_main ( void *  arg)

References g_state, and main_loop().

int init_esp_input ( int  family,
int  type,
int  proto,
int  port,
char *  msg 
)

Referenced by init_hip().

int main_loop ( int  argc,
char **  argv 
)

References hip_opt::allow_any, append_hi_node(), hip_conf::conf_filename, hip_conf::cookie_difficulty, hip_conf::cookie_lifetime, D_DEFAULT, D_QUIET, D_VERBOSE, hip_opt::daemon, hip_opt::debug, hip_opt::debug_R1, DEFAULT_DH_GROUP_ID, hip_conf::dh_group, hip_conf::dh_lifetime, hip_conf::disable_dns_lookups, hip_conf::disable_dns_thread, hip_conf::disable_notify, hip_conf::disable_udp, hip_conf::enable_bcast, endbox_init(), ERR, hip_conf::esp_transforms, espsp, expire_old_dh_entries(), hip_conf::failure_timeout, FALSE, fflush_log(), flags, g_state, get_my_addresses(), get_preferred_hi(), H_PROTO_HIP, HCNF, hip_assoc_table, HIP_CONF_FILENAME, hip_dht_update_my_entries(), hip_exit(), hip_handle_esp(), hip_handle_multihoming_timeouts(), hip_handle_netlink(), hip_handle_packet(), hip_handle_registrations(), hip_handle_state_timeouts(), hip_handle_status_request(), HIP_KNOWNID_FILENAME, HIP_LOCK_FILENAME, hip_mr_set_external_ifs(), HIP_MYID_FILENAME, hip_netlink_open(), hip_retransmit_waiting_packets(), hip_status_open(), hip_conf::hip_transforms, hip_trigger(), HIP_VERSION, hip_writelock(), hipcfg_getMyHostId(), hipcfg_init(), init_all_R1_caches(), init_dh_cache(), init_log(), hip_conf::known_hi_filename, length, hip_conf::loc_lifetime, locate_config_file(), log_(), hip_conf::log_filename, log_hipopts(), hip_conf::max_reg_lifetime, MAX_REGISTRATION_TYPES, hip_conf::max_retries, maxof(), hip_opt::mh, hip_conf::min_reg_lifetime, hip_opt::mr, hip_conf::msl, hip_conf::my_hi_filename, my_hi_head, hip_opt::no_retransmit, NORM, NORMT, hip_conf::num_reg_types, hip_opt::opportunistic, OPT, hip_conf::outbound_ifaces, hip_conf::packet_timeout, hip_conf::peer_certificate_required, peer_hi_head, hip_opt::permissive, post_init_tap(), hip_conf::preferred_hi, hip_conf::preferred_iface, print_usage(), QOUT, hip_conf::r1_lifetime, read_conf_file(), read_identities_file(), hip_conf::reg_types, REGTYPE_MR, REGTYPE_RVS, replace_next_R1(), hip_opt::rvs, s6_hip, s_hip, s_net, s_stat, SA, hip_conf::sa_lifetime, hip_conf::save_known_identities, hip_conf::save_my_identities, select_preferred_address(), hip_conf::send_hi_name, src, str_to_addr(), SUITE_ID_MAX, hip_opt::trigger, TRUE, hip_conf::ual, and WARN.

Referenced by hipd_main().

int str_to_addr ( unsigned char *  data,
struct sockaddr *  addr 
)
void* tunreader ( void *  arg)

Variable Documentation

__u8 dst[6]
int g_state
__u8 src[6]