Find code and diagrams at:
UFW is a simple firewall application that is included with Ubuntu nd can be installed on other distributions of Linux.
Note: For the demonstrations to work you may need to change settings or hardware configurations within your virtualization software. I had to connect my host machine to a hard word connection for Rules for specific IP Addresses to work.
sudo ufw status – shows current status of ufw
sudo ufw enable – Enables ufw firewall
By default ALL incoming traffic is blocked
sudo ufw disable – Disables ufw
sudo ufw status verbose – Shows all Rules currently configured for ufw
sudo ufw allow 21 – Allows specific port
sudo ufw allow ssh – Allows ports for a specific service
sudo ufw status numbered – Shows rules in numbered order so that you can delete specific rules
sudo ufw delete 1 – Deletes rule based on number
sudo ufw allow from 192.168.1.2 – Allows traffic from a specific IP address to all ports
sudo ufw allow from 192.168.1.0/24 – Allows traffic from a subnet to all ports
sudo ufw allow from 192.168.1.2 to any port 22 – Allows traffic from a specific IP address to a specific port
sudo ufw allow from 192.168.1.0/24 to any port 22 – Allows traffic from a subnet to a specific port
sudo ufw reset – Deletes all rules and disables ufw
Nguồn: https://ftlinuxcourse.com
Xem thêm bài viết khác: https://ftlinuxcourse.com/lap-trinh-linux
Xem thêm Bài Viết:
- Trải nghiệm mới hay ho với hướng dẫn cài Mac Os trên vmware
- Bật mí cách cài đặt ssl miễn phí lên Let’s Encrypt
- Tuyệt chiêu tạo usb boot kali linux đơn giản dành cho bạn
- Hướng dẫn chi tiết từ A – Z các bước cài đặt Python trên Windows 10
- Bật mí quy trình cài đặt Kali Linux trên Vmware đúng chuẩn và chi tiết
Allowing only a specific ip-address to access does not work if the client is using DHCP right?
awesome video, subscribed!
Very informative video and Thank you so much for Adding those UFW commands on the description, It really make life lot easier.
sometimes the ftp service ufw doesn't let the ftp work and then when i write "ufw allow proto ftp to any port 21" it returns with "ERROR: Unsupported protocol 'ftp'". Is there a solution to my problem and why is this happening?
Hey eli it's amazing that u made the learning new technologies much in ease manner, y don't u prefer doing videos about RPA(Robotic Process Autonation)
3:12 – I want my specific login to access SSH (and FTP) regardless of my IP address (I want to access the server from other systems without granting the system specifically access), but FTP and SSH have thus far thwarted my attempts to log in from outside my LAN. :-
Thank you so much for this series. I've learned a ton so far.
Great tutorial, Sir!
Thanks sir , your MCSC course was very worthy for me and God bless you
'impore-TUNT' 🙂 (Other 'Eli-isms' – industry = INN-doss-tree) 🙂
It's so simple rules like dog commands.
my system is 10 years old should I start fresh to use this Linux