403 Forbidden - GCP & Cloud Functions

@arnar Thank you for sharing your issue.

Companies House, can you please look into this issue again? Now we can see this affection for more than one user and I believe much more users have the same.

Much appreciate your collaboration

Dino Correia

Would like to toss my hat in and say I am also having the same issue with Firebase functions on europe-west2, however europe-west3 is working fine.

1 Like

As you are aware there is rate limiting applied to our services - in terms of your use case - are you getting 403 constantly?

Steve

Yes, I’m aware of rate-limiting, and the number of requests we made shouldn’t block the IP address. I never saw 429 responses, only 403.

With Cloud Functions, we cannot control the outbound IP address because it’s managed by Google and this IP address can be shared with multiple users - the reason other members of the forum are having the same issue.

What happened, in this case, could be some other user that used Google Services as well (Cloud Functions or App Engine) and did too many requests to the Companies House API and your services blocked the IP that is shared with multiple users even we’re using different keys.

I created an endpoint on Cloud Functions and send the request from GCP to my local machine to be able to view the outbound IP address of Cloud Functions and I’m receiving: 107.178.231.82 or 107.178.192.0/18

Can you please verify if this IP address is on your list of blocked IP addresses or could you please tell us another way we could provide some other information to solve this problem?

Thank you

I don’t think this is related to rate limiting.

It seems that from this thread, all requests from europe-west2 will fail, regardless of the number of previous requests to your API have been made. This can be proven by using the same key/endpoint on europe-west3 or any of the other GCP regions.

I can confirm that IP’s in the 107 range were prevented from accessing our services. This was as a result of breaching our fair usage policy. This restriction has now been removed. Could you please confirm you can now access the services?

Steve

I’m still receiving 403 unfortunately.

@dr0id @arnar @rentsurance can you please confirm on your side, please?

Yep, can confirm I’m still getting a 403 - I’m not sure of the IP that’s being used though.

@SteveBowen As of this morning, I’m getting the 403 error again from Google europe-west2.

Have any changes been made in the last 24-48 hours to the IP blocks again?

Cheers.

I can confirm that we re-instated WAF rules and a list of banned IP addresses yesterday after our services were adversely affected by excessive requests from a small number of IP addresses.
If you are getting intermittent 403’s you are exceeding limits. If you are ONLY getting 403’s, you are on the ‘banned’ list.
Please let us know which of these you are.

Hi @MArkWilliams,

I believe I’m on the banned list, the server that is sending the requests isn’t used very frequently and checking the logs, we’ve only had a handful of requests and they’ve all 403ed.

As my app is hosted on Google Appengine, I don’t have a static IP that I can send your way although it’s application ID 601e718f6670a39a1137a223 if that helps.

I’d set up a VPC to get a fixed static IP, but then I’d be incurring extra costs and may still get banned next time a large range is banned.

Cheers.

Hey @dr0id, after my last message on this thread, our API was still receiving 403 and was hosted with Google Cloud Functions that is hard to figure out the IP because isn’t static, as you mention. We had to move to another provider to handle the requests to companies house but requests reduced the performance due to this middle layer.

The way I previous figure out the IP address from Google Functions was by running a quick NodeJs + Express on my local machine and with help of ngrok exposing the localhost to a public URL. Then, I made a request from the Live API to the server running on my machine locally and had access to the IP via the request’s headers.

I tried to send a curl via G cloud console but the IPs are different from the Google Functions and perhaps with App Engine too.

1 Like

Hi,

Is there any update on this?

Cheers.

Hi @MArkWilliams

Still looking for a resolution here if possible. I don’t think blanket banning an entire GCP region is the correct route forward.

We are also seeing this issue of 403 errors, when using Google Cloud functions. It is a bit more sporadic for us. It works most of the time but fails intermittently.