location / { if ( $request_uri ~* abc ){ return 402; } }