简体   繁体   English

发出获取请求时的403响应

[英]403 response when making a get request

I'm getting a 403 response when making a get request to this website ( https://volusia.county-taxes.com ) using python3 in aws EC2 server. 在AWS EC2服务器中使用python3向此网站( https://volusia.county-taxes.com )进行get请求时,我收到403响应。 But I'm getting success response in my local system using same code. 但是我正在使用相同的代码在本地系统中获得成功响应。

Please help me. 请帮我。 Why im not able to make a get request in aws ec2 server? 为什么我无法在AWS EC2服务器中发出获取请求?

In aws EC2 server 在AWS EC2服务器中

import requests
requests.get('https://volusia.county-taxes.com')

<Response [403]>

In my local system 在我的本地系统中

import requests
requests.get('https://volusia.county-taxes.com')

<Response [200]>

Can't say for sure, but a 403 is a 'forbidden' code, and it is not all that unusual for some websites to block traffic from the ec2 ip ranges to cut down on the number of bots/scrapers that tend to abuse websites and are often run on aws and other cloud providers. 不能肯定地说,但是403是一个“禁止”代码,对于某些网站来说,阻止来自ec2 ip范围的流量以减少倾向于滥用网站的漫游器/抓取工具的数量并不太常见并且通常在AWS和其他云提供商上运行。

Its possible that either the entire ec2 ip range is blocked, or else just some of the ips - especially if you have been running some sort of scraper from that ip, it may be blacklisted. 可能整个ec2 ip范围被阻止,或者仅某些ip被阻止-尤其是如果您已经从该ip运行某种爬虫,则它可能会被列入黑名单。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 向Giphy API提出请求时,为什么会收到HTTP错误403? - Why do I get a HTTP Error 403 when making a request to the Giphy API? 得到“ <Response [403]> ”在Python中使用request.post - Get “<Response [403]>” using request.post in Python curl 得到响应 403 - curl get response 403 尝试获取数据时页面给出403响应 - Page is giving 403 response when tried to get the data 在使用不记名令牌(Python)发出获取请求时获得 401 响应 - Getting 401 response while making get request with bearer token (Python) 通过使用javascript发出HTTP GET请求来显示response(xml)? - Display response(xml) by making a HTTP GET request using javascript? 为什么在使用 tetpyclient 发出 POST 请求时会收到 403 错误? - Why am I getting a 403 error when making a POST request using tetpyclient? 使用Docker在Django中使用POST数据发出urllib请求时,如何解决Forbidden 403错误? - How to resolve Forbidden 403 error when making a urllib request with POST data in Django using Docker? 如何在 Web 使用代理在 python 请求中抓取时获得更少的 403 和更多的 200 响应? - How to get less 403 and more 200 response while Web Scraping in python request using proxy? 为什么我的SurveyMonkey API get请求收到403错误响应? - Why am I getting a 403 error response with my SurveyMonkey API get request?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM