跳至主要内容

vsftpd.conf设置备忘


  • listen=YES    表示vsftpd以stand alone方式来唤醒
  • anonymous_enable=NO    不允许匿名登录
  • local_enable=YES    /etc/passwd以内帐号才能以实体用户方式登录
  • write_enable=YES    允许用户上传数据
  • local_umask=022    设置权限022,建立新目录与文件的权限
  • user_sub_token=$USER  Automatically generate a home directory for each virtual user, based on a template
     
  • local_root=/home/www    更改主目录为....
    • 也有用local_root=/home/www/$USER     即名称可以随虚拟用户名字改变
  • chroot_local_user=YES    限制用户在用户主目录之内,chroot user and lock down to home directory
  • chroot_list_enable=YES    启用chroot写入列表功能,与下面文件相关
  • chroot_list_file=/etc/vsftpd/chroot_list    设置虚拟用户限制
  • allow_writeable_chroot=YES    In order to allow local users to write
  • hide_ids=YES     hide ids from user

#virutal user settings


  • guest_enable=YES    任何实体帐号均被假设为guest,activates virtual users(开启虚拟用户)
  • virtual_use_local_privs=YES     Virtual users will use the same privileges as local users
  • pam_service_name=vsftpd_virtual    PAM模块的名称
  • nopriv_user=vsftpd    vsftpd默认以vsftpd作为此服务执行者,即便入侵,权限在此
  • guest_username=vsftpd   虚拟用户对应的系统用户,实际在Linux中操作的是vsftpd
  • hide_ids=YES    
  • user_config_dir=/etc/vsftpd/user     为虚拟用户进入的主文件夹,规定可执行命令
  • pasv_enable=YES    支持数据流的被动式连接
  • pasv_min_port=3000     最小端口
  • pasv_max_port=3100     最大端口

#max conn

  • max_clients=20    设置同一时间最多多少可以连接
  • max_per_ip=10    同一IP同一时间多少连接
  • connect_timeout=30    主动式连接模式下,30秒内客户端不回应则断开
  • accept_timeout=30    被动式模式下,等待客户端30秒
  • idle_session_timeout=30    30秒内无命令,强制脱机

#log

  • xferlog_enable=YES    上传和 下载记录都会被记录
  • xferlog_file=/var/log/xferlog    日志文件文件名
  • vsftpd_log_file=/var/log/vsftpd.log    特色log文件
  • dual_log_enable=YES    具有vsftpd独特日志文件格式

#建议加上的内容

  • use_localtime=YES


 案例学习

 配置手册:VSFTPD.CONF

另外一个比较好的帖子,linux培训学习--FTP服务配置
亮点
  • 源码编译vsftpd学习




Popular posts from 产品随想的博客

《Elon Musk》Chapter 1 - 10

To anyone I’ve offended, I just want to say, I reinvented electric cars and I’m sending people to Mars in a rocket ship. Did you think I was also going to be a chill, normal dude? ——Elon Musk, Saturday Night Live, May 8, 2021 PROLOGUE: Muse of Fire Near the end of the first week, the boys were divided into two groups and told to attack each other. “It was so insane, mind-blowing,” Musk recalls. Every few years, one of the kids would die. The counselors would recount such stories as warnings. “Don’t be stupid like that dumb fuck who died last year,” they would say. “Don’t be the weak dumb fuck.” 这种氛围有毒 “I realized by then that if someone bullied me, I could punch them very hard in the nose, and then they wouldn’t bully me again. They might beat the shit out of me, but if I had punched them hard in the nose, they wouldn’t come after me again.” 勇于挑战,哈哈哈 In the emergency room, when they were preparing to stitch him up, he resisted being treated until he was promised that the dog would not ...

