# Changelog
## v0.1.34 (2026-09-10)
- Added: `check_pkgbuild_caches` Pattern 16 — a deceptive character in the **host** of a top-level `url=` or `source=` URL: a confusable Cyrillic/Greek/Armenian/fullwidth letter that renders like ASCII (`а` for `a`) but resolves to a host the attacker registered, or an invisible / reordering character (zero-width, bidi override, U+00AD, Tags block) hiding part of the host. Only the authority is checked — a non-ASCII byte in a URL path (`.../wiki/Программа`), in `pkgdesc`/`optdepends`/comments, or in an indented in-function `url=` is left alone, since non-Latin text there is legitimate. Byte-matched under `LC_ALL=C` with `grep -E`. Ported to the yay hook as a warning (`configs/yay-init.lua`, marker `(v15)`). Modeled on NeoArch's `security_scan.py`.
- Changed: `configs/yay-init.lua`'s `AURPostDownload` hook no longer pauses on a "press Enter to continue" prompt after a **clean** PKGBUILD scan — the `PKGBUILD CHECKS CLEAN` banner still prints and the build proceeds. The checkpoint now only fires on a warn verdict (privilege escalation, mutable patch source, aur-audit RED), where you actually have a decision to make; a block still aborts outright. Reported by a Mabox user for whom every clean install stopped for a keypress. Set `ARCHCANARY_PAUSE_ON_CLEAN = true` near the top of `init.lua` to pause on every scan instead — useful for large builds where even the clean banner scrolls off under compile spam before you can read it (the concern that first added the pause in v0.1.28). Marker bumped to `(v15)` (together with the Pattern 16 port above).
- Docs: dropped the held version/URL-mismatch rule from the `--check-pkgbuild` description (`README.md`, `man/archcanary.1`); it was removed from the code in v0.1.33. The reserved Pattern 16 slot is reused above.
## v0.1.33 (2026-09-02)
- Added: `check_pkgbuild_caches` gained two rules from Andreas Reichel's static-rules scan of all ~111,000 live AUR packages (2026-08-25). (1) `sudo`/`doas`/`pkexec` in a PKGBUILD's `build()`/`package()` — makepkg runs those as the calling user, so shelling through `sudo` writes outside `$pkgdir` onto the live system (`tarah` runs `sudo cp … /usr/bin`). PKGBUILD only (a `.install` scriptlet already runs as root); `sudo -u <user>` (run a step as another user) is not matched. (2) An **unchecksummed** `source=` entry on a forge merge-request/pull-request diff endpoint, whose content can be force-pushed after review (`freetype2-wps`). Sources and checksums are paired by array index the way aurscan's CHK-005 does it, so a real hash on that entry — or a `/commit/<sha>.patch` — means it's pinned and not flagged. Both are also ported to the yay hook (`configs/yay-init.lua`, marker `(v13)`), as warnings.
- Fix: `check_pkgbuild_caches`' non-interactive-`pacman` check (`--noconfirm` from a scriptlet) matched commented-out lines, so a trailing `# sudo pacman -U --noconfirm ./...` build reminder — common in hand-written PKGBUILDs — tripped a WARNING. Reported on the EndeavourOS forum against a stale `~/.cache/yay/timeshift/` tree (timeshift is in `extra`; the cached AUR copy was years old). That pattern now skips whole-line comments, as do the `aur@`, `sudo`/`doas`/`pkexec`, MR/PR-diff and base64-decode-to-shell (Pattern 2 + its yay-hook port) checks — `# install: … | base64 -d | sh` is a real maintainer note. Tor/onion-fetch, system-path-download and printf/rev-tr byte-assembly still scan comment text, since a payload URL or byte-spelled command staged there is never legitimate.
- Fix: two `check_pkgbuild_caches` false positives found in a full scan of all ~111,000 live AUR packages. (1) The printf hex/octal check flagged any `printf` carrying a `\x`/`\0` escape, so `printf '\033[1m…'` ANSI colour output tripped a WARNING (246 packages) — and the yay hook (`configs/yay-init.lua`) hard-*blocked* the install. It now needs an escape that decodes to a letter or digit (a command byte, not an ESC/CSI colour code), or a `printf` whose output is piped to a shell. (2) The `aur@aur.archlinux.org` self-propagation check now skips fully-commented lines — 21 packages carry a `# push this + .SRCINFO to ssh://aur@…` boilerplate note; a real `ssh aur@…` in code still flags.
- Fix: calibrated Patterns 14 and 15 against the same full-AUR scan. Pattern 14 (`sudo`) went from ~500 hits to 121: it was also flagging `.install` scriptlets (already root — a packaging smell, not a fakeroot escape) and counting `sudo -u` (run a step as another user). Pattern 15 (mutable patch URL) went from ~320 to 46: a PR-patch URL with a real checksum is pinned by makepkg's own verification, so it's no longer flagged. The version/URL-mismatch rule from the earlier `(v11)` work is held back for a rework — on the full scan it flagged 800+ packages (rolling `heads/master` tarballs, `$_pkgver`/`$_commit` URL variables, versionless CDN sources) at low precision.
- Fix: the base64/rev-tr/printf pipe-to-shell patterns (2, 4, 7) and their yay-hook ports read `|
This file has been truncated. show original