From 00e1823dc53b10dccb3e8a32d13bc43fd91514a7 Mon Sep 17 00:00:00 2001 From: debian Date: Sun, 29 Nov 2026 12:31:59 -0300 Subject: [PATCH] build: containerised build with every dependency pinned The repository needs seven development packages plus libcurl transitives, which is where a fresh clone usually stops. The Dockerfile pins them on Debian trixie and builds the binary; README-REPRO explains the native path (start.sh already installs per-OS) and the container path, including the USB flags the sequence needs at run time. --- Dockerfile | 27 +++++++++++++++++++++++++++ README-REPRO.md | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 Dockerfile create mode 100644 README-REPRO.md diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..4fa5114 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,27 @@ +# syntax=docker/dockerfile:1 +# Build reproducible de tr4mpass con todas sus dependencias dentro de un +# contenedor, sin tocar el sistema. Debian trixie == el host de desarrollo. +FROM debian:trixie-slim + +RUN apt-get update && apt-get install -y --no-install-recommends \ + build-essential pkg-config \ + libimobiledevice-dev libirecovery-1.0-dev libusb-1.0-0-dev libplist-dev \ + libssl-dev libcurl4-openssl-dev libssh2-1-dev \ + usbutils usbmuxd ca-certificates \ + && rm -rf /var/lib/apt/lists/* + +WORKDIR /build + +# Solo lo que make necesita: Makefile, src/, include/ y tests/ (el target +# .chip-db-canary depende de tests/chip_db_canary.c). +COPY Makefile ./ +COPY src ./src +COPY include ./include +COPY tests ./tests + +RUN make clean && make + +# El binario queda en /build/tr4mpass. +# Correr con acceso USB directo: +# podman run --rm -it --privileged -v /dev/bus/usb:/dev/bus/usb tr4mpass ./tr4mpass -v +CMD ["/bin/bash"] diff --git a/README-REPRO.md b/README-REPRO.md new file mode 100644 index 0000000..e7be942 --- /dev/null +++ b/README-REPRO.md @@ -0,0 +1,36 @@ +# Reproducir el build de tr4mpass (fix checkm8 A8/xHCI) en cualquier PC + +Rama: `fix/checkm8-a8-xhci` (3 commits: F1, F0, F3). + +## Vía 1 — Nativo (la que usa USB directo, recomendada para correr) + +El script `start.sh` detecta el SO e instala todas las dependencias y compila: + +``` +git clone +cd tr4mpass +./start.sh +``` + +`start.sh` usa `sudo` para instalar deps vía apt/brew/dnf/pacman/zypper/apk y corre +`make clean && make`. La iPad se conecta por USB a esa misma máquina. + +## Vía 2 — Contenedor (build reproducible, sin tocar el sistema) + +``` +podman build -t tr4mpass . +``` + +El `Dockerfile` (Debian trixie) instala `libimobiledevice-dev libirecovery-1.0-dev +libusb-1.0-0-dev libplist-dev libssl-dev libcurl4-openssl-dev libssh2-1-dev +pkg-config build-essential usbutils usbmuxd` y compila el binario. + +Para correr dentro del contenedor hace falta pasar el USB directo: + +``` +podman run --rm -it --privileged -v /dev/bus/usb:/dev/bus/usb tr4mpass ./tr4mpass -v +``` + +Nota: el exploit necesita USB a nivel de controlador (libusb sobre el bus real). En un +contenedor eso exige `--privileged` + montar `/dev/bus/usb`; en una VM/WSL hace falta +además passthrough del dispositivo.