Steve Jobs: `There's Sanity Returning', 1998

Nobody can doubt the charisma of Steven P. Jobs. The interim CEO of Apple Computer Inc., who returned to the company last July after his ignominious 1985 ouster, has brought back his legendary vision, impatience, and infectious passion for the Macintosh. Jobs spoke to Business Week Correspondent Andy Reinhardt in Apple's stark, fourth-floor boardroom, just after the company rolled out its new software strategy on May 11. Note: This is an extended, online-only version of the Q&A that appears in the May 25, 1998, issue of Business Week. Q: Now that you've introduced the new, bold-looking iMac, are you going to do some radically different products? A: There's a lot of talk about such things -- about handhelds, set-top boxes. A lot of computer companies have been searching for a consumer product. My view is that the personal computer has been the most successful consumer product of the last 10 years. What we have to do, what the industry stopp...

罗伯特·艾格 创始人肖像计划 <​Ep.2>

Link 罗伯特·艾格 创始人肖像计划 <​Ep.2>   https://zhuanlan.zhihu.com/p/127042313 Note 这个男人,过去十五年时间,几乎不接受采访,只是静悄悄的,花掉了1000亿美金。 ——这个男人,太厉害了...... 艾格跳槽去了ABC,从最底层的小导播做起,一辈子46年职业生涯,再也没有跳过槽。这46年里的最后15年,他升任CEO,做出了惊天动地的大事情。 今年,艾格退休写了自传,起名字叫《The Ride of a Lifetime》,我想了半天,这书名有点拽,只能翻译成《一辈子就要干一票大的》,笔者一介俗人,但愿艾总不要介意,哈哈。 ——《一辈子的旅途》,感觉会更契合些?哈哈哈 在艾总的这本《干一票》里,我读来读去,总是找不到他是怎么升到副总裁的——升到副总裁之后的一步步到CEO倒是写的很细致,看来大佬写自传也为自己讳,不愿意提太多当年勇。 ——Interesting 地表最强二人组(Tom Murphy和Dan Burke)最牛逼的成就就是不出让股权(Equity)的资本并购。一路用自由现金流加发行债券来进行收购,85年的时候举债30亿,配合巴菲特的5亿美金,小鱼吞大鱼,一把吃掉了当时比自己体量大得多的ABC电视台。他们俩的管理特点是极端节俭,冷血砍成本(不禁让人想到贝索斯),收购完成后,直接开掉1500员工、干掉高管电梯、高管餐厅、全员改坐经济舱,甚至于把曼哈顿总部的办公室卖了,换来1.75亿美金。三年多就把当时举的债还完。 作为巴菲特一辈子最推崇的企业家组合,Tom和Dan还有一个特点:放权。他们俩极为谨慎用人,但是一旦选中,就破格提拔,尚方宝剑交出,让牛人干大事。没干多久,俩人就接二连三的退休了,艾格你年轻,你来当总裁! 艾格原话是这么写的:“我心里也有预期,感觉最后总裁的位置是我的,但是确实没想到来的那么快”。按照网友的话就是“一脸懵逼”。 艾格有个特点,他性格是标准的外柔内刚,外圆内方。他不强势,不豪夺,永远不是人群中最聒噪的那位。他能等,在大都会(CapCities)花六年时间做三把手,等到二把手退休,再等好几年到一把手退休,最终上位 ——耐得住寂寞,受得住繁华 21世纪出头即提出战略: 第一句:我们只做高质量品牌视频 第二句:全力拥抱技术而不是对抗 第三句:全球化 大佬的出手案例...

进入双拼的世界

──小鹤双拼官方记忆口诀诗一首 Kuai ing Liang uang Ruan Cao Zou , T ue Qiu Yun Wei Jan Mian 快 迎 两 王 软 草 走 ,特 约 秋 云 为 见 面 Xia ua Song iong ShU ChI ZhVi , Geng Dai Bin Niao Fen Pie Hang 夏 娃 怂 恿 书 痴 追,更 待 斌 鸟 分 撇 航 注释: 如上,一和三两句的前四个字为一个大写字母代表了两个字的拼音   T ue各取拼音谐音为特约,Jan取英文谐音为见,其余均是一个大写字母代表一个字的拼音   斌鸟是一种鸟,分撇一词是分离之意,故斌鸟分撇航意为鸳鸯各自飞。   译文: 一个地方官笑着说:“快欢迎两位王爷到软草原走一走,我为两位特意约了秋云姑娘来见面”,   夏娃听见了,怂恿暗恋秋云的书痴快去追,此时不追,更待何时?难道要等鸳鸯各自飞? 记住后,每按一个键,都得停顿几秒,不过熟悉了字母和声韵母之间的对应关系。 双拼练习网站推荐: https://linci.co/sp/ 

初识PAM

Pluggable Authentication Modules for Linux 可插拨认证模块 用户访问服务器,服务程序将请求发送至PAM模块

The Three Faces Of Steve Jobs, Brent Schlender, 1998 Fortune

(FORTUNE Magazine) – Well into the conversation with FORTUNE that you're about to read, Steve Jobs, the once and interim CEO of Apple Computer, professes to feel, at the wizened age of 43, no different from when he was a frisky 17-year-old. True to form, he contradicts himself a little later, confessing to be "an old man now." Those comments reveal as much about why Jobs has been able to pull off his prestidigital revival of Apple--his first and still greatest creation--as do his observations on his business strategies and actions of the past year. Here's why. Jobs is most effective as a businessman and leader when he invokes the pathos and gestalt of his generation. He is, after all, a child of the 1960s--you're still likely to find him barefoot in the office, and for breakfast he eats granola doused in apple juice. Yet Jobs is also a mature baby-boomer, with an impressive if offbeat store of business experience, plus the typical worries that go with...