403 for multiple user agents

Payam Chychi pchychi at gmail.com
Mon Apr 6 01:53:42 MSD 2009


wow, feel kinda dumb... :)
 i used "|" statement in between each string and it works like a charm

cheers
-payam




On Sun, Apr 5, 2009 at 2:22 PM, Payam Chychi <pchychi at gmail.com> wrote:
> Hi,
>
> I recall there was a way to search for multiple strings within the
> user agent to allow a 403 redirect... but i cant find any info on
> this.
>
> example. im 403`ing any user agents that match the Macintosh string.
> now id like to be able to do this for say "Macintosh, Windows,
> Firefox..." so on
>
> if ($http_user_agent ~ Macintosh) {
>    return 403;
> }
>
> thanks
>
> --
> Payam Tarverdyan Chychi
> Network Security Specialist / Network Engineer
>



-- 
Payam Tarverdyan Chychi
Network Security Specialist / Network Engineer





More information about the nginx mailing list