ipscrub #
Replaces client IP addresses in nginx logs with a salted hash, and the salt changes regularly. Use it to link requests from one visitor without storing the real IP address. That helps with privacy rules such as the GDPR.
Source: upstream source
Directives
ipscrub_period_seconds #
syntax: ipscrub_period_seconds 1 arg (integer); · context: http
Set ipscrub_period_seconds <NUM SECONDS PER PERIOD>; (optional). 1.
Example
# Anonymise client IPs in access logs by rotating the salt every hour.
ipscrub_period_seconds 3600;
log_format scrubbed '$remote_addr_ipscrub - [$time_local] "$request" $status';
access_log /var/log/nginx/access.log scrubbed;