diff options
-rw-r--r-- | README | 4 | ||||
-rw-r--r-- | src/vmod_remoteip.vcc | 2 |
2 files changed, 3 insertions, 3 deletions
@@ -31,8 +31,8 @@ An example of using this module: } sub vcl_recv { - set resp.http.x-real-ip = remoteip.get(resp.http.X-Forwarded-For); - if (std.ip(resp.http.x-real-ip) ~ allowed) { + set req.http.x-real-ip = remoteip.get(req.http.X-Forwarded-For); + if (std.ip(req.http.x-real-ip) ~ allowed) { ... } } diff --git a/src/vmod_remoteip.vcc b/src/vmod_remoteip.vcc index b46aef5..55b161e 100644 --- a/src/vmod_remoteip.vcc +++ b/src/vmod_remoteip.vcc @@ -48,7 +48,7 @@ EXAMPLE } sub vcl_recv { - set resp.http.x-real-ip = remoteip.get(resp.http.X-Forwarded-For); + set req.http.x-real-ip = remoteip.get(req.http.X-Forwarded-For); ... } |