The Server Message Block protocol controls access to files, like FTP, and access to printers and routers. While developed for Windows, Samba ports it to Unix. SMB uses TCP. Samba and newer NetBIOS systems use port 445, while older versions can use 137, 138, and 139.
With version 3, Samba can participate in an Active Directory domain, and with version 4, can be a domain controller.