> CVE Writeup Template

[CVE-YYYY-NNNNN] โ€” [Vulnerability Title]

๐Ÿ“… Disclosed: [YYYY-MM-DD] ๐ŸŽฏ Vendor: [Vendor] ๐Ÿ“ฆ Product: [Product / Version range] [Severity ยท CVSS X.X]
[CWE-XXX][Attack Vector][Impact]

๐Ÿ“‘ Table of Contents

  1. Summary
  2. Affected Products
  3. Background
  4. Root Cause Analysis
  5. Proof of Concept
  6. Exploitation & Impact
  7. Detection
  8. Mitigation & Patch Analysis
  9. Timeline
  10. References

01Summary

One paragraph describing the vulnerability: what component is affected, what kind of bug it is, what an attacker can achieve, and the prerequisites for exploitation. Keep this readable by non-experts.

TL;DR โ€” [One-sentence summary suitable for a tweet or executive briefing.]

02Affected Products

Affected Versions
Product:        [Name]
Versions:       <= [X.Y.Z]
Fixed in:       [X.Y.Z+1]
Configurations: [default / when X is enabled / etc.]
Platforms:      [Linux / Windows / macOS / Cross-platform]

03Background

Explain the subsystem or feature the bug lives in. Cover any protocol, file format, or framework concept the reader needs to follow the rest of the writeup. Include diagrams or pseudo-code when helpful.

04Root Cause Analysis

Walk through the vulnerable code path. Quote upstream source with file/line references. Identify exactly which assumption is violated and why the bug class applies (CWE).

Vulnerable code โ€” src/foo/bar.c:142
int parse_packet(const uint8_t *buf, size_t len) {
    uint16_t n = read_be16(buf);           // attacker controlled
    uint8_t  out[256];
    memcpy(out, buf + 2, n);               // โŒ no bound check vs sizeof(out)
    return handle(out, n);
}

05Proof of Concept

A minimal PoC that triggers the bug deterministically. Include the exact payload, the expected crash/observation, and the environment it was tested on.

poc.py
#!/usr/bin/env python3
import socket, struct

HOST, PORT = "127.0.0.1", 4444
payload = struct.pack(">H", 0xFFFF) + b"A" * 0x400

with socket.create_connection((HOST, PORT)) as s:
    s.sendall(payload)
    print(s.recv(1024))
Responsible disclosure: do not publish a weaponized exploit before the vendor patch ships.

06Exploitation & Impact

From crash to control: describe primitives gained, mitigations bypassed (ASLR, DEP, CFI, sandbox), and the final impact (RCE, LPE, info-leak, DoS). Be explicit about authentication, network reachability, and user interaction requirements.

Exploitation Chain
1. Trigger OOB write to corrupt adjacent heap chunk
2. Hijack vtable pointer of next allocated object
3. Pivot stack into ROP chain via gadget at libfoo+0x1A2C0
4. Call mprotect() then jump to shellcode
5. โ†’ Remote code execution as the service user

07Detection

How defenders can spot exploitation attempts: network signatures, log artifacts, file/registry indicators, or YARA/Sigma rules.

Sigma rule (excerpt)
title: Suspicious [Product] Packet Length
detection:
  selection:
    service|equals: '[product]'
    payload_length|gt: 1024
  condition: selection
level: high

08Mitigation & Patch Analysis

How the vendor fixed it and what users should do until they can patch. Diff the fix and verify it actually addresses the root cause.

Patch diff
- memcpy(out, buf + 2, n);
+ if (n > sizeof(out)) return -EINVAL;
+ memcpy(out, buf + 2, n);

09Timeline

Disclosure Timeline
[YYYY-MM-DD]  Vulnerability discovered
[YYYY-MM-DD]  Reported to vendor via [channel]
[YYYY-MM-DD]  Vendor acknowledged
[YYYY-MM-DD]  Patch released โ€” version [X.Y.Z+1]
[YYYY-MM-DD]  CVE assigned โ€” [CVE-YYYY-NNNNN]
[YYYY-MM-DD]  Public disclosure

10References

Written by [Author Handle] ยท COBRA Research Group

โ† Back to CVE Writeups