{"id":47084,"date":"2024-10-07T11:16:42","date_gmt":"2024-10-07T03:16:42","guid":{"rendered":"https:\/\/server.hk\/cnblog\/47084\/"},"modified":"2024-10-07T11:16:42","modified_gmt":"2024-10-07T03:16:42","slug":"iis%e7%8b%80%e6%85%8b%e7%a2%bc-400-bad-request%ef%bc%88%e9%8c%af%e8%aa%a4%e8%ab%8b%e6%b1%82%ef%bc%89","status":"publish","type":"post","link":"https:\/\/server.hk\/cnblog\/47084\/","title":{"rendered":"IIS\u72c0\u614b\u78bc &#8211; 400 Bad Request\uff08\u932f\u8aa4\u8acb\u6c42\uff09"},"content":{"rendered":"<h1 id=\"iis%e7%8b%80%e6%85%8b%e7%a2%bc-400-bad-request%ef%bc%88%e9%8c%af%e8%aa%a4%e8%ab%8b%e6%b1%82%ef%bc%89-YslBoGkETZ\">IIS\u72c0\u614b\u78bc &#8211; 400 Bad Request\uff08\u932f\u8aa4\u8acb\u6c42\uff09<\/h1>\n<p>\u5728\u7db2\u7d61\u61c9\u7528\u7a0b\u5e8f\u7684\u904b\u884c\u4e2d\uff0cHTTP\u72c0\u614b\u78bc\u662f\u7528\u4f86\u6307\u793a\u8acb\u6c42\u7684\u7d50\u679c\u7684\u91cd\u8981\u5de5\u5177\u3002\u9019\u4e9b\u72c0\u614b\u78bc\u5e6b\u52a9\u958b\u767c\u8005\u548c\u7528\u6236\u7406\u89e3\u8acb\u6c42\u662f\u5426\u6210\u529f\uff0c\u4ee5\u53ca\u5982\u679c\u5931\u6557\uff0c\u5931\u6557\u7684\u539f\u56e0\u3002\u672c\u6587\u5c07\u6df1\u5165\u63a2\u8a0eIIS\uff08Internet Information Services\uff09\u4e2d\u7684400 Bad Request\u72c0\u614b\u78bc\uff0c\u4e26\u5206\u6790\u5176\u6210\u56e0\u3001\u5f71\u97ff\u53ca\u89e3\u6c7a\u65b9\u6848\u3002<\/p>\n<h2 id=\"%e4%bb%80%e9%ba%bc%e6%98%af400-bad-request%ef%bc%9f-YslBoGkETZ\">\u4ec0\u9ebc\u662f400 Bad Request\uff1f<\/h2>\n<p>400 Bad Request\u662f\u4e00\u500bHTTP\u72c0\u614b\u78bc\uff0c\u8868\u793a\u4f3a\u670d\u5668\u7121\u6cd5\u7406\u89e3\u5ba2\u6236\u7aef\u767c\u9001\u7684\u8acb\u6c42\u3002\u9019\u901a\u5e38\u662f\u7531\u65bc\u8acb\u6c42\u7684\u8a9e\u6cd5\u932f\u8aa4\u6216\u7121\u6548\u7684\u8acb\u6c42\u53c3\u6578\u6240\u5c0e\u81f4\u7684\u3002\u7576\u4f3a\u670d\u5668\u7121\u6cd5\u8655\u7406\u8acb\u6c42\u6642\uff0c\u5b83\u6703\u8fd4\u56de\u6b64\u72c0\u614b\u78bc\uff0c\u4e26\u901a\u5e38\u6703\u9644\u5e36\u4e00\u500b\u932f\u8aa4\u6d88\u606f\uff0c\u544a\u8a34\u7528\u6236\u8acb\u6c42\u7684\u5177\u9ad4\u554f\u984c\u3002<\/p>\n<h2 id=\"400-bad-request%e7%9a%84%e5%b8%b8%e8%a6%8b%e5%8e%9f%e5%9b%a0-YslBoGkETZ\">400 Bad Request\u7684\u5e38\u898b\u539f\u56e0<\/h2>\n<ul>\n<li><strong>\u8a9e\u6cd5\u932f\u8aa4\uff1a<\/strong>\u8acb\u6c42\u7684\u683c\u5f0f\u4e0d\u6b63\u78ba\uff0c\u4f8b\u5982\u7f3a\u5c11\u5fc5\u8981\u7684\u6a19\u982d\u6216\u4f7f\u7528\u4e86\u4e0d\u6b63\u78ba\u7684HTTP\u65b9\u6cd5\u3002<\/li>\n<li><strong>\u7121\u6548\u7684URL\uff1a<\/strong>\u8acb\u6c42\u7684URL\u683c\u5f0f\u4e0d\u6b63\u78ba\uff0c\u53ef\u80fd\u5305\u542b\u975e\u6cd5\u5b57\u7b26\u6216\u932f\u8aa4\u7684\u7de8\u78bc\u3002<\/li>\n<li><strong>\u8acb\u6c42\u904e\u5927\uff1a<\/strong>\u7576\u8acb\u6c42\u7684\u5927\u5c0f\u8d85\u904e\u4f3a\u670d\u5668\u7684\u9650\u5236\u6642\uff0c\u4f3a\u670d\u5668\u6703\u8fd4\u56de400\u932f\u8aa4\u3002<\/li>\n<li><strong>\u7121\u6548\u7684\u67e5\u8a62\u53c3\u6578\uff1a<\/strong>\u67e5\u8a62\u5b57\u7b26\u4e32\u4e2d\u7684\u53c3\u6578\u4e0d\u7b26\u5408\u4f3a\u670d\u5668\u7684\u9810\u671f\u683c\u5f0f\u6216\u7bc4\u570d\u3002<\/li>\n<\/ul>\n<h2 id=\"%e5%a6%82%e4%bd%95%e6%8e%92%e6%9f%a5400-bad-request%e9%8c%af%e8%aa%a4-YslBoGkETZ\">\u5982\u4f55\u6392\u67e5400 Bad Request\u932f\u8aa4<\/h2>\n<p>\u7576\u9047\u5230400 Bad Request\u932f\u8aa4\u6642\uff0c\u958b\u767c\u8005\u53ef\u4ee5\u63a1\u53d6\u4ee5\u4e0b\u6b65\u9a5f\u9032\u884c\u6392\u67e5\uff1a<\/p>\n<h3 id=\"1-%e6%aa%a2%e6%9f%a5%e8%ab%8b%e6%b1%82%e7%9a%84url-YslBoGkETZ\">1. \u6aa2\u67e5\u8acb\u6c42\u7684URL<\/h3>\n<p>\u78ba\u4fdd\u8acb\u6c42\u7684URL\u6b63\u78ba\u7121\u8aa4\uff0c\u4e26\u4e14\u4e0d\u5305\u542b\u4efb\u4f55\u975e\u6cd5\u5b57\u7b26\u3002\u53ef\u4ee5\u4f7f\u7528URL\u7de8\u78bc\u5de5\u5177\u4f86\u6aa2\u67e5URL\u7684\u6709\u6548\u6027\u3002<\/p>\n<h3 id=\"2-%e6%aa%a2%e6%9f%a5http%e6%a8%99%e9%a0%ad-YslBoGkETZ\">2. \u6aa2\u67e5HTTP\u6a19\u982d<\/h3>\n<p>\u78ba\u8a8d\u8acb\u6c42\u4e2d\u5305\u542b\u6240\u6709\u5fc5\u8981\u7684HTTP\u6a19\u982d\uff0c\u4e26\u4e14\u683c\u5f0f\u6b63\u78ba\u3002\u4f8b\u5982\uff0cContent-Type\u6a19\u982d\u61c9\u8a72\u6b63\u78ba\u5730\u63cf\u8ff0\u8acb\u6c42\u9ad4\u7684\u683c\u5f0f\u3002<\/p>\n<h3 id=\"3-%e6%b8%ac%e8%a9%a6%e8%ab%8b%e6%b1%82%e5%a4%a7%e5%b0%8f-YslBoGkETZ\">3. \u6e2c\u8a66\u8acb\u6c42\u5927\u5c0f<\/h3>\n<p>\u6aa2\u67e5\u8acb\u6c42\u7684\u5927\u5c0f\u662f\u5426\u8d85\u904e\u4f3a\u670d\u5668\u7684\u9650\u5236\u3002\u53ef\u4ee5\u901a\u904e\u6e1b\u5c11\u8acb\u6c42\u9ad4\u7684\u5927\u5c0f\u4f86\u9032\u884c\u6e2c\u8a66\u3002<\/p>\n<h3 id=\"4-%e4%bd%bf%e7%94%a8%e9%96%8b%e7%99%bc%e8%80%85%e5%b7%a5%e5%85%b7-YslBoGkETZ\">4. \u4f7f\u7528\u958b\u767c\u8005\u5de5\u5177<\/h3>\n<p>\u5229\u7528\u700f\u89bd\u5668\u7684\u958b\u767c\u8005\u5de5\u5177\u4f86\u67e5\u770b\u8acb\u6c42\u7684\u8a73\u7d30\u4fe1\u606f\uff0c\u5305\u62ec\u8acb\u6c42\u7684\u6a19\u982d\u548c\u53c3\u6578\uff0c\u9019\u6709\u52a9\u65bc\u5feb\u901f\u5b9a\u4f4d\u554f\u984c\u3002<\/p>\n<h2 id=\"%e5%a6%82%e4%bd%95%e8%a7%a3%e6%b1%ba400-bad-request%e9%8c%af%e8%aa%a4-YslBoGkETZ\">\u5982\u4f55\u89e3\u6c7a400 Bad Request\u932f\u8aa4<\/h2>\n<p>\u89e3\u6c7a400 Bad Request\u932f\u8aa4\u7684\u65b9\u6cd5\u53d6\u6c7a\u65bc\u5177\u9ad4\u7684\u554f\u984c\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u898b\u7684\u89e3\u6c7a\u65b9\u6848\uff1a<\/p>\n<ul>\n<li><strong>\u4fee\u6b63\u8acb\u6c42\u8a9e\u6cd5\uff1a<\/strong>\u78ba\u4fdd\u8acb\u6c42\u7684\u8a9e\u6cd5\u6b63\u78ba\uff0c\u4e26\u7b26\u5408HTTP\u5354\u8b70\u7684\u8981\u6c42\u3002<\/li>\n<li><strong>\u66f4\u65b0URL\uff1a<\/strong>\u5982\u679cURL\u4e0d\u6b63\u78ba\uff0c\u8acb\u4fee\u6b63\u4e26\u91cd\u65b0\u767c\u9001\u8acb\u6c42\u3002<\/li>\n<li><strong>\u8abf\u6574\u8acb\u6c42\u5927\u5c0f\uff1a<\/strong>\u5982\u679c\u8acb\u6c42\u904e\u5927\uff0c\u8003\u616e\u5206\u5272\u8acb\u6c42\u6216\u6e1b\u5c11\u8acb\u6c42\u9ad4\u7684\u5167\u5bb9\u3002<\/li>\n<li><strong>\u6aa2\u67e5\u4f3a\u670d\u5668\u914d\u7f6e\uff1a<\/strong>\u78ba\u4fdd\u4f3a\u670d\u5668\u7684\u914d\u7f6e\u5141\u8a31\u63a5\u6536\u7576\u524d\u7684\u8acb\u6c42\u683c\u5f0f\u548c\u5927\u5c0f\u3002<\/li>\n<\/ul>\n<h2 id=\"%e7%b8%bd%e7%b5%90-YslBoGkETZ\">\u7e3d\u7d50<\/h2>\n<p>400 Bad Request\u72c0\u614b\u78bc\u662f\u7db2\u7d61\u61c9\u7528\u7a0b\u5e8f\u4e2d\u5e38\u898b\u7684\u932f\u8aa4\u4e4b\u4e00\uff0c\u4e86\u89e3\u5176\u6210\u56e0\u548c\u89e3\u6c7a\u65b9\u6cd5\u5c0d\u65bc\u958b\u767c\u8005\u4f86\u8aaa\u81f3\u95dc\u91cd\u8981\u3002\u901a\u904e\u4ed4\u7d30\u6aa2\u67e5\u8acb\u6c42\u7684\u8a9e\u6cd5\u3001URL\u548c\u53c3\u6578\uff0c\u958b\u767c\u8005\u53ef\u4ee5\u6709\u6548\u5730\u6392\u67e5\u548c\u89e3\u6c7a\u9019\u4e00\u554f\u984c\u3002\u5c0d\u65bc\u9700\u8981\u7a69\u5b9a\u548c\u9ad8\u6548\u7684\u7db2\u7d61\u670d\u52d9\u7684\u7528\u6236\uff0c\u9078\u64c7\u5408\u9069\u7684 <a href=\"https:\/\/server.hk\">VPS<\/a> \u6216 <a href=\"https:\/\/server.hk\">\u9999\u6e2f\u4f3a\u670d\u5668<\/a> \u65b9\u6848\u5c07\u6709\u52a9\u65bc\u6e1b\u5c11\u6b64\u985e\u932f\u8aa4\u7684\u767c\u751f\uff0c\u78ba\u4fdd\u61c9\u7528\u7a0b\u5e8f\u7684\u6b63\u5e38\u904b\u884c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e86\u89e3IIS\u72c0\u614b\u78bc400 Bad Request\uff08\u932f\u8aa4\u8acb\u6c42\uff09\u7684\u539f\u56e0\u53ca\u89e3\u6c7a\u65b9\u6cd5\uff0c\u5e6b\u52a9\u60a8\u5feb\u901f\u6392\u9664\u7db2\u7ad9\u8a2a\u554f\u554f\u984c\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4924],"tags":[],"class_list":["post-47084","post","type-post","status-publish","format-standard","hentry","category-setup-tutorials"],"_links":{"self":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/47084","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/comments?post=47084"}],"version-history":[{"count":1,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/47084\/revisions"}],"predecessor-version":[{"id":47085,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/posts\/47084\/revisions\/47085"}],"wp:attachment":[{"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/media?parent=47084"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/categories?post=47084"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/server.hk\/cnblog\/wp-json\/wp\/v2\/tags?post=47084"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}