Skip to content

Gpetto - portscan the local machine, report to syslog and shutdown the interface if needed

License

Notifications You must be signed in to change notification settings

MatthewBuchananAstley/Gpetto

Repository files navigation

OpenSSF Scorecard

Gpetto

Nmap scan the local machine, report any surprising open ports to syslog and shutdown the interface if needed.

Installation

The script can be installed by cloning the github repository:

$git clone https://github.com/MatthewBuchananAstley/Gpetto.git

Or via the excellent ubuntu snap software distribution system:

$snap install gpetto --devmode --edge

Usage

./gpetto 

For your information: the utp port scanning is only available as the root user

Configuring exceptions to the rule

Services that need to have an open port can be defined in gpetto_allowlist.conf. The line that appears in the nmap scan output can be used. For instance:

127.0.0.1 25/tcp open  smtp

gpetto_allowlist.conf goes in /etc/security/gpetto_allowlist.conf

Gpetto scan at boot time

The systemd service file to have the script check the system at boot time:

gpetto.service goes in /lib/systemd/system/gpetto.service

systemctl enable gpetto

or manually create the symlink in:

cd /etc/systemd/system/default.target.wants ;
ln -s /lib/systemd/system/gpetto.service gpetto.service

Versions

gpetto v1.0.0

About

Gpetto - portscan the local machine, report to syslog and shutdown the interface if needed

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages