Commit 22606ce7 authored by Graham Leggett's avatar Graham Leggett
Browse files

Add the ability to access the connection level remote IP address from the

expression parser.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1204990 13f79535-47bb-0310-9956-ffa450edef68
parent eb1bb1c1
Loading
Loading
Loading
Loading
+3 −0
Changes for server/util_expr_eval.c: 3 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -1184,6 +1184,7 @@ static const char *conn_var_names[] = {
    "HTTPS",                    /*  0 */
    "IPV6",                     /*  1 */
    "CONN_LOG_ID",              /*  2 */
    "CONN_REMOTE_ADDR",         /*  3 */
    NULL
};

@@ -1215,6 +1216,8 @@ static const char *conn_var_fn(ap_expr_eval_ctx_t *ctx, const void *data)
#endif
    case 2:
        return c->log_id;
    case 3:
        return c->remote_ip;
    default:
        ap_assert(0);
        return NULL;