Splunk Enterprise Security

Splunk Enterprise Security: Is there a search to detect old password in use?

sahiltcs
Path Finder

Detect active accounts with passwords that haven't been updated in more than 120 days.
Is there a search where we can detect old password in use?

0 Karma

jkat54
SplunkTrust
SplunkTrust

As Rich mentioned, you should enforce your policy via active directory. Once enforced, there shouldnt be any people with old passwords who arent also locked out.

TO find out if they exist you could use powershell to find them, and run the powershell as a scripted input into splunk:

PwdLastSet is the AD attribute you need to look for and it's encoded a bit.

    $objDomain = New-Object System.DirectoryServices.DirectoryEntry

    $objSearcher = New-Object System.DirectoryServices.DirectorySearcher
    $objSearcher.SearchRoot = $objDomain
    $objSearcher.PageSize = 1000

    $objSearcher.Filter = "(objectClass=User)"

    $colProplist = @("name","pwdLastSet")
    foreach ($i in $colPropList){$objSearcher.PropertiesToLoad.Add($i) | out-null}

    $colResults = $objSearcher.FindAll()

    foreach ($objResult in $colResults){
    write-host "Name: " $objResult.Properties.name
    write-host "PwdLastSet: " ConvertTo-Date($objResult.Properties.pwdLastSet)
    }

Youll need this function too:

Function ConvertTo-Date {
    Param (
        [Parameter(ValueFromPipeline=$true,mandatory=$true)]$accountExpires
    )

process {
    $lngValue = $accountExpires
    if(($lngValue -eq 0) -or ($lngValue -gt [DateTime]::MaxValue.Ticks)) {
        $AcctExpires = "<Never>"
    } else {
        $Date = [DateTime]$lngValue
        $AcctExpires = $Date.AddYears(1600).ToLocalTime()
    }
    $AcctExpires 
}
}

richgalloway
SplunkTrust
SplunkTrust

Do you you have a place where you keep track of when passwords were last changed? Or perhaps you record the password change event itself. If so, then you can detect an old password in use.

---
If this reply helps you, Karma would be appreciated.
0 Karma

sahiltcs
Path Finder

Yes we have AD logs and Windows security logs and record the password change event, But i am looking for the query which will tell us the Password last set , When password created and which user

Can you help me with the Query

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Why do this when Windows will detect old passwords and prevent their use?

---
If this reply helps you, Karma would be appreciated.
Get Updates on the Splunk Community!

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...

New in Observability Cloud - Explicit Bucket Histograms

Splunk introduces native support for histograms as a metric data type within Observability Cloud with Explicit ...