trustedproxy.php 929 B

123456789101112131415161718192021222324252627
  1. <?php
  2. return [
  3. /*
  4. * Set trusted proxy IP addresses.
  5. *
  6. * Both IPv4 and IPv6 addresses are
  7. * supported, along with CIDR notation.
  8. *
  9. * The "*" character is syntactic sugar
  10. * within TrustedProxy to trust any proxy
  11. * that connects directly to your server,
  12. * a requirement when you cannot know the address
  13. * of your proxy (e.g. if using Rackspace balancers).
  14. *
  15. * The "**" character is syntactic sugar within
  16. * TrustedProxy to trust not just any proxy that
  17. * connects directly to your server, but also
  18. * proxies that connect to those proxies, and all
  19. * the way back until you reach the original source
  20. * IP. It will mean that $request->getClientIp()
  21. * always gets the originating client IP, no matter
  22. * how many proxies that client's request has
  23. * subsequently passed through.
  24. */
  25. 'proxies' => env('TRUST_PROXIES', ''),
  26. ];