Skip to main content
skill CX Codex

analyzing-malware-persistence-with-autoruns — Claude Code skill

A skill that walks the agent through Windows persistence hunting with Sysinternals Autoruns: registry keys, services, tasks, drivers. Built for incident response.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-malware-persistence-with-autoruns -a claude-code
Open on GitHub

What analyzing-malware-persistence-with-autoruns does

The skill covers Autoruns and Autorunsc: enumerating Auto-Start Extensibility Points across the registry, Task Scheduler, services, drivers, Winlogon, LSA providers, WMI subscriptions and AppInit DLLs. It also spells out signature verification, baseline diffing to spot newly added entries, and offline analysis of a disk image with the -z flag.

A Python script ships with it. It runs autorunsc64.exe with -a * -c -h -s -nobanner *, writes the output to CSV and flags what looks wrong: unsigned binaries, missing metadata, paths under \Temp\ or \AppData\Local\Temp, and launch strings using powershell, wscript, mshta or regsvr32. The script expects Python 3.9+.

Reputation checks need a VirusTotal API key, and the compare function needs a clean baseline export taken beforehand. No baseline means nothing to diff against, so pull one before you start on an infected host.

What it helps with

  • enumerate every autostart point on a compromised host
  • separate unsigned entries from Microsoft-signed ones
  • spot LOLBin launch strings in autostart entries
  • diff current Autoruns output against a clean baseline
  • analyze autostart entries from an offline disk image

Example prompts for the agent

  • scan autostart with autorunsc and list the suspicious entries
  • compare the current Autoruns export with the baseline and name new entries
  • analyze autostart points in a disk image offline

How to install analyzing-malware-persistence-with-autoruns

1Skills CLI (Vercel)

npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-malware-persistence-with-autoruns -a claude-code

2Manually: put the files in place

~/.claude/skills/analyzing-malware-persistence-with-autoruns/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/analyzing-malware-persistence-with-autoruns/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about analyzing-malware-persistence-with-autoruns

How do I install analyzing-malware-persistence-with-autoruns in Claude?

Run npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill analyzing-malware-persistence-with-autoruns -a claude-code. The skill file then lives at ~/.claude/skills/analyzing-malware-persistence-with-autoruns/SKILL.md.

What does this skill do?

It lays out a Windows persistence hunt with Sysinternals Autoruns: which autostart categories to check, how to flag suspicious entries, and how to compare against a baseline export.

What do I need for it to work?

Autoruns and Autorunsc, admin rights on the target system, Python 3.9+ for the script, a VirusTotal API key for reputation checks, and a clean baseline export for comparison.

Source text

SKILL.md · Apache-2.0
---
name: analyzing-malware-persistence-with-autoruns
description: Use Sysinternals Autoruns to systematically enumerate and analyze malware
  persistence mechanisms across Windows registry run keys, scheduled tasks, services,
  drivers, and startup locations. Use when hunting for persistence during Windows
  incident response, triaging a compromised endpoint, or validating that malware
  autostart entries have been fully identified and removed.
domain: cybersecurity
subdomain: malware-analysis
tags:
- autoruns
- persistence
- malware-analysis
- sysinternals
- windows
- registry
- startup
- incident-response
mitre_attack:
- T1547.001
- T1543.003
- T1053.005
- T1574.001
- T1037.001
version: '1.0'
author: mahipal
license: Apache-2.0
d3fend_techniques:
- Executable Denylisting
- Execution Isolation
- File Metadata Consistency Validation
- Content Format Conversion
- File Content Analysis
nist_csf:
- DE.AE-02
- RS.AN-03
- ID.RA-01
- DE.CM-01
---
# Analyzing Malware Persistence with Autoruns

## Overview

Sysinternals Autoruns extracts data from hundreds of Auto-Start Extensibility Points (ASEPs) on Windows, scanning 18+ categories including Run/RunOnce keys, services, scheduled tasks, drivers, Winlogon entries, LSA providers, print monitors, WMI subscriptions, and AppInit DLLs. Digital signature verification filters Microsoft-signed entries. The compare function identifies newly added persistence via baseline diffing. VirusTotal integration checks hash reputation. Offline analysis via -z flag enables forensic disk image examination.


## When to Use

- When investigating security incidents that require analyzing malware persistence with autoruns
- When building detection rules or threat hunting queries for this domain
- When SOC analysts need structured procedures for this analysis type
- When validating security monitoring coverage for related attack techniques

## Prerequisites

