Reguła alertu o niepowodzeniu polecenia SU

Microsoft.Linux.SLES.12.LogFile.Syslog.SU.Command.Root.Failure.Alert (Rule)

Reguła alertu dotycząca wiadomości o niepowodzeniu polecenia „SU to root”.

Knowledge Base article:

Podsumowanie

W plikach dziennika systemu wykryto nieudane polecenie „su”.

Przyczyny

Wykonano nieudaną próbę podniesienia uprawnień za pomocą polecenia „su”. Przyczyną może być błędnie wpisane hasło lub próba użycia nieprawidłowej nazwy użytkownika. Niemniej jednak utrzymujące się niepowodzenie może wskazywać na podejrzaną aktywność.

Rozwiązania

Opis alertu i/lub elementu danych wyjściowych zawiera informacje o napotkanym zdarzeniu. Jeśli użycie polecenia „su” wydaje się podejrzane, sprawdź szczegóły skojarzone ze zdarzeniem oraz wszelkie inne zdarzenia, które wystąpiły w zbliżonym czasie.

Element properties:

TargetMicrosoft.Linux.SLES.12.Computer
CategoryEventCollection
EnabledTrue
Alert GenerateTrue
Alert SeverityError
Alert PriorityNormal
RemotableTrue
Alert Message
Wykryto niepowodzenie polecenia SU to Root
{0}

Member Modules:

ID Module Type TypeId RunAs 
EventDS DataSource Microsoft.Unix.SCXLog.Privileged.Datasource Default
GenerateAlert WriteAction System.Health.GenerateAlert Default

Source Code:

<Rule ID="Microsoft.Linux.SLES.12.LogFile.Syslog.SU.Command.Root.Failure.Alert" Target="Microsoft.Linux.SLES.12.Computer" Enabled="true" Remotable="true">
<Category>EventCollection</Category>
<DataSources>
<!-- [TYPE] SUSE SU False -->
<!-- [INPUT] 2014-12-15T13:57:14.311950-05:00 linux-sb1s su: FAILED SU (to root) root on pts/1 -->
<!-- [INPUT-MISS] Nov 30 03:37:25 scxcr-sles11-03 su: FAILED SU (to jeffcof) jonas on /dev/pts/2 -->
<DataSource ID="EventDS" TypeID="Unix!Microsoft.Unix.SCXLog.Privileged.Datasource">
<Host>$Target/Property[Type="Unix!Microsoft.Unix.Computer"]/PrincipalName$</Host>
<LogFile>/var/log/messages</LogFile>
<RegExpFilter>\s+su: FAILED SU \(to root\) \S+ on</RegExpFilter>
<IndividualAlerts>false</IndividualAlerts>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="GenerateAlert" TypeID="SystemHealth!System.Health.GenerateAlert">
<Priority>1</Priority>
<Severity>2</Severity>
<AlertMessageId>$MPElement[Name="Microsoft.Linux.SLES.12.LogFile.Syslog.SU.Command.Root.Failure.AlertMessage"]$</AlertMessageId>
<AlertParameters>
<AlertParameter1>$Data/EventDescription$</AlertParameter1>
</AlertParameters>
<Suppression>
<SuppressionValue/>
</Suppression>
</WriteAction>
</WriteActions>
</Rule>