apifox-bin

maintainer zxp19821005 · 7 votes · scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged The package downloads a prebuilt AppImage from the official project domain (file-assets.apifox.com) which is plausibly controlled by the vendor; despite the static analyzer flagging the host as non-standard, the source is verifiable and checksummed, and the package installs only extracted files from that AppImage without executing arbitrary remote code.

Triggered rules

LOW AI review downgraded a static finding llm_review

The static rules flagged this MEDIUM, but an AI model (qwen/qwen3-235b-a22b-07-25) reviewed the full PKGBUILD and judged it LOW (confidence 95%): The package downloads a prebuilt AppImage from the official project domain (file-assets.apifox.com) which is plausibly controlled by the vendor; despite the static analyzer flagging the host as non-standard, the source is verifiable and checksummed, and the package installs only extracted files from that AppImage without executing arbitrary remote code.

1 higher static finding superseded - not the current verdict (shown for transparency)
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:34 source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.zip::https://file-assets.apifox.com/download/${_pkgname}-linux-arm64-latest.zip")

PKGBUILD

1 offending line(s) highlighted
1# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2pkgname=apifox-bin
3_pkgname=Apifox
4# 从以下网址确定版本 https://docs.apifox.com/changelog
5pkgver=2.8.37
6_electronversion=37
7pkgrel=1
8pkgdesc="Apifox=Postman+Swagger+Mock+JMeter(Prebuilt version.Use system-wide electron).API 文档、API 调试、API Mock、API 自动化测试"
9arch=(
10 'aarch64'
11 'x86_64'
12)
13url="https://apifox.com/"
14_ghurl="https://github.com/apifox/apifox"
15license=('LicenseRef-custom')
16conflicts=("${pkgname%-bin}")
17provides=("${pkgname%-bin}=${pkgver}")
18depends=(
19 "electron${_electronversion}"
20 'java-runtime'
21 'libxcrypt-compat'
22 'python'
23 'nodejs'
24 'libxml2-legacy'
25 'dbus-glib'
26)
27options=(
28 '!strip'
29)
30source=(
31 #"${pkgname%-bin}.sh"
32 "LICENSE.html"
33)
34source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.zip::https://file-assets.apifox.com/download/${_pkgname}-linux-arm64-latest.zip")
35source_x86_64=("${pkgname%-bin}-${pkgver}-x86_64.zip::https://file-assets.apifox.com/download/${_pkgname}-linux-latest.zip")
36sha256sums=('3884df6451dd5aaadc867c2b6882a7feabccb10c7e1df98e48e9fe2414c9fe19')
37sha256sums_aarch64=('91332624a7f102bbe637c2d6d9d4d35abee2bddab4865540b1cf9300969d5154')
38sha256sums_x86_64=('6c5e9392c5669e2739d699f6c12955044d5c28a8f60f57c4d791d35f8546f60d')
39pkgver() {
40 cd "${srcdir}/squashfs-root"
41 grep "X-AppImage-Version" "${pkgname%-bin}.desktop" | sed "s/X-AppImage-Version=//g"
42}
43_get_app_dir() {
44 find "${srcdir}" -type f -name "resources.pak" -exec dirname {} + | head -n 1
45}
46_check_electron_version() {
47 echo "Verifying Electron version..."
48 local _main_exe=$(find "$(_get_app_dir)" -maxdepth 1 -type f -executable -printf '%s %p\n' | sort -nr | head -1 | cut -d' ' -f2-)
49 [[ -z "${_main_exe}" ]] && echo -e "\033[1;33mNote: Could not find Electron binary.\033[0m" && return
50 local _elec_ver=$(strings "${_main_exe}" | grep -oP 'Electron/\K[0-9]+' | head -1)
51 [[ -z "${_elec_ver}" ]] && echo -e "\033[1;33mNote: Could not determine Electron version.\033[0m" && return
52 [[ "${_elec_ver}" != "${_electronversion}" ]] &&
53 echo -e "\033[1;31mWarning: Electron version mismatch! Detected: ${_elec_ver}, Expected: ${_electronversion}\033[0m" ||
54 echo -e "Electron version verified: \033[1;31m${_elec_ver}\033[0m"
55}
56prepare() {
57 #sed -i -e "
58 # s/@electronversion@/${_electronversion}/g
59 # s/@appname@/${pkgname%-bin}/g
60 # s/@runname@/app.asar/g
61 # s/@cfgdirname@/${pkgname%-bin}/g
62 #" "${srcdir}/${pkgname%-bin}.sh"
63 if [ ! -x "${srcdir}/${_pkgname}"*.AppImage ];then
64 chmod +x "${srcdir}/${_pkgname}"*.AppImage
65 fi
66 if [ -d "${srcdir}/squashfs-root" ];then
67 rm -rf "${srcdir}/squashfs-root"
68 fi
69 "${srcdir}/${_pkgname}"*.AppImage --appimage-extract > /dev/null
70 _check_electron_version
71 sed -i "s/AppRun --no-sandbox/${pkgname%-bin}/g" "${srcdir}/squashfs-root/${pkgname%-bin}.desktop"
72 #find "${srcdir}/squashfs-root/resources/app.asar.unpacked/node_modules" -type d -name ".github" -exec rm -rf {} +
73 rm -rf "${srcdir}/squashfs-root/resources/app.asar.unpacked/node_modules/oracledb/build/Release/"{*darwin*,*win32*}
74 find "${srcdir}/squashfs-root" -type d -perm 700 -exec chmod 755 {} +
75 _file_list=(chrome_100_percent.pak chrome_200_percent.pak chrome-sandbox icudtl.dat libEGL.so libffmpeg.so \
76 libGLESv2.so libvk_swiftshader.so libvulkan.so.1 resources.pak vk_swiftshader_icd.json)
77 for _files in "${_file_list[@]}";do
78 ln -sf "/usr/lib/electron${_electronversion}/${_files}" "${srcdir}/squashfs-root/${_files}"
79 done
80}
81package() {
82 #install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}"
83 #install -Dm644 "${srcdir}/squashfs-root/resources/app.asar" -t "${pkgdir}/usr/lib/${pkgname%-bin}"
84 #cp -Pr --no-preserve=ownership "${srcdir}/squashfs-root/resources/app.asar.unpacked" "${pkgdir}/usr/lib/${pkgname%-bin}"
85 install -Dm755 -d "${pkgdir}/usr/"{bin,lib/"${pkgname%-bin}"}
86 cp -a "${srcdir}/squashfs-root/"* "${pkgdir}/usr/lib/${pkgname%-bin}"
87 ln -sf "/usr/lib/${pkgname%-bin}/${pkgname%-bin}" "${pkgdir}/usr/bin/${pkgname%-bin}"
88 _icon_sizes=(16x16 32x32 48x48 64x64 128x128 256x256 512x512)
89 for _icons in "${_icon_sizes[@]}";do
90 install -Dm644 "${srcdir}/squashfs-root/usr/share/icons/hicolor/${_icons}/apps/${pkgname%-bin}.png" \
91 -t "${pkgdir}/usr/share/icons/hicolor/${_icons}/apps"
92 done
93 install -Dm644 "${srcdir}/squashfs-root/${pkgname%-bin}.desktop" -t "${pkgdir}/usr/share/applications"
94 install -Dm644 "${srcdir}/LICENSE.html" -t "${pkgdir}/usr/share/licenses/${pkgname}"
95}
96

Scan history

Scanned at (UTC)SeverityRules
2026-08-03 00:08:14 LOW 2
2026-08-02 00:16:08 LOW 2
2026-08-01 00:11:18 LOW 2
2026-07-31 00:14:10 LOW 2
2026-07-30 00:17:23 LOW 2
2026-07-29 00:25:53 LOW 2
2026-07-28 00:07:28 LOW 2
2026-07-27 00:24:32 LOW 2
2026-07-26 00:07:32 LOW 2
2026-07-25 00:13:44 LOW 2
2026-07-24 00:02:28 LOW 2
2026-07-23 00:14:47 LOW 2
2026-07-22 00:29:32 LOW 2
2026-07-21 00:24:15 LOW 2
2026-07-20 00:19:49 LOW 2
2026-07-19 00:17:08 LOW 2
2026-07-18 00:14:48 LOW 2
2026-07-17 00:06:16 LOW 2
2026-07-16 00:05:41 LOW 2
2026-07-15 00:09:25 LOW 2

Report a package

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

0 / 4000
Your suggestion