# xenloops/red_team_notes architecture

> Architecture diagram of the GitHub repository xenloops/red_team_notes, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-04-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/xenloops/red_team_notes
- Repository: https://github.com/xenloops/red_team_notes

## Overview

##### Main Components
- Attacker Environment: Represent the attacker’s machine where tools like Cobalt Strike are run (as noted in the README).
- Beacon/Listener Setup: A component for beacon listeners, which are set up and maintained throughout the engagement.
- Recon and Initial Access: Group components for initial engagement stages (files like 02_external_recon.md and 03_init_compromise.md).
- Internal Recon and Exploitation: Components detailing host recon, privilege escalation (04_host_recon.md, 06_priv_escalation.md), and lateral movement (12_lateral_movement.md, 16_pivoting.md).
- Persistence and Post-Exploitation: Components for persistence (05_persistence.md), credential theft (08_cred_theft.md, 09_password_cracking.md), and further domain control (e.g., 10_domain_recon.md, 21_domain_dominance.md).
- Specialized Techniques: Additional nodes for advanced techniques like DPAPI (14_DPAPI.md), Kerberos exploitation (15_kerberos.md), and manipulation of certificate services or group policies.
- Tools and Utilities: Acknowledgment of common tools (Cobalt Strike and guides) and notes on environment caveats (like snapshot limitations or copy/paste limitations).

##### Relationships and Interactions
- Typical “flow” of a red team operation: starting at the attacker machine, proceeding to reconnaissance and initial compromise, then escalating privileges, moving laterally through internal networks, and eventually achieving persistence or exfiltrate data.
- Feedback loops where appropriate (for example, how established command and control (C2) structures feed back into ongoing operations).

##### Architectural Patterns and Design Principles
- Stress the importance of separation of concerns—each file or module in the documentation focuses on a specific phase or technique. This modularity is critical to clearly conveying the workflow and dependencies.
- “pipeline” as a series of steps: from the initial connection (attacker setup) to later phases (credential theft, lateral movement, etc.).

##### Relevant Technologies, Frameworks, or Libraries
- That the techniques and strategies documented are applied in real network scenarios (lab machines and attacker setups) and often interact with existing operating systems, network configurations, and security measures (such as Microsoft Defender, group policy adjustments, etc.).

##### Elements
- Clear Labels: Each module or stage (Attacker Environment, Recon, Exploitation, etc.) should be clearly labeled.

## Diagram (Mermaid)

```mermaid
flowchart TD
    A["Attacker Environment & Beacon/Listener Setup"]:::attacker

    subgraph "Recon and Initial Access"
        ER["External Recon"]:::recon
        IC["Initial Compromise"]:::recon
    end

    subgraph "Internal Recon and Exploitation"
        HR["Host Recon"]:::internal
        PE["Privilege Escalation"]:::internal
        LM["Lateral Movement"]:::internal
        PV["Pivoting"]:::internal
    end

    subgraph "Persistence and Post-Exploitation"
        P["Persistence"]:::persistence
        CT["Credential Theft"]:::persistence
        PC["Password Cracking"]:::persistence
        DR["Domain Recon"]:::persistence
        DD["Domain Dominance"]:::persistence
    end

    subgraph "Specialized Techniques"
        DP["DPAPI Techniques"]:::special
        KE["Kerberos Exploitation"]:::special
        ADCS["AD Certificate Services"]:::special
        GP["Group Policy Exploitation"]:::special
    end

    subgraph "Tools and Utilities / Operational Caveats"
        RH["README Highlights"]:::tools
        UT["Useful Tools"]:::tools
    end

    A -->|"to"| ER
    A -->|"to"| IC
    ER -->|"to"| HR
    IC -->|"to"| HR
    HR -->|"to"| PE
    PE -->|"to"| LM
    LM -->|"to"| PV
    PV -->|"to"| P
    P -->|"to"| CT
    CT -->|"to"| PC
    PC -->|"to"| DR
    DR -->|"to"| DD
    DD -->|"to"| DP
    DP -->|"to"| KE
    KE -->|"to"| ADCS
    ADCS -->|"to"| GP

    RH ---|"supports"| A
    UT ---|"supports"| A

    click A "https://github.com/xenloops/red_team_notes/blob/main/01_c2.md"
    click ER "https://github.com/xenloops/red_team_notes/blob/main/02_external_recon.md"
    click IC "https://github.com/xenloops/red_team_notes/blob/main/03_init_compromise.md"
    click HR "https://github.com/xenloops/red_team_notes/blob/main/04_host_recon.md"
    click PE "https://github.com/xenloops/red_team_notes/blob/main/06_priv_escalation.md"
    click LM "https://github.com/xenloops/red_team_notes/blob/main/12_lateral_movement.md"
    click PV "https://github.com/xenloops/red_team_notes/blob/main/16_pivoting.md"
    click P "https://github.com/xenloops/red_team_notes/blob/main/05_persistence.md"
    click CT "https://github.com/xenloops/red_team_notes/blob/main/08_cred_theft.md"
    click PC "https://github.com/xenloops/red_team_notes/blob/main/09_password_cracking.md"
    click DR "https://github.com/xenloops/red_team_notes/blob/main/10_domain_recon.md"
    click DD "https://github.com/xenloops/red_team_notes/blob/main/21_domain_dominance.md"
    click DP "https://github.com/xenloops/red_team_notes/blob/main/14_DPAPI.md"
    click KE "https://github.com/xenloops/red_team_notes/blob/main/15_kerberos.md"
    click ADCS "https://github.com/xenloops/red_team_notes/blob/main/17_AD_cert_services.md"
    click GP "https://github.com/xenloops/red_team_notes/blob/main/18_group_policy.md"
    click RH "https://github.com/xenloops/red_team_notes/blob/main/README.md"
    click UT "https://github.com/xenloops/red_team_notes/blob/main/Useful_tools.md"

    classDef attacker fill:#f9c74f,stroke:#333,stroke-width:2px
    classDef recon fill:#90be6d,stroke:#333,stroke-width:2px
    classDef internal fill:#f9844a,stroke:#333,stroke-width:2px
    classDef persistence fill:#577590,stroke:#fff,stroke-width:2px
    classDef special fill:#277da1,stroke:#fff,stroke-width:2px
    classDef tools fill:#f94144,stroke:#fff,stroke-width:2px
```
