Warning: include(/home/blog66rr/public_html/wp-content/plugins/hyper-cache/cache.php): failed to open stream: No such file or directory in /home/blog66rr/public_html/wp-content/advanced-cache.php on line 24

Warning: include(/home/blog66rr/public_html/wp-content/plugins/hyper-cache/cache.php): failed to open stream: No such file or directory in /home/blog66rr/public_html/wp-content/advanced-cache.php on line 24

Warning: include(): Failed opening '/home/blog66rr/public_html/wp-content/plugins/hyper-cache/cache.php' for inclusion (include_path='.:/opt/cpanel/ea-php70/root/usr/share/pear') in /home/blog66rr/public_html/wp-content/advanced-cache.php on line 24

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723

Warning: Cannot modify header information - headers already sent by (output started at /home/blog66rr/public_html/wp-content/advanced-cache.php:24) in /home/blog66rr/public_html/wp-includes/rest-api/class-wp-rest-server.php on line 1723
{"id":233,"date":"2013-03-18T19:57:38","date_gmt":"2013-03-19T03:57:38","guid":{"rendered":"http:\/\/blog.unethost.com\/?p=233"},"modified":"2014-04-16T16:34:21","modified_gmt":"2014-04-16T08:34:21","slug":"introduction_to_php_hash_dos","status":"publish","type":"post","link":"https:\/\/blog.unethost.com\/introduction_to_php_hash_dos\/","title":{"rendered":"\u6dfa\u8ac7hash dos\u653b\u64ca"},"content":{"rendered":"

\u8eab\u70ba\u4e00\u500b\u4e3b\u6a5f\u5546\uff0c\u8655\u7406\u904e\u7684\u653b\u64ca\u4e2d\uff0c\u6700\u5bb9\u6613\u5f97\u624b\u7684\u653b\u64ca\uff0c\u5f80\u5f80\u662fDoS\u653b\u64ca\u3002DoS\u53c8\u540ddenial of service \uff0c\u9019\u7a2e\u653b\u64ca\u7684\u6982\u5ff5\u4e0d\u5f37\u8abf\u53bb\u66f4\u6539\u7db2\u7ad9\u7684\u5167\u5bb9\u6216\u662f\u5077\u53d6\u8cc7\u6599\uff0c\u53ea\u662f\u8b93\u7db2\u7ad9\u5012\u7ad9\u3002\u76f8\u5c0d\u65bcSQL injection, XSS\u9019\u4e00\u985e\u7684\u653b\u64ca\uff0c\u9700\u8981\u4f9d\u8cf4\u5beb\u7a0b\u5f0f\u7684\u4e0d\u5c0f\u5fc3\u3002DoS\u55ae\u7d14\u53c8\u66b4\u529b\uff0c\u4f46\u662f\u5f9e\u653b\u64ca\u8005\u7684\u89c0\u9ede\u4f86\u8aaa\uff0c\u975e\u5e38\u7684\u6709\u6548\u3002<\/p>\n

\u4ee5php\u9019\u7a2e\u8a9e\u8a00\u70ba\u4f8b\u5b50\uff0c\u5728\u5beb\u7a0b\u5f0f\u7684\u6642\u5019\uff0c\u53ef\u4ee5\u5229\u7528$_POST[“name”]\u5f9e\u7528\u6236\u7aef\u7684Post request\u4e2d\u5b58\u53d6name\u9019\u500b\u8b8a\u6578\u3002\u50cf\u9019\u6a23\u5b50\u7684\u6a5f\u5236\uff0c\u5c31\u662fphp\u8a9e\u8a00\u5be6\u4f5c\u7684hash tables(\u54c8\u5e0c\u8868)\u6240\u63d0\u4f9b\u7684\u3002\u7136\u800chash tables\u56fa\u6709\u7684\u7279\u6027\u4e4b\u4e00\uff0c\u5c31\u662f\u6703\u6709\u885d\u7a81\u7684\u6642\u5019\uff0c\u5373Hash Collision\u3002\u653b\u64ca\u8005\u53ef\u4ee5\u5229\u7528Hash Collision\u6703\u6d88\u8017\u5927\u91cf\u7684CPU\u904b\u7b97\u9019\u500b\u7279\u6027\uff0c\u767c\u52d5hash DoS\u653b\u64ca\u3002<\/p>\n

\u9019\u500b\u653b\u64ca\u7684\u767c\u52d5\u65b9\u5f0f\u662f\u9019\u6a23\u5b50\uff1a\u653b\u64ca\u8005\u7d66\u4e88php\u7db2\u9801\u4e00\u500bPost request\uff0c\u4e26\u4e14\u5728\u9019\u500b\u55ae\u4e00\u7684request\u4e4b\u4e2d\uff0c\u63d0\u4ea4\u5927\u91cf\u7684\u53c3\u6578\uff0c\u800c\u4e14\u9019\u4e9b\u53c3\u6578\u900f\u904ephp\u7684hash\u898f\u5247\u90fd\u6070\u597d\u6703\u767c\u751fhash collision\u3002\u9019\u6a23\u5b50\u7684\u653b\u64ca\u65b9\u5f0f\uff0c\u57282003\u5e74\u5728\u8a31\u591a\u8a9e\u8a00(Perl, CRuby)\u4e2d\u88ab\u767c\u73fe\u3002<\/p>\n

\u76ee\u524d\uff0c\u8a31\u591a\u8a9e\u8a00\u5728\u5176\u66f4\u65b0\u7684\u7248\u672c\u4e2d\uff0c\u5df2\u7d93\u6709\u91dd\u5c0d\u9019\u4e00\u9ede\u53bb\u6539\u5584\u4e86\u3002\u4ee5php\u70ba\u4f8b\u5b50\uff0c\u5f9e php\u76845.3.9\u7248\u672c\u958b\u59cb\uff0c\u6709\u4e00\u500b\u6307\u4ee4 max_input_var<\/a>\uff0c\u5b83\u53ef\u4ee5\u53bb\u9650\u5236GET\uff0cPOST\uff0cCookie\u9019\u4e9b\u8b8a\u6578\u7684\u9577\u5ea6\uff0c\u6700\u9577\u53ea\u80fd\u52301000\u3002\u6709\u4e86\u9019\u500b\u7279\u6027\uff0c\u8981hash dos\u5c31\u4e0d\u592a\u5bb9\u6613\u4e86\u3002<\/p>\n

\u5c0d\u65bc\u4e0d\u5e78\u4f7f\u7528\u820a\u7248php\u7684\u4eba\uff0c\u4e5f\u53ef\u4ee5\u8003\u616e\u4f7f\u7528ModSecurity\u7684\u898f\u5247\u4f86\u6514\u963b\u9019\u7a2e\u653b\u64ca\u3002\u4f8b\u5982\u4e0b\u65b9\u7684rule\uff0c\u5c31\u662f\u985e\u4f3cmax_input_vars\u7684\u6548\u679c\u3002<\/p>\n

SecRule &ARGS|&REQUEST_COOKIES_NAMES|&REQUEST_COOKIES \"@gt 1000\" \"phase:2, \\t:none,log,block,severity:2,msg:'Hash DoS Detected'\"<\/pre>\n","protected":false},"excerpt":{"rendered":"

\u8eab\u70ba\u4e00\u500b\u4e3b\u6a5f\u5546\uff0c\u8655\u7406\u904e\u7684\u653b\u64ca\u4e2d\uff0c\u6700\u5bb9\u6613\u5f97\u624b\u7684\u653b\u64ca\uff0c\u5f80\u5f80\u662fDoS\u653b\u64ca\u3002DoS\u53c8\u540ddenial of servic … \u95b1\u8b80\u5168\u6587 \u6dfa\u8ac7hash dos\u653b\u64ca<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false},"categories":[3],"tags":[62,61],"_links":{"self":[{"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/posts\/233"}],"collection":[{"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/comments?post=233"}],"version-history":[{"count":4,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/posts\/233\/revisions"}],"predecessor-version":[{"id":641,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/posts\/233\/revisions\/641"}],"wp:attachment":[{"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/media?parent=233"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/categories?post=233"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.unethost.com\/wp-json\/wp\/v2\/tags?post=233"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}