본문으로 건너뛰기
Skillpedia
분석 및 스프레드시트35k · #7956

hunting-for-defense-evasion-via-timestomping

하는 일

이 도구는 Windows 시스템의 파일 생성 날짜와 수정 날짜를 비교합니다. 누군가 날짜를 바꿔 악성 활동을 숨기려 한 불일치를 찾습니다.

사용하는 경우

  • ✓누군가 악성 프로그램을 숨기려고 파일 날짜를 바꿨다고 의심될 때.
  • ✓Windows 시스템이 침해되었고 활동을 위장하려는 시도가 있었는지 조사할 때.
  • ✓파일 날짜가 타당한지, 예를 들어 파일이 운영체제보다 오래되어 보이는지 확인할 때.

스킬 링크

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/hunting-for-defense-evasion-via-timestomping/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/hunting-for-defense-evasion-via-timestomping/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“내 시스템에서 파일 타임스탬프 조작이 있는지 확인해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

이 도구는 NTFS 파일 시스템 메타데이터를 분석해 두 가지 날짜 정보를 비교합니다. 하나는 쉽게 바뀔 수 있는 $STANDARD_INFORMATION이고, 다른 하나는 더 바꾸기 어려운 $FILE_NAME입니다. 쉽게 바뀌는 날짜가 실제보다 오래되어 보이면 위험 신호입니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Hunting for Defense Evasion via Timestomping

Detect timestamp manipulation by analyzing NTFS MFT entries for discrepancies between $STANDARD_INFORMATION and $FILE_NAME attributes.

When to Use

  • Investigating suspected anti-forensic activity where an adversary may have altered file timestamps to blend malware into legitimate directories
  • Threat hunting for defense evasion (MITRE ATT&CK T1070.006) across compromised Windows systems
  • Validating timeline integrity during forensic examinations of disk images or live acquisitions
  • Triaging suspicious files that appear to have creation dates older than the OS installation or inconsistent with known deployment timelines
  • Detecting tools like Timestomp (Metasploit), NTimeStomp, SetMACE, or PowerShell Set-ItemProperty used to alter timestamps
  • Building automated detection pipelines that flag temporal anomalies in MFT data for SOC analysts

Do not use as the sole detection method; advanced adversaries can manipulate both $STANDARD_INFORMATION and $FILE_NAME timestamps (though the latter requires raw disk access and is much harder). Combine with USN Journal, $LogFile, and ShimCache/Amcache analysis for corroboration.

Prerequisites

  • Raw $MFT file extracted from a Windows system (via FTK Imager, KAPE, or live extraction)
  • MFTECmd (Eric Zimmerman tool) or analyzeMFT for MFT parsing
  • Python 3.8+ with pandas for analysis
  • Optional: mft Python library (pip install mft) for programmatic MFT parsing
  • Optional: KAPE (Kroll Artifact Parser and Extractor) for automated artifact collection
  • Timeline Explorer or Excel for visual analysis of parsed MFT output

Workflow

Step 1: Extract the $MFT from a Live System or Disk Image

# Method 1: Using KAPE to collect MFT and related artifacts
.\kape.exe --tsource C: --tdest D:\Evidence\MFT_Collection --target !SANS_Triage

# Method 2: Using FTK Imager CLI to extract $MFT
ftkimager.exe \\.\C: D:\Evidence\mft_raw.bin --e01 --include $MFT

# Method 3: Raw copy using RawCopy (handles locked NTFS system files)
RawCopy.exe /FileNamePath:C:0 /OutputPath:D:\Evidence\ /OutputName:$MFT
# Method 4: On a mounted forensic image in Linux
sudo mount -o ro,norecovery /dev/sdb1 /mnt/evidence
sudo icat -o 2048 /dev/sdb 0 > /mnt/output/$MFT

# Method 5: Using sleuthkit to extract MFT from disk image
icat -o 2048 evidence.E01 0 > extracted_MFT

Step 2: Parse the MFT with MFTECmd

Use Eric Zimmerman's MFTECmd to produce a CSV with both $STANDARD_INFORMATION and $FILE_NAME timestamps:

# Parse MFT to CSV with all timestamp columns
MFTECmd.exe -f "D:\Evidence\$MFT" --csv D:\Evidence\Parsed\ --csvf mft_parsed.csv

# The output CSV contains these critical columns:
# Created0x10         - $STANDARD_INFORMATION Created timestamp
# LastModified0x10    - $STANDARD_INFORMATION Modified timestamp
# LastAccess0x10      - $STANDARD_INFORMATION Accessed timestamp
# LastRecordChange0x10 - $STANDARD_INFORMATION Entry Modified timestamp
# Created0x30         - $FILE_NAME Created timestamp
# LastModified0x30    - $FILE_NAME Modified timestamp
# LastAccess0x30      - $FILE_NAME Accessed timestamp
# LastRecordChange0x30 - $FILE_NAME Entry Modified timestamp

Step 3: Detect Timestomping via SI vs FN Comparison

The core detection: $STANDARD_INFORMATION timestamps are easily modified by user-mode tools, but $FILE_NAME timestamps are updated only by the NTFS driver (kernel-mode). When SI timestamps are OLDER than FN timestamps, timestomping is likely:

import pandas as pd
from datetime import datetime, timedelta

def load_mft_data(csv_path):
    """Load MFTECmd parsed CSV output."""
    df = pd.read_csv(csv_path, low_memory=False)

    # Parse timestamp columns
    timestamp_cols = [
        "Created0x10", "LastModified0x10", "LastAccess0x10", "LastRecordChange0x10",
        "Created0x30", "LastModified0x30", "LastAccess0x30", "LastRecordChange0x30"
    ]

    for col in timestamp_cols:
        if col in df.columns:
            df[col] = pd.to_datetime(df[col], errors="coerce")

    return df

def detect_timestomping(df):
    """Detect timestamp manipulation by comparing SI and FN attributes.

    Key indicators:
    1. SI Created < FN Created (SI timestamp pushed back in time)
    2. SI timestamps have nanoseconds = 0000000 (tool artifact)
    3. SI Created < FN Entry Modified (impossible under normal NTFS behavior)
    4. Large gap between SI and FN timestamps
    """

…
자주 묻는 질문

파일 타임스탬프란 무엇인가요?

파일이 언제 생성되었는지, 마지막으로 언제 수정되었는지, 또는 마지막으로 언제 접근되었는지를 기록한 파일과 연관된 정보입니다.

‘타임스토밍(timestomping)’이란 무엇인가요?

공격자가 파일 타임스탬프를 바꿔 합법적으로 보이거나 실제보다 오래된 것처럼 보이게 해서, 탐지를 방해하는 기법입니다.

$STANDARD_INFORMATION과 $FILE_NAME을 비교하는 이유는 무엇인가요?

$STANDARD_INFORMATION은 일반 프로그램이 수정하기 쉽고, $FILE_NAME은 파일 시스템(NTFS)이 직접 업데이트해서 바꾸기 어렵습니다. 둘 사이의 불일치는 조작을 나타낼 수 있습니다.

상세 정보

작성자의 원본 설명

Detect NTFS timestamp manipulation (MITRE T1070.006) by comparing $STANDARD_INFORMATION vs $FILE_NAME timestamps in the MFT. Uses analyzeMFT and Python to identify files with anomalous temporal patterns indicating anti-forensic timestomping activity. '

repo: mukul975/Anthropic-Cybersecurity-Skills

인기도

GitHub 스타
35k
순위
#7956
라이선스
Apache-2.0
업데이트
2026. 8. 31.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