0

Web サイト用に JSON ベースの WS を使用しており、Google Bot から ASMX ファイルへのノンストップ リクエストを受け取ります。

これらのリクエストを停止するにはどうすればよいですか?

注:ここでそれについて読んでみましたが、WSのエレガントなソリューションを提供していないようです。

/w HTTP リクエストを受け取る例外は次のとおりです。

Logged date (UTC):  20/02/2011 12:00:59
Requested URL:      https://dynamic-subdomain.somedomain.com/ExternalApi/Rest/RateServices.asmx/GetRate

A general error has occured.

Exception:
System.InvalidOperationException: Request format is unrecognized for URL unexpectedly ending in '/GetRate'.
   at System.Web.Services.Protocols.WebServiceHandlerFactory.CoreGetHandler(Type type, HttpContext context, HttpRequest request, HttpResponse response)
   at System.Web.Services.Protocols.WebServiceHandlerFactory.GetHandler(HttpContext context, String verb, String url, String filePath)
   at System.Web.Script.Services.ScriptHandlerFactory.GetHandler(HttpContext context, String requestType, String url, String pathTranslated)
   at System.Web.HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig)
   at System.Web.HttpApplication.MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

HTTP Request:
GET /ExternalApi/Rest/RateServices.asmx/GetRate HTTP/1.1
Connection: Keep-alive
Accept: */*
Accept-Encoding: gzip,deflate
From: googlebot(at)googlebot.com
Host: dynamic-subdomain.somedomain.com
User-Agent: Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)
4

2 に答える 2

2

robots.txt ファイルの使用を検討しましたか?

于 2011-02-20T12:31:19.290 に答える
0

Robots.txt を使用すると、ほとんどのボットが Web サイトから特定のアクションにアクセスすることを禁止できます。Google には、これに関するサポートページがあります。
必要に応じてサーバーを構成できるように、それを見てください。
生成ツールは、ほとんどの場合に役立ちます。見てみな。

于 2011-02-21T07:19:30.257 に答える