0

I have an app deployed on DigitalOcean

When I run ufw status

this is the output,

Status: active

To                         Action      From
--                         ------      ----
Nginx Full                 ALLOW       Anywhere
5432/tcp                   ALLOW       Anywhere
22/tcp                     LIMIT       Anywhere
53                         ALLOW       Anywhere
25/tcp                     ALLOW       Anywhere
587/tcp                    ALLOW       Anywhere
993/tcp                    ALLOW       Anywhere
995/tcp                    ALLOW       Anywhere
4190/tcp                   ALLOW       Anywhere
80/tcp                     ALLOW       Anywhere
443/tcp                    ALLOW       Anywhere
25                         ALLOW       Anywhere
587                        ALLOW       Anywhere
Nginx Full (v6)            ALLOW       Anywhere (v6)
5432/tcp (v6)              ALLOW       Anywhere (v6)
22/tcp (v6)                LIMIT       Anywhere (v6)
53 (v6)                    ALLOW       Anywhere (v6)
25/tcp (v6)                ALLOW       Anywhere (v6)
587/tcp (v6)               ALLOW       Anywhere (v6)
993/tcp (v6)               ALLOW       Anywhere (v6)
995/tcp (v6)               ALLOW       Anywhere (v6)
4190/tcp (v6)              ALLOW       Anywhere (v6)
80/tcp (v6)                ALLOW       Anywhere (v6)
443/tcp (v6)               ALLOW       Anywhere (v6)
25 (v6)                    ALLOW       Anywhere (v6)
587 (v6)                   ALLOW       Anywhere (v6)

I need to close all extra ports and secure my server.

What should I do about this?

Any help would be appreciated as I am new in the world of hosting.

danish2694
  • 199
  • 3
  • 16

1 Answers1

0

Remove the unwanted rules with the delete command

sudo ufw delete allow 25/tcp

See Linuxize How to List and Delete UFW Firewall Rules

Beppe C
  • 11,256
  • 2
  • 19
  • 41