User privileges and activity log

Objective:

Define the privileges of each user of the Info360 project and configure the log (logs) of actions taken with administrator permissions.

Privileges per user:

Here’s how the privileges were assigned to each user:

User sudo access Description
super Yeah You can run any command with sudo
major No (full access without sudo) Can run commands as root without prompting for password (set to sudoers)
brayan Yeah Has sudo permissions as a student
alex Yeah Has sudo permissions as a student
angel Yeah Has sudo permissions as a student
operator No I don’t have sudo permissions
technician No I don’t have sudo permissions

Enabling Privilege Usage Logs:

Linux operating systems (Ubuntu, CentOS) already have command activity logging enabled by default with sudo.
The log files are:
– Ubuntu/Debian: /var/log/auth.log
– CentOS/RHEL: /var/log/secure

To see which commands have been executed with sudo you can do:
grep sudo /var/log/auth.log
the
journalctl | grep sudo

Configuration in sudoers file:

So that the senior user can run commands without needing to put sudo or a password, this line has been added to the end of the /etc/sudoers file:
major ALL=(ALL) NOPASSWD: ALL
This line has been safely added with the visudo tool to avoid syntax errors.

Script

Esta web utiliza cookies propias y de terceros para su correcto funcionamiento y para fines analíticos. Contiene enlaces a sitios web de terceros con políticas de privacidad ajenas que podrás aceptar o no cuando accedas a ellos. Al hacer clic en el botón Aceptar, acepta el uso de estas tecnologías y el procesamiento de tus datos para estos propósitos.
Privacidad