BASH_SRV Telegram 100
🔐 Проверяем, у кого есть root-доступ через sudo

Иногда нужно быстро выяснить, какие пользователи могут выполнять команды от имени root через sudo. Вот простой способ это сделать:


getent group sudo | cut -d: -f4 | tr ',' '\n' | sort


📋 Что делает скрипт:

* getent group sudo — вытаскивает строку группы sudo;
* cut -d: -f4 — берёт список пользователей;
* tr ',' '\n' — превращает список в столбик;
* sort — сортирует результат.

💡 Работает в Debian/Ubuntu — для других систем группу sudo нужно заменить на wheel, например:


getent group wheel | cut -d: -f4 | tr ',' '\n' | sort


🔥 Быстрый аудит — особенно полезно при подозрении на несанкционированный доступ.

👉@bash_srv
👍73



tgoop.com/bash_srv/100
Create:
Last Update:

🔐 Проверяем, у кого есть root-доступ через sudo

Иногда нужно быстро выяснить, какие пользователи могут выполнять команды от имени root через sudo. Вот простой способ это сделать:


getent group sudo | cut -d: -f4 | tr ',' '\n' | sort


📋 Что делает скрипт:

* getent group sudo — вытаскивает строку группы sudo;
* cut -d: -f4 — берёт список пользователей;
* tr ',' '\n' — превращает список в столбик;
* sort — сортирует результат.

💡 Работает в Debian/Ubuntu — для других систем группу sudo нужно заменить на wheel, например:


getent group wheel | cut -d: -f4 | tr ',' '\n' | sort


🔥 Быстрый аудит — особенно полезно при подозрении на несанкционированный доступ.

👉@bash_srv

BY Bash Советы




Share with your friend now:
tgoop.com/bash_srv/100

View MORE
Open in Telegram


Telegram News

Date: |

The creator of the channel becomes its administrator by default. If you need help managing your channel, you can add more administrators from your subscriber base. You can provide each admin with limited or full rights to manage the channel. For example, you can allow an administrator to publish and edit content while withholding the right to add new subscribers. For crypto enthusiasts, there was the “gm” app, a self-described “meme app” which only allowed users to greet each other with “gm,” or “good morning,” a common acronym thrown around on Crypto Twitter and Discord. But the gm app was shut down back in September after a hacker reportedly gained access to user data. Click “Save” ; Among the requests, the Brazilian electoral Court wanted to know if they could obtain data on the origins of malicious content posted on the platform. According to the TSE, this would enable the authorities to track false content and identify the user responsible for publishing it in the first place. It’s easy to create a Telegram channel via desktop app or mobile app (for Android and iOS):
from us


Telegram Bash Советы
FROM American