http://twincreations.co.uk/change-default-ftp-port-for-vsftp/

http://www.cnblogs.com/kuliuheng/p/3209674.html

http://www.cnblogs.com/kuliuheng/p/3209744.html

In a bid to secure our server for a production environment, we need to secure FTP as a vital step. FTP is one of the least secure and most exploited standard protocols on production servers today. Many hosting providers now take additional steps to secure FTP for this very reason.

I’m using VSFTP (Very Secure FTP). Let’s change the default FTP port in a bid to improve our server security. We need to edit the/etc/vsftpd/vsftpd.conf file.

 
 
1
$ vi /etc/vsftpd/vsftpd.conf

First, we disable the connect_from_port option and specify a new data port (typically one port number lower than our connection port):

 
 
1
2
3
4
# set this to NO...
connect_from_port_20=NO
# define new data port (one number lower than connection port)
ftp_data_port=1233

Now we add or edit the following lines to change the port:

 
 
1
2
# non-standard FTP port
listen_port=1234

Don’t be tempted to use 2121! I’m sure that was hard to come up with, but these crackers are smart folks  Also, I would recommend you use a port higher than 1024 and make sure it is not in use by something else.

Once you have edited the file, save and close it and restart the service for changes to take effect:

 
 
1
2
3
/etc/init.d/vsftpd restart
// OR
service vsftpd restart

Done! We changed the port and greatly upped our server security in the process. Don’t forget to change firewall rules for your new port, and secure port 21.

CHANGE DEFAULT FTP PORT FOR VSFTP的更多相关文章

  1. XE: Changing the default http port

    Oracle XE uses the embedded http listener that comes with the XML DB (XDB) to serve http requests. T ...

  2. JDK Environment Variable And Change default JDK

    Environment Variable : change(import) /etc/bashrc export JAVA_HOME=/software/jdk1.8.0 export PATH=$J ...

  3. How to Change Default Web ADI Upload Parameters for FlexField Import / Validation

    How to Change Default Web ADI Upload Parameters for FlexField Import / Validation (文档 ID 553345.1) 转 ...

  4. Change default network name (ens33) to old “eth0” on Ubuntu 18.04 / Ubuntu 16.04

    Change default network name (ens33) to old “eth0” on Ubuntu 18.04 / Ubuntu 16.04 By Raj Last updated ...

  5. [转]how can I change default errormessage for invalid price

    本文转自:http://forums.asp.net/t/1598262.aspx?how+can+I+change+default+errormessage+for+invalid+price I ...

  6. windows 10 change default program bug

    windows 10 change default program bug https://www.isumsoft.com/windows-10/how-to-change-or-set-defau ...

  7. Why was 80 Chosen as the Default HTTP Port and 443 as the Default HTTPS Port?

    https://www.howtogeek.com/233383/why-was-80-chosen-as-the-default-http-port-and-443-as-the-default-h ...

  8. linux 安装SSH Server + FTP Server(openssh-server + vsftp)

    openssh-server (推荐. 一般ssh,ftp 都是单独的,但是这个包含2个) 默认ubuntu 已经安装了, ssh client ,ftp client dpkg -l | grep ...

  9. FTP基础知识 FTP port(主动模式) pasv(被动模式) 及如何映射FTP

    您是否正准备搭建自己的FTP网站?您知道FTP协议的工作机制吗?您知道什么是PORT方式?什么是PASV方式吗?如果您不知道,或没有完全掌握,请您坐下来,花一点点时间,细心读完这篇文章.所谓磨刀不误砍 ...

随机推荐

  1. WEB前端优化一些经验技巧

    引言: 1. 慢的页面可能会网站失去更多的用户. 2. 慢500ms意味着20%的用户将放弃访问(google) 3. 慢100ms意味着1%的用户将放弃交易(amazon) 前段时间偶然看到网上的两 ...

  2. Spring引用测试

    上下文 using System; using Spring.Core; using Spring.Aop; using System; using Spring.Core; using Spring ...

  3. linux下设置mysql数据库字符集utf8

    mysql中文乱码解决方法:将mysql数据库编码统一utf8 查看数据库编码: show variables like 'character%'; 编辑/etc/my.cnf [mysql] def ...

  4. db2相关问题及解决方法

    DB2相关问题及解决方法: 一.DB2中的代码页(codepage)问题. DB2备份时发生过代码页错误的问题,修改代码页后备份正常,但创建数据库时又发生代码页的错误.这是DB2服务器使用的代码页配置 ...

  5. ASP.NET在IIS7中如何更改网站的.net framework框架版本

    IIS7安装好以后使用了.net 2.0 framework框架,经过折腾发现如下方法可以更改框架版本,从而可以部署使用其他版本框架开发的网站 方法一:建立网站时设置.net框架版本 方法二:对于已经 ...

  6. C#变量初始化问题:字段初始值无法引用非静态字段、方法或属性

    http://www.cnblogs.com/bluestorm/p/3432190.html 问题:字段初始值设定项无法引用非静态字段.方法或属性的问题 下面代码出错的原因,在类中定义的字段为什么不 ...

  7. TortoiseSVN本地代码版本控制设置步骤。

    1.下载安装TortoiseSVN客户端. 2.在某个盘创建空的文件夹作为项目代码的版本库.在空的文件夹内部右键鼠标TortoiseSVN->Create repository here 3.在 ...

  8. vue防止闪烁

    v-text也可以 转意的话使用v-html <style> [v-clock]{ display:none } <style> <span>{{msg}}< ...

  9. (CodeForces 558C) CodeForces 558C

    题目链接:http://codeforces.com/problemset/problem/558/C 题意:给出n个数,让你通过下面两种操作,把它们转换为同一个数.求最少的操作数. 1.ai = a ...

  10. MFC通过ADO操作Access数据库

    我在<VC知识库在线杂志>第十四期和第十五期上曾发表了两篇文章——“直接通过ODBC读.写Excel表格文件”和“直接通过DAO读.写Access文件”,先后给大家介绍了ODBC和DAO两 ...