trusted.c File Reference

#include <sys/types.h>
#include <regex.h>
#include <string.h>
#include "permissions.h"
#include "hash.h"
#include "../../config.h"
#include "../../db/db.h"
#include "../../ip_addr.h"
#include "../../mem/shm_mem.h"
#include "../../parser/msg_parser.h"
#include "../../parser/parse_from.h"
#include "../../usr_avp.h"

Include dependency graph for trusted.c:

Go to the source code of this file.

Defines

#define TABLE_VERSION   4

Functions

int allow_trusted (struct sip_msg *msg, char *src_ip, int proto)
int allow_trusted_0 (struct sip_msg *_msg, char *str1, char *str2)
int allow_trusted_2 (struct sip_msg *_msg, char *_src_ip_sp, char *_proto_sp)
void clean_trusted (void)
int init_child_trusted (int rank)
int init_trusted (void)
static int match_proto (const char *proto_string, int proto_int)
static int match_res (struct sip_msg *msg, int proto, db_res_t *_r)
int mi_init_trusted (void)
int reload_trusted_table (void)

Variables

static db_con_tdb_handle = 0
struct trusted_list *** hash_table
struct trusted_list ** hash_table_1
struct trusted_list ** hash_table_2
static db_func_t perm_dbf


Define Documentation

#define TABLE_VERSION   4

Definition at line 43 of file trusted.c.


Function Documentation

int allow_trusted ( struct sip_msg msg,
char *  src_ip,
int  proto 
)

int allow_trusted_0 ( struct sip_msg _msg,
char *  str1,
char *  str2 
)

int allow_trusted_2 ( struct sip_msg _msg,
char *  _src_ip_sp,
char *  _proto_sp 
)

void clean_trusted ( void   ) 

Definition at line 271 of file trusted.c.

References free_hash_table(), and shm_free.

Referenced by mod_exit().

int init_child_trusted ( int  rank  ) 

int init_trusted ( void   ) 

static int match_proto ( const char *  proto_string,
int  proto_int 
) [inline, static]

Definition at line 283 of file trusted.c.

References LM_ERR, PROTO_SCTP, PROTO_TCP, PROTO_TLS, and PROTO_UDP.

Referenced by match_res().

static int match_res ( struct sip_msg msg,
int  proto,
db_res_t _r 
) [static]

int mi_init_trusted ( void   ) 

Definition at line 256 of file trusted.c.

References db_url, db_func::init, LM_ERR, and _str::s.

Referenced by mi_trusted_child_init().

int reload_trusted_table ( void   ) 


Variable Documentation

db_con_t* db_handle = 0 [static]

Definition at line 50 of file trusted.c.

Definition at line 45 of file trusted.c.

Definition at line 46 of file trusted.c.

Definition at line 47 of file trusted.c.

db_func_t perm_dbf [static]

Definition at line 51 of file trusted.c.


Generated on Thu May 24 20:00:45 2012 for Kamailio - The Open Source SIP Server by  doxygen 1.5.6