linux ftp \u7528\u6237\u6307\u5b9a\u76ee\u5f55<\/strong>\uff0c\u6211\u4eec\u5c31\u5b8c\u6210\u4e86vsftpd\u7684FTP\u4e3b\u76ee\u5f55\u8bbe\u7f6e\u3002<\/p>\n\u6280\u5de7\u4e8c\uff1a\u4f7f\u7528FTP\u865a\u62df\u7528\u6237\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55<\/p>\n
\u5047\u5982\u4f60\u4e0d\u60f3\u4f9d\u7167FTP\u7528\u6237\u540d\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\uff0c\u4f60\u8fd8\u53ef\u4ee5\u4f7f\u7528FTP\u865a\u62df\u7528\u6237\u3002FTP\u865a\u62df\u7528\u6237\u5177\u6709\u81ea\u5df1\u7684\u7528\u6237\u540d\u548c\u5bc6\u7801\uff0c\u4f46\u5b83\u4eec\u4e0d\u987b\u8981\u5728Linux\u7cfb\u7edf\u4e2d\u6ce8\u518c\u3002\u8fd9\u5bb9\u8bb8\u4f60\u4f7f\u7528\u81ea\u5df1\u7684\u72ec\u7acb\u7528\u6237\u6570\u636e\u5e93\u6765\u7ba1\u7406FTP\u7528\u6237\u3002<\/p>\n
\u5728\u8fd9\u4e9b\u60c5\u51b5\u4e0b\uff0c\u6211\u4eec\u987b\u8981\u5b89\u88c5\u4e00\u4e2a\u79f0\u4e3adb-util\u7684\u8f6f\u4ef6\u5305linux \u7535\u5b50\u4e66\uff0c\u8be5\u8f6f\u4ef6\u624b\u5305\u542b\u7528\u4e8e\u521b\u5efa\u7528\u6237\u6570\u636e\u5e93\u7684\u547d\u4ee4\u3002<\/p>\n
\u201c`<\/p>\n
sudoyuminstalldb-util<\/p>\n
\u201c`<\/p>\n
\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u6211\u4eec\u5f00\u59cb\u521b\u5efa\u81ea\u5df1\u7684\u7528\u6237\u6570\u636e\u5e93\u3002\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u521b\u5efa\u65b0\u7528\u6237db\uff1a<\/p>\n
\u201c`<\/p>\n
<\/p>\n
sudodb4.8_load-T-thash-f\/etc\/vsftpd\/virtual_users.db\/etc\/vsftpd\/virtual_users.txt<\/p>\n
\u201c`<\/p>\n
\u8bf7\u6ce8\u610f\uff0c\u6211\u4eec\u4f7f\u7528virtual_users.txt\u6587\u4ef6\u4e2d\u5217\u4e3e\u7684\u7528\u6237\u540d\u548c\u5bc6\u7801\u521b\u5efa\u4e86\u65b0\u7684\u865a\u62df\u7528\u6237\u6570\u636e\u5e93\u3002<\/p>\n
\u63a5\u51fa\u6765\uff0c\u6211\u4eec\u987b\u8981\u4f7f\u7528\u4ee5\u4e0b\u547d\u4ee4\u5728\u914d\u7f6e\u6587\u4ef6\u4e2d\u6dfb\u52a0\u4e0e\u65b0\u865a\u62df\u7528\u6237\u6570\u636e\u5e93\u7684\u94fe\u63a5\uff1a<\/p>\n
\u201c`<\/p>\n
sudovi\/etc\/vsftpd\/vsftpd.conf<\/p>\n
\u201c`<\/p>\n
\u6dfb\u52a0\u4ee5\u4e0b\u884c\uff1a<\/p>\n
\u201c`<\/p>\n
user_config_dir=\/etc\/vsftpd\/virtual_users\/<\/p>\n
virtual_use_local_privs=YES<\/p>\n
guest_enable=YES<\/p>\n
\u201c`<\/p>\n
\u4e4b\u4e00\u884c\u544a\u8bc9vsftpd\u670d\u52a1\u8981\u5728\/etc\/vsftpd\/virtual_users\/\u76ee\u5f55\u4e0b\u67e5\u627e\u865a\u62df\u7528\u6237\u914d\u7f6e\u6587\u4ef6\u3002\u7b2c\u4e8c\u884c\u51c6\u8bb8\u865a\u62df\u7528\u6237\u5de5\u4f5c\u76ee\u5f55\u5bb9\u8bb8\u6267\u884c\u6587\u4ef6\uff0c\u5e76\u53ef\u4ee5\u5bf9FTP\u7528\u6237\u8fdb\u884c\u8bfb\/\u5199\u8bbf\u95ee\u6743\u9650\u3002\u7b2c\u4e09\u884c\u542f\u7528\u987e\u5ba2\u7aef\u767b\u5165\u8d26\u6237\u7684\u865a\u62df\u4e3b\u76ee\u5f55\uff0c\u5373\u4e0e\u5176\u8d26\u6237\u76f8\u5173\u8054\u7684\u76ee\u5f55\u3002<\/p>\n
\u5728\u521b\u5efa\u865a\u62df\u7528\u6237\u76ee\u5f55\u4e2d\uff0c\u987b\u8981\u5728*\/etc\/vsftpd\/virtual_users\/*\u76ee\u5f55\u4e0b\u521b\u5efa\u4e00\u4e2a\u6587\u4ef6\uff0c\u5e76\u4f7f\u7528vi\u7f16\u8f91\u5668\u6253\u5f00\u3002\u5728\u6587\u4ef6\u4e2d\uff0c\u4f60\u987b\u8981\u4e3a\u6bcf\u4f4dFTP\u865a\u62df\u7528\u6237\u6307\u5b9a\u4e3b\u76ee\u5f55\u3002\u8bf8\u5982\uff0c\u5047\u5982FTP\u865a\u62df\u7528\u6237\u7684\u7528\u6237\u540d\u4e3aftpuser\uff0c\u5219\u53ef\u4ee5\u5728\/etc\/vsftpd\/virtual_users\/ftpuser\u6587\u4ef6\u4e2d\u6dfb\u52a0\u4ee5\u4e0b\u884c\uff1a<\/p>\n
\u201c`<\/p>\n
local_root=\/var\/ftproot\/ftpuser<\/p>\n
\u201c`<\/p>\n
\u6b64\u884c\u6307\u5b9aftpuser\u7684\u4e3b\u76ee\u5f55\u4e3a\/var\/ftproot\/ftpuser\u3002<\/p>\n
\u6700\u540e\u987b\u8981\u521b\u5efa\u5404\u4e2aFTP\u7528\u6237\u7684\u4e3b\u76ee\u5f55<\/p>\n
\u201c`<\/p>\n
sudomkdir\/var\/ftproot\/ftpuser<\/p>\n
sudochownnobody:nobody\/var\/ftproot\/ftpuser<\/p>\n
sudochmoda-w\/var\/ftproot\/ftpuser<\/p>\n
sudochmodu+w\/var\/ftproot\/ftpuser<\/p>\n
\u201c`<\/p>\n
\u5b8c\u6210\u4e0a\u8ff0\u64cd\u4f5c\uff0c\u4f60\u5c31\u80fd\u5426\u4e3aFTP\u7528\u6237\u8bbe\u7f6e\u4e3b\u76ee\u5f55\u5e76\u4f7f\u7528FTP\u670d\u52a1\u5668\u4e86\u3002<\/p>\n
\u7ed3\u5c3e<\/p>\n
\u5728\u672c\u6587\u4e2d\uff0c\u6211\u4eec\u4ecb\u7ecd\u4e86\u5728Linux\u4e0a\u600e\u4e48\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528vsftpd\u7b49\u6d41\u884c\u7684FTP\u8f6f\u4ef6\uff0c\u6309\u7167\u5b9e\u9645\u9700\u6c42\u9009\u62e9\u4e0d\u540c\u7684\u65b9\u5f0f\u8fdb\u884c\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\u3002\u65e0\u8bba\u54ea\u79cd\u65b9\u5f0f\uff0c\u90fd\u53ef\u4ee5\u4f7fFTP\u670d\u52a1\u6108\u53d1\u5b89\u5168\u548c\u53ef\u9760\u3002\u901a\u8fc7\u4e0a\u8ff0\u624b\u518c\uff0c\u60a8\u53ef\u4ee5\u8f7b\u677e\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\uff0c\u5e76\u4e3a\u7528\u6237\u63d0\u4f9b\u5b89\u5168\u7684\u6587\u4ef6\u4f20\u8f93\u670d\u52a1\u3002<\/p>\n
\u76f8\u5173\u95ee\u9898\u62d3\u5c55\u9605\u8bfb\uff1a<\/p>\n
linux\u4e0b\u8bbe\u7f6e\u7528\u6237\u767b\u5165FTP\u670d\u52a1\u5668\u65f6\uff0c\u6240\u5728\u7684\u76ee\u5f55<\/p>\n
\u5728vsftpd.conf\u8fd9\u4e2a\u6587\u4ef6\u4e0a\u9762\u7684\uff0clocal_enable=yes\uff0c\u9996\u5148\u8981\u5f00\u542f\u8fd9\u4e2a\uff0c\u4e4b\u540e\u7528useradd\u547d\u4ee4\u65b0\u5efa\u672c\u5730\u7528\u6237\uff0c\u4e4b\u540e\u628a\u81ea\u5bb6\u76ee\u5f55\u7531\u505a\u8ba9\/home\uff0c\u6539\u4e3a\u5176\u4ed6\uff0c\u8981\u66f4\u6539\u8fd9\u4e2a\u6587\u4ef6linux ftp \u7528\u6237\u6307\u5b9a\u76ee\u5f55<\/strong>\uff0c\/etc\/passwd\uff1a<\/p>\nroot:x:0:0:root:\/root:\/bin\/bash<\/p>\n
<\/p>\n
bin:x:1:1:bin:\/bin:\/in\/nologin<\/p>\n
daemon:x:2:2:daemon:\/in:\/in\/nologin<\/p>\n
desktop:x:80:80:desktop:\/var\/lib\/\u4f8d\u8ba9menu\/kde:\/in\/nologin<\/p>\n
mengqc:x:500:500:mengqc:\/home\/mengqc:\/bin\/bash<\/p>\n
\u5982\u4e0a\u6240\u663e\u793a\uff0c\u627e\u5230\u4f60\u7684\u672c\u5730\u7528\u6237\uff0c\u4e4b\u540e\u628a\/home\u65c1\u8fb9\u7684\u8def\u5f84\u6539\u4e86\u5c31\u53ef\u4ee5\uff0c\u8bb0\u5f97\u4fdd\u5b58\u8fd9\u4e2a\u6587\u4ef6\u3002\u8fd9\u6837FTP\u7528\u6237\u5c31\u53ef\u4ee5\u7528\u672c\u5730\u7528\u6237\u767b\u5165\u4e86\uff0c\u4e0d\u6539\u8def\u5f84\u7684\u7eaf\u8c08\u5c40\u8bdd\u987b\u8981\u53e6\u5916\u5f00\u542f\/home\u7684\u8bbf\u95ee\u6743\u9650\uff0c\u56e0\u4e3a\u8fd9\u4e2a\u662f\u654f\u611f\u76ee\u5f55\uff0c\u6240\u4ee5\u4e2a\u4eba\u5e76\u4e0d\u63a8\u8350\u5f00\u542f\u3002<\/p>\n
linux\u4e0bXampp\u4e2dftp\u7684\u914d\u7f6e\u95ee\u9898<\/p>\n
\u7b80\u5355\u7684\u529e\u6cd5\u5c31\u662f\u5728linux\u4e2d\u5206\u522b\u521b\u5efa\u8d26\u53f7\uff0c\u4f46\u662f\u628a\u8d26\u53f7\u4e3b\u76ee\u5f55\u8bbe\u7f6e\u4e3a\u76f8\u5173\u7684\u76ee\u5f55<\/p>\n
useradd-gftp-d\/opt\/lampp\/htdocs\/web1-s\/in\/nologinweb1<\/p>\n
\u8fd9\u6837\u5c31\u6dfb\u52a0\u4e86\u4e00\u4e2aftp\u7ec4\u7684\u7528\u6237web1\uff0c\u4e3b\u76ee\u5f55\u662f\/opt\/lampp\/htdocs\/web1\u65e0\u767b\u9646\u6743\u9650\uff08\u53ea\u5bb9\u8bb8\u901a\u8fc7ftp\u767b\u9646\uff09\uff0c\u521b\u5efa\u7528\u6237\u7684\u65f6\u4faf\u4f1a\u751f\u6210\u4e3b\u76ee\u5f55\uff0c\u4e0d\u8981\u81ea\u5df1\u521b\u5efa\/opt\/lampp\/htdocs\/web1\uff0c<\/p>\n
\u4e4b\u540e\u5c31\u662fpasswdweb1\u4e3a\u5176\u8bbe\u7f6e\u5bc6\u7801<\/p>\n
\u5047\u5982\u7528\u6237\u6bd4\u7fa1\u914d\u548c\u8f83\u591a\uff0c\u4e0a\u767e\u4e2a\u8fd9\u6837\u5b50\u5c31\u9700\u5356\u4eff\u8981\u7528\u5230\u865a\u62df\u7528\u6237\u4e86\uff0c\u865a\u62df\u7528\u6237\u7684\u8bbe\u7f6e\u5c31\u6ca1\u8fd9\u4e48\u7b80\u5355\u4e86\uff0c\uff0c\u5230\u7f51\u5144\u76ef\u4e0a\u627e\u627e\u76f8\u5e94\u7684\u6587\u7ae0\u5427\u3002<\/p>\n
linux\u6ca1\u5fc5\u8981\u914d\u7f6eFTP\u73af\u5883\u7684<\/p>\n
linux\u8bbe\u7f6eftp\u4e3b\u76ee\u5f55\u7684\u4ecb\u7ecd\u5c31\u804a\u5230\u8fd9\u513f\u5427\uff0c\u8c22\u8c22\u4f60\u82b1\u65f6\u95f4\u9605\u8bfb\u672c\u7ad9\u5185\u5bb9\uff0c\u66f4\u591a\u5173\u4e8elinux\u8bbe\u7f6eftp\u4e3b\u76ee\u5f55,Linux\u600e\u4e48\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\uff1f,linux\u4e0b\u8bbe\u7f6e\u7528\u6237\u767b\u5165FTP\u670d\u52a1\u5668\u65f6\uff0c\u6240\u5728\u7684\u76ee\u5f55,linux\u4e0bXampp\u4e2dftp\u7684\u914d\u7f6e\u95ee\u9898\u7684\u4fe1\u606f\u522b\u5fd8\u4e86\u5728\u672c\u7ad9\u8fdb\u884c\u67e5\u627e\u5594\u3002<\/p>\n
\u53f0\u6e7e\u670d\u52a1\u5668\u9996\u9009\u540e\u6d6a\u4e91\uff0c2H2G\u9996\u670810\u5143\u5f00\u901a\u3002<\/p>\n
\u540e\u6d6a\u4e91\uff08\uff09\u63d0\u4f9b\u7b80\u5355\u597d\u7528\uff0c\u4ef7\u94b1\u539a\u9053\u7684\u65b0\u52a0\u5761\/\u9a6c\u6765\u897f\u4e9a\u4e91\u670d\u52a1\u5668\u548c\u72ec\u7acb\u670d\u52a1\u5668\u3002IDC+ISP+ICP\u8d44\u8d28\u3002ARIN\u548cAPNIC\u4f1a\u5458\u3002\u6210\u719f\u6280\u672f\u56e2\u961f15\u5e74\u884c\u4e1a\u7ecf\u9a8c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"
\u4f8b\u5982\uff0c\u5982\u679cFTP\u7528\u6237\u7684\u7528\u6237\u540d\u4e3aftpuser\uff0c\u5219\u5176\u4e3b\u76ee\u5f55\u5c06\u4e3a\/var\/ftp\/ftpuser\u3002linux\u4e0b\u8bbe\u7f6e\u7528\u6237\u767b\u5f55FTP\u670d\u52a1\u5668\u65f6\uff0c\u6240\u5728\u7684\u76ee\u5f55\u5728linux\u4e2d\u5206\u522b\u521b\u5efa\u5e10\u53f7\uff0c\u5e76\u4e14\u628a\u5e10\u53f7\u4e3b\u76ee\u5f55\u8bbe\u7f6e\u4e3a\u76f8\u5173\u7684\u76ee\u5f55\u8bbe\u7f6eftp\u4e3b\u76ee\u5f55,Linux\u5982\u4f55\u8bbe\u7f6eFTP\u4e3b\u76ee\u5f55\uff1f<\/p>\n","protected":false},"author":1,"featured_media":295087,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[988],"tags":[4237,3291,4238,5057,1624],"class_list":["post-295086","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tougao","tag-frj","tag-lfxb","tag-proftpd","tag-Pure-FTPd","tag-v-10"],"acf":[],"_links":{"self":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/295086","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/comments?post=295086"}],"version-history":[{"count":0,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/posts\/295086\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media\/295087"}],"wp:attachment":[{"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/media?parent=295086"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/categories?post=295086"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lrxjmw.cn\/wp-json\/wp\/v2\/tags?post=295086"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}