re_group.h

Go to the documentation of this file.
00001 /*
00002  * $Id: re_group.h 5210 2008-11-17 19:52:43Z henningw $ 
00003  *
00004  * Copyright (C) 2005-2007 Voice Sistem SRL
00005  *
00006  * This file is part of Kamailio, a free SIP server.
00007  *
00008  * Kamailio is free software; you can redistribute it and/or modify
00009  * it under the terms of the GNU General Public License as published by
00010  * the Free Software Foundation; either version 2 of the License, or
00011  * (at your option) any later version
00012  *
00013  * Kamailio is distributed in the hope that it will be useful,
00014  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00016  * GNU General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU General Public License 
00019  * along with this program; if not, write to the Free Software 
00020  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00021  *
00022  * History:
00023  * --------
00024  *  2005-10-06 - created by bogdan
00025  */
00026 
00027 /**
00028  * \file
00029  * \brief Group membership module
00030  * \ingroup group
00031  * - Module: \ref group
00032  */
00033 
00034 #ifndef RE_GROUP_H
00035 #define RE_GROUP_H
00036 
00037 #include "../../str.h"
00038 #include "../../parser/msg_parser.h"
00039 
00040 
00041 /*!
00042  * \brief Load regular expression rules from a database
00043  * \param table DB table
00044  * \return 0 on success, -1 on failure
00045  */
00046 int load_re(str *table);
00047 
00048 
00049 /*!
00050  * \brief Get the user group and compare to the regexp list
00051  * \param req SIP message
00052  * \param user user string
00053  * \param avp AVP value
00054  * \return number of all matches (positive), -1 on errors or when not found
00055  */
00056 int get_user_group(struct sip_msg *req, char *user, char *avp);
00057 
00058 #endif

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