modules_k/registrar/reg_mod.h
31ccf6a2
 /* 
  * $Id$ 
  *
  * registrar module interface
  *
  * Copyright (C) 2001-2003 FhG Fokus
  *
27642a08
  * This file is part of Kamailio, a free SIP server.
31ccf6a2
  *
27642a08
  * Kamailio is free software; you can redistribute it and/or modify
31ccf6a2
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version
  *
27642a08
  * Kamailio is distributed in the hope that it will be useful,
31ccf6a2
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License 
  * along with this program; if not, write to the Free Software 
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
30368e16
  *
  * History:
  * --------
  *
  * 2005-07-11  added sip_natping_flag for nat pinging with SIP method
  *             instead of UDP package (bogdan)
f56ae82e
  * 2006-11-28  Added statistics tracking for the number of accepted/rejected
  *             registrations, as well as for the max expiry time, max contacts,
  *             and default expiry time. (Jeffrey Magder - SOMA Networks)
e47f4b50
  * 2007-02-24  sip_natping_flag moved into branch flags, so migrated to 
  *             nathelper module (bogdan)
31ccf6a2
  */
 
d847357a
 /*!
  * \file
  * \brief SIP registrar module - interface
  * \ingroup registrar   
  */  
 
31ccf6a2
 
 #ifndef REG_MOD_H
 #define REG_MOD_H
 
 #include "../../parser/msg_parser.h"
 #include "../../qvalue.h"
 #include "../../usr_avp.h"
 #include "../usrloc/usrloc.h"
1a9a0d9b
 #include "../../modules/sl/sl.h"
31ccf6a2
 
f485b55c
 /* if DB support is used, this values must not exceed the 
fb3bee93
  * storage capacity of the DB columns! See db/schema/entities.xml */
f485b55c
 #define CONTACT_MAX_SIZE       255
 #define RECEIVED_MAX_SIZE      255
 #define USERNAME_MAX_SIZE      64
 #define DOMAIN_MAX_SIZE        128
 #define CALLID_MAX_SIZE        255
 #define UA_MAX_SIZE            255
 
79bf803d
 #define PATH_MODE_STRICT	2
 #define PATH_MODE_LAZY		1
 #define PATH_MODE_OFF		0
 
bf3705d3
 #define REG_SAVE_MEM_FL     (1<<0)
 #define REG_SAVE_NORPL_FL   (1<<1)
e4dbad77
 #define REG_SAVE_REPL_FL    (1<<2)
 #define REG_SAVE_ALL_FL     ((1<<3)-1)
bf3705d3
 
31ccf6a2
 extern int nat_flag;
8f55b4c0
 extern int tcp_persistent_flag;
31ccf6a2
 extern int received_avp;
32f46645
 extern int reg_use_domain;
31ccf6a2
 extern float def_q;
 
8d9d76ed
 extern unsigned short aor_avp_type;
 extern int_str aor_avp_name;
 extern unsigned short rcv_avp_type;
 extern int_str rcv_avp_name;
f0ed82ce
 extern unsigned short reg_callid_avp_type;
 extern int_str reg_callid_avp_name;
8d9d76ed
 
31ccf6a2
 extern str rcv_param;
76af1362
 extern int method_filtering;
79bf803d
 extern int path_enabled;
 extern int path_mode;
932053d7
 extern int path_use_params;
31ccf6a2
 
 extern str sock_hdr_name;
 extern int sock_flag;
 
611b511e
 extern usrloc_api_t ul;/*!< Structure containing pointers to usrloc functions*/
31ccf6a2
 
1a9a0d9b
 extern sl_api_t slb;
31ccf6a2
 
f56ae82e
 extern stat_var *accepted_registrations;
 extern stat_var *rejected_registrations;
9e047c21
 extern stat_var *default_expire_stat;
be26e161
 extern stat_var *max_expires_stat;
c2b7096e
 
31ccf6a2
 #endif /* REG_MOD_H */