The Pyra, which has a modified build based on Debian, has systemd.
The Linux Journal, now resurrected, has a nice article about hardening your Linux Installation.
Basically you can run the following command to check what the OS thinks about it's services (you do not need to be root to run this command):
Then you can edit a single service:
and you can re-check with:
Note that there could be old-style services in /etc/init.d/ too; those, if there, need to be handled differently.
If you are not root, put the word "sudo" in front of the command to run it as root. It will ask you your password.
The article comes with an ansible demo. And although you might not be able to run it, the readme tells us a whole lot about what to check for and how to harden services (by adding sandboxing settings, and then re-checking your service):
Next time, we will be talking about open ports and Dutch Tulips (tulpen)
and established connections:
Disclaimer: I do not have my Pyra yet, so I can't check the correct working of the commands posted in this post. But I'm on a Debian system.
The Linux Journal, now resurrected, has a nice article about hardening your Linux Installation.
Systemd Service Hardening | Linux Journal
www.linuxjournal.com
Basically you can run the following command to check what the OS thinks about it's services (you do not need to be root to run this command):
Bash:
root@pyra:~# systemd-analyze security
Then you can edit a single service:
Bash:
root@pyra:~# systemctl edit --full $servicename
and you can re-check with:
Bash:
root@pyra:~# systemd-analyze verify $servicename
Note that there could be old-style services in /etc/init.d/ too; those, if there, need to be handled differently.
If you are not root, put the word "sudo" in front of the command to run it as root. It will ask you your password.
The article comes with an ansible demo. And although you might not be able to run it, the readme tells us a whole lot about what to check for and how to harden services (by adding sandboxing settings, and then re-checking your service):
GitHub - alegrey91/systemd-service-hardening: Basic guide to harden systemd services
Basic guide to harden systemd services. Contribute to alegrey91/systemd-service-hardening development by creating an account on GitHub.
github.com
Next time, we will be talking about open ports and Dutch Tulips (tulpen)
Bash:
root@pyra:~# netstat -tulpn
Bash:
root@pyra:~# netstat -tuwpn
Disclaimer: I do not have my Pyra yet, so I can't check the correct working of the commands posted in this post. But I'm on a Debian system.
Last edited: