10 ຄຳ ຖາມ ສຳ ລັບການ ສຳ ພາດ VsFTP ລ່ວງ ໜ້າ - ພາກ II


ພວກເຮົາປະທັບໃຈກັບ ຄຳ ຕອບທີ່ພວກເຮົາໄດ້ຮັບໃນບົດຂຽນສຸດທ້າຍຂອງພວກເຮົາ. ບ່ອນທີ່ພວກເຮົາໄດ້ ນຳ ສະ ເໜີ 10 ຄຳ ຖາມທີ່ດີເລີດກ່ຽວກັບອະນຸສັນຍາການໂອນໄຟລ໌ທີ່ປອດໄພຫຼາຍ. ສືບຕໍ່ບົດຄວາມ ສຳ ພາດ VSFTP ພວກເຮົາມາຮອດນີ້ ນຳ ສະ ເໜີ ທ່ານອີກ 10 ຄຳ ຖາມ ສຳ ພາດລ່ວງ ໜ້າ ເຊິ່ງແນ່ນອນຈະຊ່ວຍທ່ານໄດ້.

<

  • 10 ຄຳ ຖາມ ສຳ ລັບການຕອບ ສຳ ພາດ Vsftp ຂັ້ນພື້ນຖານ - ສ່ວນທີ I
  • ກະລຸນາສັງເກດ vsftpd.conf file ຖືກໃຊ້ເພື່ອຄວບຄຸມດ້ານຕ່າງໆຂອງການຕັ້ງຄ່າຕາມທີ່ໄດ້ ກຳ ນົດໄວ້ໃນບົດຄວາມນີ້. ໂດຍຄ່າເລີ່ມຕົ້ນ, vsftpd ຄົ້ນຫາເອກະສານການຕັ້ງຄ່າພາຍໃຕ້ /etc/vsftpd/vsftpd.conf. ເຖິງຢ່າງໃດກໍ່ຕາມ, ຮູບແບບເອກະສານແມ່ນງ່າຍດາຍຫຼາຍແລະມັນມີ ຄຳ ເຫັນຫຼື ຄຳ ແນະ ນຳ. ສາຍ ຄຳ ເຫັນເລີ່ມຕົ້ນດ້ວຍ '#' ຖືກລະເວັ້ນແລະສາຍການຊີ້ ນຳ ມີຮູບແບບຕໍ່ໄປນີ້.

    option=value

    ກ່ອນທີ່ພວກເຮົາຈະເລີ່ມຕົ້ນ ຄຳ ຖາມແລະ ຄຳ ຕອບທີ່ໄດ້ອະທິບາຍດີຂອງພວກເຮົາພວກເຮົາຢາກຕອບ ຄຳ ຖາມທີ່ວ່າ "ໃຜຈະໄປເຂົ້າ ສຳ ພາດ FTP?". ດີບໍ່ມີໃຜ. ບາງທີບໍ່ມີໃຜທີ່ຈະເຂົ້າຮ່ວມການ ສຳ ພາດ FTP. ແຕ່ພວກເຮົາ ກຳ ລັງ ນຳ ສະ ເໜີ ຄຳ ຖາມທີ່ສະຫລາດກ່ຽວກັບຫົວຂໍ້ເພື່ອຮັກສາວິທີການທີ່ເປັນລະບົບເພື່ອວ່າໃນການ ສຳ ພາດໃດໆ, ທ່ານຈະບໍ່ໄດ້ຮັບ ຄຳ ຖາມ ໃໝ່ ທີ່ທ່ານບໍ່ຮູ້ກ່ຽວກັບຫົວຂໍ້/ຫົວຂໍ້ໃດ ໜຶ່ງ ທີ່ພວກເຮົາໄດ້ກ່າວເຖິງນີ້.

    ເປີດເອກະສານ ‘/etc/hosts.deny’.

    # vi /etc/hosts.deny

    ຕິດຢູ່ແຖວຕໍ່ໄປນີ້ຢູ່ທາງລຸ່ມຂອງເອກະສານກັບທີ່ຢູ່ IP ທີ່ທ່ານຕ້ອງການທີ່ຈະສະກັດການເຂົ້າເຖິງ FTP.

    #
    # hosts.deny    This file contains access rules which are used to
    #               deny connections to network services that either use
    #               the tcp_wrappers library or that have been
    #               started through a tcp_wrappers-enabled xinetd.
    #
    #               The rules in this file can also be set up in
    #               /etc/hosts.allow with a 'deny' option instead.
    #
    #               See 'man 5 hosts_options' and 'man 5 hosts_access'
    #               for information on rule syntax.
    #               See 'man tcpd' for information on tcp_wrappers
    #
    vsftpd:172.16.16.1

    ເພື່ອສະກັດການເຂົ້າເຖິງ FTP ຂອງທີ່ຢູ່ IP ໂດຍສະເພາະ, ເພີ່ມກົດລະບຽບການເລື່ອນລົງຕໍ່ໄປນີ້ໃຫ້ກັບລະບົບຕ່ອງໂສ້ iptables INPUT.

    iptables -A RH-Firewall-1-INPUT -p tcp -s 172.16.16.1 -m state --state NEW -m tcp --dport 21 -j DROP
    # Add this line to enable secured SSL connection to anonymous users.
    allow_anon_ssl=YES
    # Uncomment this to enable any form of FTP write command.
    write_enable=YES
    # Uncomment this if you want the anonymous FTP user to be able to create
    # new directories.
    anon_mkdir_write_enable=YES
    # Add this line to enable read only permission to anonymous users.
    allow_anon_ssl=YES
    # Add this line to chmod all anonymous uploads automatically.
    chmod_enable=YES
    # Add this line to disable directory listing.
    dirlist_enable=NO
    # Add this line to maintain session logins.
    session_support=YES
    # Add this line to display directory listing in local time zone.
    usr_localtime=YES
    # Add this line to limit the ftp transfer rate.
    anon_max_rate=0 # 0 means unlimited
    # Add this line to set the ftp timeout session.
    idle_session_timeout=300

    ດຽວນີ້ ໝົດ ແລ້ວ. ພວກເຮົາຈະຂຽນບົດຄວາມຕໍ່ໄປໃນໄວໆນີ້, ຈົນກວ່າຈະຕິດຕາມແລະເຊື່ອມຕໍ່ແລະຢ່າລືມສະ ເໜີ ຄຳ ຄິດເຫັນທີ່ມີຄຸນຄ່າຂອງພວກເຮົາໃນພາກ ຄຳ ເຫັນຂອງພວກເຮົາ.