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.

最新文章

  1. FineUI(开源版)v4.2.2发布(8年125个版本,官网示例突破300个)!
  2. PHPCMS开启伪静态和织梦开启伪静态的优缺点比较
  3. Delphi之DLL知识学习3---为什么要使用DLL
  4. 『备忘』HttpWebRequest 在 POST 提交时, 标头(Headers)丢失原因
  5. 一个很好的Delphi博客
  6. I/O系统,多线程、图形用户界面编程
  7. chromium的部署工具depot_tools和gclient
  8. 帝国cms7.0跳过[会员注册类型]这步的方法
  9. android 34 ListView进阶
  10. 经典排序算法及python实现
  11. 关于iOS性能调优
  12. JDBC 异常简介 jDBC简介(六)
  13. JAVA经典算法50题(转)
  14. 基于MNIST数据集使用TensorFlow训练一个没有隐含层的浅层神经网络
  15. luogu P3243 [HNOI2015]菜肴制作
  16. NeoFinder for Mac(增强型文件管理工具)破解版安装
  17. 20155326 第12周课堂实践总结(二)String类和Arrays类的学习
  18. oracle 将字符串转化为数值型to_number()
  19. 【转】如何在Mac上卸载Java及安装Java
  20. 有向图与无向图的合并操作区别D(递归与并查集)

热门文章

  1. 服务端缓存HttpRuntime.Cache的使用
  2. 使用grunt运行hintjs任务
  3. hibernate的dao操作不能提交到数据库问题的解决
  4. 查找并绘制轮廓[OpenCV 笔记XX]
  5. 实习笔记-2:sql 分组不一定要group by
  6. ASP.NET取得Request URL的各个部分
  7. linux修改时间 时区
  8. CentOS上无法识别NTFS格式分区的解决方法
  9. js中的in-for循环
  10. 不同的extend 在调用构造函数时不同的写法