Skip to content

Latest commit

 

History

History
13 lines (12 loc) · 584 Bytes

README.md

File metadata and controls

13 lines (12 loc) · 584 Bytes

cf-nginx-realip

Cloudflare/Nginx Restoring original visitor IPs in nginx access logs

Developed by G4L1L3O

<< Instructions >>

  • change the nginxpath in configurations if your path is different.
  • add a cronjob to run this bash script @daily or @weekly /path_to_bash_script/cfips_nginx.sh
  • make sure bash script can be executed by running this: chmod +x cfips-nginx.sh
  • run the script once to create the include files
  • add this line in your nginx.conf file, within the http block "include cfips.txt;"
  • restart nginx
  • you should now have the real ip in your access logs