- Sysinternals Autoruns (GUI) and Autorunsc (CLI)
- Administrative privileges on target system
- Python 3.9+ for automated analysis
- VirusTotal API key for reputation checks
- Clean baseline export for comparison

## Workflow

### Step 1: Automated Persistence Scanning

```python
#!/usr/bin/env python3
"""Automate Autoruns-based persistence analysis."""
import subprocess
import csv
import json
import sys


def scan_and_analyze(autorunsc_path="autorunsc64.exe", csv_path="scan.csv"):
    cmd = [autorunsc_path, "-a", "*", "-c", "-h", "-s", "-nobanner", "*"]
    result = subprocess.run(cmd, capture_output=True, text=True, timeout=600)
    with open(csv_path, 'w') as f:
        f.write(result.stdout)
    return parse_and_flag(csv_path)


def parse_and_flag(csv_path):
    suspicious = []
    with open(csv_path, 'r', errors='replace') as f:
        for row in csv.DictReader(f):
            reasons = []
            signer = row.get("Signer", "")
            if not signer or signer == "(Not verified)":
                reasons.append("Unsigned binary")
            if not row.get("Description") and not row.get("Company"):
                reasons.append("Missing metadata")
            path = row.get("Image Path", "").lower()
            for sp in ["\temp\\", "\appdata\local\temp", "\users\public\\"]:
                if sp in path:
                    reasons.append(f"Suspicious path")
            launch = row.get("Launch String", "").lower()
            for kw in ["powershell", "cmd /c", "wscript", "mshta", "regsvr32"]:
                if kw in launch:
                    reasons.append(f"LOLBin: {kw}")
            if reasons:
                row["reasons"] = reasons
                suspicious.append(row)
    return suspicious


if __name__ == "__main__":
    if len(sys.argv) > 1:
        results = parse_and_flag(sys.argv[1])
        print(f"[!] {len(results)} suspicious entries")
        for r in results:
            print(f"  {r.get('Entry','')} - {r.get('Image Path','')}")
            for reason in r.get('reasons', []):
                print(f"    - {reason}")
```

## Validation Criteria

- All ASEP categories scanned and cataloged
- Unsigned entries flagged for investigation
- Suspicious paths and LOLBin launch strings highlighted
- Baseline comparison identifies new persistence mechanisms

## References

- [Sysinternals Autoruns](https://learn.microsoft.com/en-us/sysinternals/downloads/autoruns)
- [SANS - Offline Autoruns Revisited](https://www.sans.org/blog/offline-autoruns-revisited-auditing-malware-persistence/)
- [Hunting Malware with Autoruns](https://nasbench.medium.com/hunting-malware-with-windows-sysinternals-autoruns-19cbfe4103c2)
- [MITRE ATT&CK T1547 - Boot or Logon Autostart](https://attack.mitre.org/techniques/T1547/)

© mahipal · Apache-2.0 · mukul975/Anthropic-Cybersecurity-Skills

Similar skills

Everything for Security →

From the same set89

exploiting-idor-vulnerabilities Guides authorized testing of IDOR vulnerabilities across API endpoints using Burp Suite, the Authorize extension, and curl scripts. CX Codex +1 365installs analyzing-malware-behavior-with-cuckoo-sandbox A skill that detonates samples in Cuckoo Sandbox and walks through what they do at runtime: processes, files, registry, network. CX Codex +1 361installs testing-for-sensitive-data-exposure A skill that walks an agent through checks for leaked secrets, PII in API responses, and unencrypted data transmission. Useful during authorized pentests and data protection audits. CX Codex +1 356installs performing-security-headers-audit Audits HTTP security headers including CSP, HSTS, and cookie flags. It detects missing browser protections and configuration flaws on web endpoints. CX Codex +1 359installs analyzing-memory-dumps-with-volatility Investigates RAM memory dumps using Volatility 3 to uncover hidden malware, code injections, network activity, and cached credentials. CX Codex +1 354installs testing-oauth2-implementation-flaws A skill that probes OAuth 2.0 and OpenID Connect flows for code interception, redirect URI tricks, CSRF, token leakage and PKCE bypass. CX Codex +1 350installs implementing-api-rate-limiting-and-throttling This skill configures Redis-backed sliding window and token bucket rate limiters to protect API endpoints against brute force attacks. CX Codex +1 348installs analyzing-malware-family-relationships-with-malpedia This skill connects malware aliases, YARA rules, and threat actors through Malpedia. Use it to study family lineage, loader-payload chains, or attribution. CX Codex +1 349installs

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor