google-cloud-platformgoogle-cloud-rungoogle-cloud-networkinggcp-load-balancer

Google is blocking traffic because it detects automated queries


When I try to access my website deployed on Google Cloud I receive the following error page:

We're sorry...

... but your computer or network may be sending automated queries. To protect our users, we can't process your request right now.

Here are the details of my setup:

Troubleshooting:

Based on this, there seems to be some network configuration/security occurring near the load balancer.

Any solutions or suggestions to continue debugging?


Solution

  • So far the two only workarounds available are:

    Both are not acceptable on production systems unless you don't care about security. We are trying to work out what are the IAP headers lost between NGINX and Cloud RUN but I guess the issue affects also infrastructure without NGINX

    EDIT the issue tracker post https://issuetracker.google.com/issues/265184232 looks related to the issue. The workaround suggested by the google team is to switch to a Global HTTP Classic Load Balancer We tried and it did not work but we may have a different problem. Hope that helps anyone else for the time being

    EDIT 2 In our NGINX configuration we proxy the request to a public Cloud RUN API which at the moment is affected by the issue.

    I was able to proxy the request successfully just by removing the JWT header added by IAP (leaving any other headers with the authenticated user) example of my config

     location /api/ {
        #remove iap jwt token header 
        proxy_set_header        X-Goog-Iap-Jwt-Assertion "";
    
        # proxy to the public cloud run instance
        proxy_pass https://myCloudRun-123456basd-ew.a.run.app/;
    }