spflashtool-standalone

MEDIUM
maintainer orphaned 4 votes scanned 2026-09-17 00:27:14.276658
View on AUR
Why flagged

The package downloads a prebuilt binary ZIP from spflashtools.com, which is a third-party WordPress-based site (not the official MediaTek or official SP Flash Tool distribution channel). The binary is executed directly on the user's system (flash_tool, a native Linux executable). The Referer header requirement is a minor oddity but not inherently malicious — it's common on WordPress download sites. The sha256sum is present and pinned, which mitigates substitution risk somewhat, but the source is still an unofficial redistributor of a closed-source binary tool. This is a genuine medium-severity supply-chain concern: a prebuilt closed-source binary from an unofficial third-party host with no way to verify it matches any authoritative upstream release. The risk is real but not evidence of active malice.

Triggered rules

Medium source=() URL on a non-standard host source_untrusted_domain

One or more source=() URLs point to a host outside the trusted allowlist (github.com, gitlab.com, codeberg.org, pypi.org, …).

  • PKGBUILD:12 source=("https://spflashtools.com/wp-content/uploads/SP_Flash_Tool_v${pkgver}_Linux.zip"
Medium AI review llm_review

An AI model (anthropic/claude-4.6-sonnet-20260217) reviewed this and agrees it is MEDIUM (confidence 72%): The package downloads a prebuilt binary ZIP from spflashtools.com, which is a third-party WordPress-based site (not the official MediaTek or official SP Flash Tool distribution channel). The binary is executed directly on the user's system (flash_tool, a native Linux executable). The Referer header requirement is a minor oddity but not inherently malicious — it's common on WordPress download sites. The sha256sum is present and pinned, which mitigates substitution risk somewhat, but the source is still an unofficial redistributor of a closed-source binary tool. This is a genuine medium-severity supply-chain concern: a prebuilt closed-source binary from an unofficial third-party host with no way to verify it matches any authoritative upstream release. The risk is real but not evidence of active malice.

PKGBUILD

1 offending line(s) highlighted
1pkgname=spflashtool-standalone
2_pkgname=spflashtool
3pkgver="5.2044"
4pkgrel=1
5pkgdesc="SP Flash Tool is an application to flash your MediaTek (MTK) SmartPhone. (standalone)"
6arch=('x86_64')
7url="https://spflashtools.com/category/linux"
8license=('unknown')
9makedepends=('gendesk')
10provides=('spflashtool')
11conflicts=('spflashtool' 'spflashtool-bin' 'spflashtool-noqtdeps')
12source=("https://spflashtools.com/wp-content/uploads/SP_Flash_Tool_v${pkgver}_Linux.zip"
13 'spflashtool.png')
14sha256sums=('3d0c08f3c4a46abbd79bdbb1b9cd1d44410d95da8afec2327d079538f19c2199'
15 'fe0b9c1de77c687623bfc07733041d1387f755493cdf904e6afcb47f784d34c7')
16
17# Workaround for source file download, which requires the 'Referer' header to be set
18DLAGENTS=('https::/usr/bin/curl -fLC - --retry 3 --retry-delay 3 -e '"${url}"' -o %o %u')
19
20prepare() {
21 # Create .desktop file.
22 gendesk -f -n \
23 --pkgname "${_pkgname}" \
24 --pkgdesc "${pkgdesc}" \
25 --name "SP Flash Tool" \
26 --genericname "Firmware Flasher" \
27 --comment "MediaTek (MTK) Firmware Flasher" \
28 --exec "/usr/bin/${_pkgname}" \
29 --categories "System;"
30}
31
32package() {
33 # Install files
34 mkdir -p "${pkgdir}/opt/${_pkgname}/"
35 bsdtar -xf "SP_Flash_Tool_v${pkgver}_Linux.zip" -C "${pkgdir}/opt/${_pkgname}/" --strip-components=1
36
37 # Overwrite flash_tool.sh
38 echo '#!/usr/bin/env sh
39
40execfile=$(readlink -f "$0" | sed "s/\.sh$//")
41dirname=$(dirname "$execfile")
42
43LD_LIBRARY_PATH="$dirname":"$dirname/lib"
44export LD_LIBRARY_PATH
45
46"$execfile" "$@"' \
47 > "${pkgdir}/opt/${_pkgname}/flash_tool.sh"
48
49 # Mark the binaries as executable
50 chmod +x "${pkgdir}/opt/${_pkgname}/"{flash_tool,flash_tool.sh,bin/assistant}
51
52 # Excutable in PATH
53 mkdir -p "${pkgdir}/usr/bin/"
54 ln -sf "/opt/${_pkgname}/flash_tool.sh" "${pkgdir}/usr/bin/${_pkgname}"
55
56 # Desktop file and icon
57 install -Dm644 "${srcdir}/${_pkgname}.png" "${pkgdir}/usr/share/pixmaps/${_pkgname}.png"
58 install -Dm644 "${srcdir}/${_pkgname}.desktop" "${pkgdir}/usr/share/applications/${_pkgname}.desktop"
59
60 # Remove udev rule (package modemmanager contains this rule)
61 rm "${pkgdir}/opt/${_pkgname}/99-ttyacms.rules"
62}
63

Scan history

Scanned at (UTC)SeverityRules
2026-09-17 00:27:14 Medium 2
2026-09-16 00:03:17 Medium 2
2026-09-15 00:25:31 Medium 2
2026-09-14 00:27:57 Medium 2
2026-09-13 00:19:54 Medium 2
2026-09-12 00:25:17 Medium 2
2026-09-11 00:19:22 Medium 2
2026-09-10 00:22:44 Medium 2
2026-09-09 00:04:09 Medium 2
2026-09-08 00:18:08 Medium 2
2026-09-07 00:30:15 Medium 2
2026-09-06 00:17:06 Medium 2
2026-09-05 00:16:27 Medium 2
2026-09-04 00:03:13 Medium 2
2026-09-03 00:15:47 Medium 2
2026-09-02 00:02:31 Medium 2
2026-09-01 00:11:19 Medium 2
2026-08-31 00:19:57 Medium 2
2026-08-30 00:04:14 Medium 2
2026-08-29 00:29:17 Medium 2

Report a package

Reports go to the AURWatch maintainer (one person) and are read by hand. No login required.

0 / 4000
Your suggestion