PROFTPD的Chroot限制

来源:asp之家 时间:2010-01-02 19:16:00 

PROFTPD.CONF如何改?我要限制不同FTP USER在他自己目录读写,其他目录不可读写.请帮一把巴!!请看一下这个配置文件错在那里:(FTP USER AND FTP GROUP有了,控制目录是 /APP/FTPDIR 允许目录是 /APP/FTPDIR/PEARL ) # # Virtual Hosting Server Configuration # for Frontier Internet Services Limited # (http://www.000.com/) # ServerName "Master Webserver" # # Spawn from inetd? # #ServerType inetd # # or maybe a standalone server... # ServerType standalone # # don't give the server banner until _after_ authentication # DeferWelcome off # # Some basic defaults # Port 21 Umask 002 TimeoutLogin 120 TimeoutIdle 600 TimeoutNoTransfer 900 TimeoutStalled 3600 # # No, I don't think we'll run as root! # User ftp Group ftp

# We want clients to be able to login with "anonymous" as well as "ftp" UserAlias anonymous ftp RequireValidShell no

# # This is a non-customer usable name, (ie they should be connecting via www.{domain}) # not 'hostname'. Therefore let's dump them in a dummy account and wait for them to # scream. # DefaultRoot /app/ftpdir/ # # Performance, let's do DNS resolution when we process the logs... # UseReverseDNS off # # Where do we put the pid files? # #ScoreboardPath /var/run/proftpd # # Logging options # #TransferLog /var/spool/syslog/proftpd/xferlog.legacy # # Some logging formats # #LogFormat default "%h %l %u %t "%r" %s %b" #LogFormat auth "%v [%P] %h %t "%r" %s" #LogFormat write "%h %l %u %t "%r" %s %b" # # Global settings #

DisplayLogin welcome.msg DisplayFirstChdir readme # # having to delete before uploading is a pain ;) # AllowOverwrite yes # # Turn off Ident lookups # IdentLookups off # # Logging # # file/dir access # # ExtendedLog /var/spool/syslog/proftpd/access.log WRITE,READ write # # # Record all logins # # ExtendedLog /var/spool/syslog/proftpd/auth.log AUTH auth # # Paranoia logging level.... # ##ExtendedLog /var/spool/syslog/proftpd/paranoid.log ALL default

# # Deny writing to the base server... #

DenyAll

# -------------------------------------------- # Virtual Servers start here.... # # (Note: this is normally auto generated by a # script written in house). # -------------------------------------------- # # ewftp.ewserver.com. # This is the default server # Gets all the connections for www.{customer.domain}, #

ServerAdmin admin@ewserver.com ServerName "ewMaster FTPserver" MaxLoginAttempts 2 RequireValidShell no # TransferLog /var/spool/syslog/proftpd/xferlog.www MaxClients 50 DefaultServer on #DefaultRoot ~ !staff DefaultRoot /app/ftpdir AllowOverwrite yes

# # No quickly do we kick someone out # TimeoutLogin 120 TimeoutIdle 600 TimeoutNoTransfer 900

DenyAll

User ftp Group ftp UserAlias anonymous ftp

AllowAll

DenyAll

# --------------------------------------------

# --------------------------------------------

# # Block them from doing anything other than reading... # #

AllowAll

FLOATBOAT TOLD ME THIS BELOW,BUT DIDN'T WORK: 修改proftpd.conf,添加DefaultRoot ~ groupname 其中groupname为用户组的名,如添加一个新的用户username,和一个新的组groupname,要将username限制在其主目录内只需要添加上面所说的那条语句到proftpd.conf中即可。切记修改完之后要重新启动proftpd

标签:ftp,服务器
0
投稿

猜你喜欢

  • 打造绿色社区 论坛关键字屏蔽有窍门

    2009-02-05 16:24:00
  • GoDaddy常见问题之Linux主机帐户的绝对路径问题

    2010-04-14 12:50:00
  • 基于XP架设Web和FTP服务器

    2010-04-14 18:00:00
  • 电脑报:网页游戏不再沉默

    2008-05-13 12:08:00
  • 流量的概念

    2007-09-17 17:49:00
  • 在美国Godaddy购买空间支付宝付款图文教程

    2010-03-17 14:25:00
  • 美国主机Godaddy优化后速度超过国内

    2010-04-07 12:47:00
  • 腾讯TT浏览器4.8(589)体验版发布

    2009-09-30 13:51:00
  • 与SEO有关的内容质量

    2007-09-13 18:31:00
  • 微软发布13个安全补丁创纪录 首次波及Win7

    2009-10-14 09:29:00
  • 个人站长打造网站心态之路

    2008-03-24 19:31:00
  • Windows2003服务器安装及设置教程—软件安装与设置篇五—ISAPI_Rewrite组件安装图解

    2010-01-30 13:15:00
  • WindowsIIS6安全保护贴—URL授权全攻略(3)

    2007-09-26 14:18:00
  • 付费可删企业“有害信息” 揭秘“删稿人”黑链条

    2009-10-16 14:53:00
  • 提高网站浏览量的方法

    2007-08-24 13:03:00
  • 新手详解:提高网站流量的常用方法总结

    2009-01-21 10:27:00
  • 通过网上兼职月赚5000以上的经验分享

    2010-05-10 12:33:00
  • 周新宁:中国旅游业网站逐步升温

    2008-04-26 07:17:00
  • 用Windows2008 Server防火墙 确保系统安全

    2009-10-14 14:46:00
  • Linux 下如何利用proftpd构架一个ftp服务器

    2007-10-11 14:52:00
  • asp之家 网站运营 m.aspxhome.com