403 Forbidden - 从谷歌搜索图片获取网址

时间:2014-02-21 21:11:06

标签: asp.net http-status-code-403

使用谷歌搜索引擎查找我的网站图片获得以下链接:

http://www.rionegro.com.ar/diario/funciones/binario/imagen.aspx%3Fidart%3D380098%26idcat%3D9862%26idcon%3D1087449%26resolucion%3D1%26tipo%3D2

正如您所看到的,网址有特殊字符,但我认为不应该是问题。

在搜索结果中,而不是显示图像,它会显示以下错误:

403 Forbidden

我检查firefox的firebug,我得到以下内容:

Response Headers
HTTP/1.1 403 Forbidden
Content- Length: 0
Server : Microsoft-IIS/7.5
X -Powered -By : ASP.NET
Date: Fri, 21 February 2014 20:53:02 GMT

请求标头     GET /diario/funciones/binario/imagen.aspx%3Fidart%3D380098%26idcat%3D9862%26idcon%3D1087449%26resolucion%3D1%26tipo%3D2HTTP/1.1     主持人:www.rionegro.com.ar     User -Agent:Mozilla / 5.0(Windows NT 6.1; WOW64; rv:27.0)Gecko / 20100101 Firefox / 27.0     接受:text / html,application / xhtml + xml,application / xml; q = 0.9,* / *,q = 0.8     Accept-语言:en -ar,is,q = 0.8,en- us; q = 0.5,in,q = 0.3     接受编码:gzip,deflate     Cookie:__ utma = 194708910.1295956645.1392158205.1392994869.1393012210.13; __utmz = 194708910.1392413045.7.2.utmcsr = 200.32.2.69 | utmccn =(推荐)| utmcmd =推荐| utmcct = / diario / inicio.aspx; _cb_ls = 1; _chartbeat2 = qdoy9rkh40fmppme.1392162975510.1392982793966.11011111011; _chartbeat_uuniq = 2    连接:keep -alive    缓存控制:max -age = 0

如果我使用特殊字符搜索正确的网址:

http://www.rionegro.com.ar/diario/funciones/binario/imagen.aspx?idart=380098&idcat=9862&idcon=1087449&resolucion=1&tipo=2

搜索结果正确,带上图像。

有人可以帮我解决问题,因为google会在文本开头向我返回上面提到的网址。

2 个答案:

答案 0 :(得分:0)

你有read the documentation吗? RFC 2616超文本传输​​协议 - HTTP / 1.1 说,在§10.4.4;中有关HTTP状态的说法403 Forbidden:

  

10.4.4 403禁止

     

服务器理解请求,但拒绝履行请求。授权不会   帮助和请求不应重复。如果请求方法不是HEAD而且   服务器希望公开为什么请求没有得到满足,它应该描述   该实体拒绝的原因。如果服务器不希望这样做   客户可以获得的信息,可以使用状态代码404(未找到)。

Google几乎可以检测到您搜索结果并拒绝了您的请求。

您需要从中获取API密钥(for which see this answer

另见

答案 1 :(得分:0)

  

如果您的请求超出了可用配额,则服务器将返回   HTTP 403状态。见下面的链接

Google Places Photo Api

相关问题