[Mod-auth-commit] mod_authn_dbi/src mod_authn_dbi.c,1.7,1.8
Brought to you by:
firechipmunk,
honx
From: <ho...@us...> - 2004-01-01 16:29:53
|
Update of /cvsroot/mod-auth/mod_authn_dbi/src In directory sc8-pr-cvs1:/tmp/cvs-serv25713 Modified Files: mod_authn_dbi.c Log Message: 3 new variables: LocalIP, RemoteIP and RemoteHost. semantics of RemoteHost may (and probably will) change soon. Index: mod_authn_dbi.c =================================================================== RCS file: /cvsroot/mod-auth/mod_authn_dbi/src/mod_authn_dbi.c,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mod_authn_dbi.c 3 Nov 2003 16:03:25 -0000 1.7 --- mod_authn_dbi.c 1 Jan 2004 16:29:49 -0000 1.8 *************** *** 441,444 **** --- 441,455 ---- e = (ap_auth_name(r) ? ap_auth_name(r) : EMPTY_VAR); } + else if (!strcasecmp(var, "RemoteIP")) { + e = (r->connection->remote_ip ? r->connection->remote_ip : EMPTY_VAR); + } + /* umm... *coughuglycough*... */ + else if (!strcasecmp(var, "RemoteHost")) { + e = (ap_get_remote_host(r->connection, r->per_dir_config, REMOTE_NOLOOKUP, NULL) ? + ap_get_remote_host(r->connection, r->per_dir_config, REMOTE_NOLOOKUP, NULL) : EMPTY_VAR); + } + else if (!strcasecmp(var, "LocalIP")) { + e = (r->connection->local_ip ? r->connection->local_ip : EMPTY_VAR); + } else if (!strcasecmp(var, "ConfigHostname")) { e = (r->server->server_hostname ? r->server-> |