• ubuntu ufw


        *

          First, ufw needs to be enabled. From a terminal prompt enter:

          sudo ufw enable

        *

          To open a port (ssh in this example):

          sudo ufw allow 22

        *

          Similarly, to close an opened port:

          sudo ufw deny 22

        *

          To remove a rule, use delete followed by the rule:

          sudo ufw delete deny 22

        *

          It is also possible to allow access from specific hosts or networks to a port. The following example allows ssh access from host 192.168.0.2 to any ip address on this host:

          sudo ufw allow proto tcp from 192.168.0.2 to any port 22

          Replace 192.168.0.2 with 192.168.0.0/24 to allow ssh access from the entire subnet.
        *

          ufw can be disabled by:

          sudo ufw disable

  • 相关阅读:
    IBinder介绍
    Android组成部分
    Android中handler,looper与messageQueue的代码解析
    JS
    设计模式
    冒泡排序
    战斗逻辑
    mongo数据库基础
    JS闭包
    c/c++
  • 原文地址:https://www.cnblogs.com/greencolor/p/2161320.html
Copyright © 2020-2023  润新知