# starseed12345/queststack architecture

> Architecture diagram of the GitHub repository starseed12345/queststack, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-05). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/starseed12345/queststack
- Repository: https://github.com/starseed12345/queststack

## Overview

QuestStack is a cross-platform desktop tool for temporarily rooting supported Quest 1 devices and unlocking their bootloader. The main path runs from UI confirmation through device and firmware checks, temporary root, inactive-slot backup and downgrade, fastboot unlocking, then slot restoration, reset, and reboot. Unlock Only is a separate mode for devices already in vulnerable fastboot. The README documents workflow stages not fully visible in the excerpts; those links cite the README. The graph omits peripheral implementation details not established by the supplied evidence.

Main entry points: [`QuestWorkflow.cs`](https://github.com/starseed12345/queststack/blob/main/QuestWorkflow.cs) (Full workflow), [`MainWindow.cs`](https://github.com/starseed12345/queststack/blob/main/MainWindow.cs) (Main window), [`Firmware.cs`](https://github.com/starseed12345/queststack/blob/main/Firmware.cs) (Firmware bundle), [`BackupStore.cs`](https://github.com/starseed12345/queststack/blob/main/BackupStore.cs) (Verified backups)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_desktop["Desktop interface"]
  node_ui["Main window<br/>[MainWindow.cs]"]
  node_fullflow["Full workflow<br/>[QuestWorkflow.cs]"]
  node_unlockmode["Unlock Only workflow"]
  node_logging["Logging<br/>[Logger.cs]"]
end

subgraph group_device["Device access"]
  node_identity["Device probe<br/>[DeviceIdentity.cs]"]
  node_adb["ADB commands<br/>[Adb.cs]"]
  node_root["GhostLock root<br/>[RootExploit.cs]"]
  node_platform["Bundled platform tools<br/>[BundledAdb.cs]"]
end

subgraph group_firmware["Firmware safety"]
  node_firmware["Firmware bundle<br/>[Firmware.cs]"]
  node_abl["ABL extraction"]
  node_backup[("Verified backups<br/>[BackupStore.cs]")]
  node_paths["App data paths<br/>[AppDataPaths.cs]"]
end

subgraph group_unlock["Unlock and recovery"]
  node_fastbootcli["Fastboot commands<br/>[FastbootCli.cs]"]
  node_usbfastboot["Fastboot USB"]
  node_unlocker["ABL unlock exploit"]
end

node_user(("Developer"))
node_headset["Quest headset"]
node_externalfiles["Hosted files"]

node_user -->|"starts and selects"| node_ui
node_ui -->|"runs full mode"| node_fullflow
node_ui -->|"runs unlock-only"| node_unlockmode
node_ui -->|"refreshes device"| node_identity
node_ui -->|"lists backups"| node_backup
node_fullflow -->|"checks support"| node_identity
node_identity -->|"reads device properties"| node_adb
node_fullflow -->|"validates tools"| node_platform
node_platform -.->|"extracts verified tools"| node_externalfiles
node_fullflow -->|"gains temporary root"| node_root
node_root -->|"pushes and runs exploit"| node_adb
node_fullflow -->|"downloads and verifies"| node_firmware
node_firmware -->|"downloads bundle"| node_externalfiles
node_fullflow -->|"backs up slot"| node_backup
node_backup -->|"exports partitions"| node_adb
node_backup -->|"uses storage paths"| node_paths
node_fullflow -->|"pushes and flashes images"| node_firmware
node_firmware -.->|"extracts ABL image"| node_abl
node_fullflow -->|"switches slots and reboots"| node_fastbootcli
node_fullflow -->|"performs unlock"| node_unlocker
node_unlocker -->|"sends exploit commands"| node_usbfastboot
node_unlocker -->|"builds patched payload"| node_abl
node_fullflow -->|"restores slot and resets"| node_fastbootcli
node_fullflow -->|"reports stages"| node_logging
node_unlockmode -->|"runs fastboot unlock"| node_fastbootcli
node_unlockmode -->|"invokes unlock"| node_unlocker

click node_ui "https://github.com/starseed12345/queststack/blob/main/MainWindow.cs"
click node_fullflow "https://github.com/starseed12345/queststack/blob/main/QuestWorkflow.cs"
click node_unlockmode "https://github.com/starseed12345/queststack/blob/main/UnlockOnlyWorkflow.cs"
click node_logging "https://github.com/starseed12345/queststack/blob/main/Logger.cs"
click node_identity "https://github.com/starseed12345/queststack/blob/main/DeviceIdentity.cs"
click node_adb "https://github.com/starseed12345/queststack/blob/main/Adb.cs"
click node_root "https://github.com/starseed12345/queststack/blob/main/RootExploit.cs"
click node_platform "https://github.com/starseed12345/queststack/blob/main/BundledAdb.cs"
click node_firmware "https://github.com/starseed12345/queststack/blob/main/Firmware.cs"
click node_abl "https://github.com/starseed12345/queststack/blob/main/AblImageExtractor.cs"
click node_backup "https://github.com/starseed12345/queststack/blob/main/BackupStore.cs"
click node_paths "https://github.com/starseed12345/queststack/blob/main/AppDataPaths.cs"
click node_fastbootcli "https://github.com/starseed12345/queststack/blob/main/FastbootCli.cs"
click node_usbfastboot "https://github.com/starseed12345/queststack/blob/main/FastbootUsbDevice.cs"
click node_unlocker "https://github.com/starseed12345/queststack/blob/main/BootloaderUnlocker.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_ui,node_fullflow,node_unlockmode,node_logging toneBlue
class node_identity,node_adb,node_root,node_platform toneAmber
class node_firmware,node_abl,node_backup,node_paths toneMint
class node_fastbootcli,node_usbfastboot,node_unlocker toneRose
class node_user,node_headset,node_externalfiles toneIndigo
```

## Components

### Desktop interface

- [Main window](https://github.com/starseed12345/queststack/blob/main/MainWindow.cs): `MainWindow.cs`
- [Full workflow](https://github.com/starseed12345/queststack/blob/main/QuestWorkflow.cs): `QuestWorkflow.cs`
- [Unlock Only workflow](https://github.com/starseed12345/queststack/blob/main/UnlockOnlyWorkflow.cs): `UnlockOnlyWorkflow.cs`
- [Logging](https://github.com/starseed12345/queststack/blob/main/Logger.cs): `Logger.cs`

### Device access

- [Device probe](https://github.com/starseed12345/queststack/blob/main/DeviceIdentity.cs): `DeviceIdentity.cs`
- [ADB commands](https://github.com/starseed12345/queststack/blob/main/Adb.cs): `Adb.cs`
- [GhostLock root](https://github.com/starseed12345/queststack/blob/main/RootExploit.cs): `RootExploit.cs`
- [Bundled platform tools](https://github.com/starseed12345/queststack/blob/main/BundledAdb.cs): `BundledAdb.cs`

### Firmware safety

- [Firmware bundle](https://github.com/starseed12345/queststack/blob/main/Firmware.cs): `Firmware.cs`
- [ABL extraction](https://github.com/starseed12345/queststack/blob/main/AblImageExtractor.cs): `AblImageExtractor.cs`
- [Verified backups](https://github.com/starseed12345/queststack/blob/main/BackupStore.cs): `BackupStore.cs`
- [App data paths](https://github.com/starseed12345/queststack/blob/main/AppDataPaths.cs): `AppDataPaths.cs`

### Unlock and recovery

- [Fastboot commands](https://github.com/starseed12345/queststack/blob/main/FastbootCli.cs): `FastbootCli.cs`
- [Fastboot USB](https://github.com/starseed12345/queststack/blob/main/FastbootUsbDevice.cs): `FastbootUsbDevice.cs`
- [ABL unlock exploit](https://github.com/starseed12345/queststack/blob/main/BootloaderUnlocker.cs): `BootloaderUnlocker.cs`

### Other components

- **Developer**
- **Quest headset**
- **Hosted files**

## Connections

- Developer → Main window: starts and selects (evidence: `README.md`)
- Main window → Full workflow: runs full mode (evidence: `MainWindow.cs`)
- Main window → Unlock Only workflow: runs unlock-only (evidence: `MainWindow.cs`)
- Main window → Device probe: refreshes device (evidence: `MainWindow.cs`)
- Main window → Verified backups: lists backups (evidence: `MainWindow.cs`)
- Full workflow → Device probe: checks support (evidence: `QuestWorkflow.cs`)
- Device probe → ADB commands: reads device properties (evidence: `DeviceIdentity.cs`)
- Full workflow → Bundled platform tools: validates tools (evidence: `QuestWorkflow.cs`)
- Bundled platform tools → Hosted files: extracts verified tools
- Full workflow → GhostLock root: gains temporary root (evidence: `QuestWorkflow.cs`)
- GhostLock root → ADB commands: pushes and runs exploit (evidence: `RootExploit.cs`)
- Full workflow → Firmware bundle: downloads and verifies (evidence: `README.md`)
- Firmware bundle → Hosted files: downloads bundle (evidence: `Firmware.cs`)
- Full workflow → Verified backups: backs up slot (evidence: `README.md`)
- Verified backups → ADB commands: exports partitions (evidence: `BackupStore.cs`)
- Verified backups → App data paths: uses storage paths (evidence: `BackupStore.cs`)
- Full workflow → Firmware bundle: pushes and flashes images (evidence: `README.md`)
- Firmware bundle → ABL extraction: extracts ABL image
- Full workflow → Fastboot commands: switches slots and reboots (evidence: `README.md`)
- Full workflow → ABL unlock exploit: performs unlock (evidence: `README.md`)
- ABL unlock exploit → Fastboot USB: sends exploit commands (evidence: `BootloaderUnlocker.cs`)
- ABL unlock exploit → ABL extraction: builds patched payload (evidence: `BootloaderUnlocker.cs`)
- Full workflow → Fastboot commands: restores slot and resets (evidence: `README.md`)
- Full workflow → Logging: reports stages (evidence: `QuestWorkflow.cs`)
- Unlock Only workflow → Fastboot commands: runs fastboot unlock (evidence: `UnlockOnlyWorkflow.cs`)
- Unlock Only workflow → ABL unlock exploit: invokes unlock (evidence: `UnlockOnlyWorkflow.cs`)
