해피 투게더

omv 로 세팅한 proftpd 설정 본문

장난감

omv 로 세팅한 proftpd 설정

보아요 2017. 7. 2. 19:50

proftpd 세팅


nano /etc/proftpd/proftpd.conf


Include /etc/proftpd/modules.conf
LoadModule mod_vroot.c
UseIPv6 on
ServerName "IOMEGA-EZ"
ServerType standalone
DeferWelcome on
MultilineRFC2228 on
DefaultServer on
ShowSymlinks on
DisplayChdir .message true
ListOptions "-l"
MaxInstances 30
DenyFilter \*.*/
User proftpd
Group nogroup
Umask 000 000
PersistentPasswd off
TimesGMT off
AllowOverwrite on
AuthOrder mod_auth_pam.c* mod_auth_unix.c
DefaultTransferMode ascii
#SystemLog /var/log/proftpd/proftpd.log
<IfModule mod_facl.c>
  FACLEngine on
</IfModule>
<IfModule mod_quotatab.c>
  QuotaEngine off
</IfModule>
<IfModule mod_ratio.c>
  Ratios off
</IfModule>
<IfModule mod_delay.c>
  DelayEngine on
</IfModule>
<IfModule mod_ctrls.c>
  ControlsEngine on
  ControlsMaxClients 2
  ControlsLog /var/log/proftpd/controls.log
  ControlsInterval 5
  ControlsSocket /var/run/proftpd/proftpd.sock
</IfModule>
<IfModule mod_ctrls_admin.c>
  AdminControlsEngine off
</IfModule>
<IfModule mod_vroot.c>
  VRootEngine on
  VRootLog /var/log/proftpd/vroot.log
</IfModule>
Port 21
TransferLog NONE
IdentLookups off
UseReverseDNS off
TimeoutIdle 1200
TimeoutNoTransfer 600
TimeoutStalled 600
DeleteAbortedStores off

MaxConnectionsPerHost 2
<Directory />
  HideFiles (welcome.msg)
</Directory>
<IfModule mod_vroot.c>
  VRootAlias "/srv/dev-disk-by-id-ata-ST31500341AS_9VS3G04B-part1/private" "private"
</IfModule>
<Directory /private>
  <Limit ALL>
    AllowUser OR dad
    DenyAll
  </Limit>
  <Limit READ DIRS>
    AllowUser OR dad
    DenyAll
  </Limit>
</Directory>
<IfModule mod_vroot.c>
  VRootAlias "/srv/dev-disk-by-id-ata-ST31500341AS_9VS3G04B-part1/public" "public"
</IfModule>
<Directory /public>
  <Limit ALL>
    AllowUser OR kids,dad
    DenyAll
  </Limit>
  <Limit READ DIRS>
    AllowUser OR kids,dad
    DenyAll
  </Limit>
</Directory>
<IfModule mod_auth.c>
  DefaultRoot /srv/ftp
  MaxClients 5
  MaxLoginAttempts 1
  RequireValidShell on
  # This option is useless because this is handled via the PAM
  # pam_listfile.so module, so set it to 'off' by default.
  UseFtpUsers off
</IfModule>
<IfModule mod_auth_pam.c>
  AuthPAM on
  AuthPAMConfig proftpd
</IfModule>
<IfModule mod_ban.c>
  BanEngine off
  BanControlsACLs all allow user root
  BanLog /var/log/proftpd/ban.log
  BanMessage Host %a has been banned
  BanTable /var/run/proftpd/ban.tab
</IfModule>
DisplayLogin /srv/ftp/welcome.msg
<IfModule mod_wrap.c>
  TCPAccessFiles /etc/hosts.allow /etc/hosts.deny
  TCPAccessSyslogLevels info warn
  TCPServiceName ftpd
</IfModule>