Skip to content

Instantly share code, notes, and snippets.

@mon0theist
Created July 25, 2020 08:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mon0theist/471a4df8c8a1f6fbe4dbbcee7de7ed5a to your computer and use it in GitHub Desktop.
Save mon0theist/471a4df8c8a1f6fbe4dbbcee7de7ed5a to your computer and use it in GitHub Desktop.
Samba App Profile for UFW

/etc/ufw/applications.d/Samba

[Samba]
title=LanManager-like file and printer server for Unix
description=The Samba software suite is a collection of programs that implements the SMB/CIFS protocol for unix systems, allowing you to serve files and printers to Windows, NT, OS/2 and DOS clients. This protocol is sometimes also referred to as the LanManager or NetBIOS protocol.
ports=137,138/udp|139,445/tcp

Once you have defined your application file tell ufw to reload the application definitions with:

ufw app update Samba

Use it with:

ufw allow Samba
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment