T1550.004 Sumo Logic CSE · Sumo

Detect Web Session Cookie in Sumo Logic CSE

Adversaries steal and reuse valid web session cookies to authenticate to web applications and cloud services, effectively bypassing multi-factor authentication. Because session cookies represent a completed authentication event, they allow adversaries to impersonate users without knowing credentials or possessing their MFA device. Cookies are commonly obtained via adversary-in-the-middle (AiTM) phishing frameworks such as Evilginx2, Modlishka, or Muraena, which proxy the legitimate login flow and capture the post-MFA session token in real time. Once imported into an attacker-controlled browser or HTTP client, the stolen cookie grants full access to the victim's SaaS applications, cloud consoles, and email for the lifetime of the session. Star Blizzard (APT29 affiliate) has used this technique via EvilGinx to compromise email accounts protected by MFA.

MITRE ATT&CK

Tactic
Defense Evasion Lateral Movement
Technique
T1550 Use Alternate Authentication Material
Sub-technique
T1550.004 Web Session Cookie
Canonical reference
https://attack.mitre.org/techniques/T1550/004/

Sumo Detection Query

Sumo Logic CSE (Sumo)
sql
// MFA Bypass via Cookie Reuse
_sourceCategory=azure/aad/signin
| json "ResultType", "UserPrincipalName", "IPAddress", "AppDisplayName", "AuthenticationRequirement", "RiskLevelDuringSignIn", "CorrelationId" nodrop
| json "LocationDetails.countryOrRegion" as Country nodrop
| json "LocationDetails.city" as City nodrop
| json "AuthenticationDetails[0].authenticationMethod" as AuthMethod nodrop
| json "AuthenticationDetails[0].authenticationStepResultDetail" as AuthStepResult nodrop
| where ResultType == "0"
| eval IsCookieReuse = if(matches(AuthStepResult, "(?i)(previously satisfied|token broker|existing token)"), 1, 0)
| eval IsSingleFactor = if(AuthenticationRequirement == "singleFactorAuthentication", 1, 0)
| eval IsSuspiciousApp = if(matches(AppDisplayName, "(?i)(microsoft 365|office 365|azure portal|teams|sharepoint|onedrive|exchange|outlook)"), 1, 0)
| eval IsRisky = if(matches(RiskLevelDuringSignIn, "(?i)(medium|high)"), 1, 0)
| eval MFABypassCookie = if(IsCookieReuse == 1 and IsSingleFactor == 1 and IsSuspiciousApp == 1, 1, 0)
| where IsCookieReuse == 1 or IsRisky == 1
// Aggregate by user over 1-hour windows
| timeslice 1h
| stats count as SigninCount,
        values(Country) as Countries,
        values(IPAddress) as IPAddresses,
        values(AppDisplayName) as Apps,
        dc(Country) as UniqueCountries,
        dc(IPAddress) as UniqueIPs,
        max(MFABypassCookie) as MFABypass,
        max(IsRisky) as RiskySignin
        by UserPrincipalName, _timeslice
| eval ImpossibleTravel = if(UniqueCountries > 1, 1, 0)
| eval ThreatScore = MFABypass + ImpossibleTravel + RiskySignin
| where ThreatScore > 0
| eval DetectionType = if(ImpossibleTravel == 1 and MFABypass == 1, "ImpossibleTravel+MFABypass",
                     if(ImpossibleTravel == 1, "ImpossibleTravel",
                     if(MFABypass == 1, "MFABypassViaCookie", "AnomalousSignin")))
| fields _timeslice, UserPrincipalName, DetectionType, ThreatScore, UniqueCountries, Countries, UniqueIPs, IPAddresses, Apps, MFABypass, ImpossibleTravel, RiskySignin, SigninCount
| sort by ThreatScore desc
high severity medium confidence

Sumo Logic detection for T1550.004 analyzing Azure AD sign-in logs to identify web session cookie theft patterns. Parses authentication details to identify cookie-satisfaction results (Previously satisfied, Token broker, existing token) and flags users who complete single-factor authentication on Microsoft 365/Azure workloads with cookie reuse. Additionally detects impossible travel by counting distinct countries per user in 1-hour time slices. Outputs a composite ThreatScore to prioritize investigation.

Data Sources

Azure Active Directory Sign-in LogsAzure AD via Sumo Logic Azure App

Required Tables

azure/aad/signin

False Positives & Tuning

  • Users accessing Microsoft 365 through Conditional Access compliant devices in named locations where MFA has been previously satisfied and a refresh token is being used — this is expected behavior and will trigger cookie reuse signals
  • Mobile application sign-ins using broker authentication (Microsoft Authenticator app as token broker) which legitimately produce Token broker authentication step results
  • Global administrators or privileged users accessing Azure Portal from multiple geographic locations due to legitimate business travel within the same day, particularly when using personal hotspots or hotel networks
Download portable Sigma rule (.yml)

Other platforms for T1550.004


Testing Methodology

Validate this detection against 4 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1Extract Chrome Session Cookies Using SQLite (Windows)

    Expected signal: Sysmon Event ID 11 (File Create): Target image %TEMP%\stolen_cookies.db created by cmd.exe or powershell.exe. Sysmon Event ID 1 (Process Create): powershell.exe with CommandLine referencing 'SQLiteConnection' and 'Cookies'. Sysmon Event ID 10 (Process Access): If Chrome is running, file access conflict may be logged. Security Event ID 4663 if file auditing is enabled on Chrome profile directories.

  2. Test 2Replay Stolen Session Cookie via Python Requests

    Expected signal: Network connection from python3 to httpbin.org on port 443. Linux audit log (auditd): SYSCALL record for socket/connect from python3 process. Syslog/EDR network telemetry showing python3 making outbound HTTPS connections with cookie headers in the User-Agent matching Windows browser patterns (OS mismatch indicator).

  3. Test 3Import Cookie to Browser via EditThisCookie and Access Authenticated Session

    Expected signal: Sysmon Event ID 1: python3.exe or playwright process spawned with CDP flags. Sysmon Event ID 3: Network connection from chromium subprocess to httpbin.org on port 443. Sysmon Event ID 23 (File Delete) or 11 (File Create) for Playwright browser cache. Security Event ID 4688 if process creation auditing enabled.

  4. Test 4Simulate AiTM Cookie Theft Detection via Impossible Travel Pattern

    Expected signal: Azure AD Sign-in Logs (SigninLogs): Two non-interactive token use events for the authenticated user against Microsoft Graph within seconds. OfficeActivity or CloudAppEvents: MailItemsAccessed or ListMessages operation from the Graph API call. Azure AD audit logs: Token issued and used for mail access.

Unlock Pro Content

Get the full detection package for T1550.004 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections