#include <string.h>#include "../../ut.h"#include "../../str.h"#include "../../db/db.h"#include "../../dprint.h"#include "../../parser/digest/digest.h"#include "../../parser/hf.h"#include "../../parser/parser_f.h"#include "../../usr_avp.h"#include "../../mod_fix.h"#include "../../mem/mem.h"#include "aaa_avps.h"#include "authdb_mod.h"

Go to the source code of this file.
Functions | |
| static int | authorize (struct sip_msg *_m, gparam_p _realm, char *_table, hdr_types_t _hftype) |
| static int | generate_avps (db_res_t *result) |
| static int | get_ha1 (struct username *_username, str *_domain, const str *_table, char *_ha1, db_res_t **res) |
| int | proxy_authorize (struct sip_msg *_m, char *_realm, char *_table) |
| int | www_authorize (struct sip_msg *_m, char *_realm, char *_table) |
Variables | |
| static str | auth_500_err = str_init("Server Internal Error") |
| static int authorize | ( | struct sip_msg * | _m, | |
| gparam_p | _realm, | |||
| char * | _table, | |||
| hdr_types_t | _hftype | |||
| ) | [inline, static] |
Definition at line 209 of file auth_db/authorize.c.
References auth_db_handle, auth_dbf, AUTH_ERROR, AUTHORIZED, auth_body::digest, DO_AUTHORIZATION, domain, ERROR, sip_msg::first_line, fixup_get_svalue(), db_func::free_result, generate_avps(), get_ha1(), INVALID_PASSWORD, _str::len, LM_ERR, NULL, hdr_field::parsed, msg_start::request, _str::s, sl_binds::send_reply, slb, table, msg_start::u, USER_UNKNOWN, and dig_cred::username.
Referenced by diameter_proxy_authorize(), diameter_www_authorize(), proxy_authorize(), radius_proxy_authorize_1(), radius_proxy_authorize_2(), radius_www_authorize(), and www_authorize().
| static int generate_avps | ( | db_res_t * | result | ) | [static] |
Definition at line 136 of file auth_db/authorize.c.
References add_avp(), aaa_avp::avp_name, AVP_NAME_STR, aaa_avp::avp_type, AVP_VAL_STR, db_res::col, credentials, DB_INT, DB_STR, DB_STRING, _str::len, LM_DBG, LM_ERR, int_str::n, db_res::names, aaa_avp::next, NULL, db_res::rows, _str::s, int_str::s, db_res::types, VAL_INT, VAL_NULL, VAL_STR, VAL_STRING, db_row::values, and ZSW.
Referenced by authorize(), radius_authorize_sterman(), radius_does_uri_user_exist(), radius_does_uri_user_host_exist(), radius_is_user_in(), radius_load_callee_avps(), radius_load_caller_avps(), and verify_destination().
| static int get_ha1 | ( | struct username * | _username, | |
| str * | _domain, | |||
| const str * | _table, | |||
| char * | _ha1, | |||
| db_res_t ** | res | |||
| ) | [inline, static] |
Definition at line 54 of file auth_db/authorize.c.
References auth_db_handle, auth_dbf, calc_ha1, credentials, credentials_n, DB_STR, username::domain, domain_column, HA_MD5, _str::len, LM_DBG, LM_ERR, nc, aaa_avp::next, NULL, pass_column, pass_column_2, pkg_free, pkg_malloc, db_func::query, RES_ROW_N, RES_ROWS, ROW_VALUES, _str::s, use_domain, db_func::use_table, username::user, user_column, VAL_NULL, VAL_STR, VAL_TYPE, vals, username::whole, and ZSW.
Referenced by authorize().
| int proxy_authorize | ( | struct sip_msg * | _m, | |
| char * | _realm, | |||
| char * | _table | |||
| ) |
| int www_authorize | ( | struct sip_msg * | _m, | |
| char * | _realm, | |||
| char * | _table | |||
| ) |
Definition at line 285 of file auth_db/authorize.c.
References authorize(), and HDR_AUTHORIZATION_T.
str auth_500_err = str_init("Server Internal Error") [static] |
Definition at line 51 of file auth_db/authorize.c.
1.5.6