boxplayer-bin
maintainer zxp19821005
· 1 votes
· scanned 2026-08-03 00:08:14.047287
MEDIUM
View on AUR ↗
Why flagged
The PKGBUILD runs 'npm install' on external packages (aria2-lib, @motrix/nat-api) during prepare(), which are not declared in source array or verified for integrity, posing a supply-chain risk if the npm registry is compromised or spoofed.
Triggered rules
MEDIUM
npm/yarn/pnpm install of an undeclared external package
npm_install_external
Runs `npm/yarn/pnpm install <package>` for a package not in source=(), pulling unpinned, unreviewed code at build time. Severity downgraded: the package declares/looks like a Node.js consumer, where build-time installs are expected.
-
PKGBUILD:69
npm install aria2-lib @motrix/nat-api --save
MEDIUM
AI review
llm_review
An AI model (qwen/qwen3-235b-a22b-2507) reviewed this and agrees it is MEDIUM (confidence 95%): The PKGBUILD runs 'npm install' on external packages (aria2-lib, @motrix/nat-api) during prepare(), which are not declared in source array or verified for integrity, posing a supply-chain risk if the npm registry is compromised or spoofed.
PKGBUILD
1 offending line(s) highlighted
1
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2
pkgname=boxplayer-bin
3
_pkgname=BoxPlayer
4
pkgver=5.0.11
5
_electronversion=40
6
pkgrel=1
7
pkgdesc="Unified cloud drive management, smart media library, media servers, and high-speed downloads.(Prebuilt version.Use system-wide electron)小白羊网盘 BoxPlayer - 多网盘统一管理 + 智能媒体库 + 媒体服务器 + 高速下载."
8
arch=(
9
'aarch64'
10
'x86_64'
11
)
12
url="https://xbyvideohub.com/"
13
_ghurl="https://github.com/gaozhangmin/boxplayer"
14
license=('GPL-3.0-only')
15
conflicts=("${pkgname%-bin}")
16
provides=("${pkgname%-bin}=${pkgver}")
17
depends=(
18
"electron${_electronversion}"
19
'nodejs'
20
)
21
makedepends=(
22
'asar'
23
'npm'
24
)
25
options=(
26
'!emptydirs'
27
)
28
source=("${pkgname%-bin}.sh")
29
source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.AppImage::${_ghurl}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}-linux-arm64.AppImage")
30
source_x86_64=("${pkgname%-bin}-${pkgver}-x86_64.AppImage::${_ghurl}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}-linux-x86_64.AppImage")
31
sha256sums=('a774c2f54fbbeeaac3cefc0f7250796d30c86d27f0fd40b7eaf9c0fdb021623d')
32
sha256sums_aarch64=('a8abf992b426aacef52479afb7b607e3514c559eb213cc5d72b0bc76f31b7c6b')
33
sha256sums_x86_64=('5b0459588e08a8f4267920c8ac0e62a267b3ebd5f5fe26fcda449428fd30fc78')
34
_get_app_dir() {
35
find "${srcdir}" -type f -name "resources.pak" -exec dirname {} + | head -n 1
36
}
37
_check_electron_version() {
38
echo "Verifying Electron version..."
39
local _main_exe=$(find "$(_get_app_dir)" -maxdepth 1 -type f -executable -printf '%s %p\n' | sort -nr | head -1 | cut -d' ' -f2-)
40
[[ -z "${_main_exe}" ]] && echo -e "\033[1;33mNote: Could not find Electron binary.\033[0m" && return
41
local _elec_ver=$(strings "${_main_exe}" | grep -oP 'Electron/\K[0-9]+' | head -1)
42
[[ -z "${_elec_ver}" ]] && echo -e "\033[1;33mNote: Could not determine Electron version.\033[0m" && return
43
[[ "${_elec_ver}" != "${_electronversion}" ]] &&
44
echo -e "\033[1;31mWarning: Electron version mismatch! Detected: ${_elec_ver}, Expected: ${_electronversion}\033[0m" ||
45
echo -e "Electron version verified: \033[1;31m${_elec_ver}\033[0m"
46
}
47
prepare() {
48
sed -i -e "
49
s/@electronversion@/${_electronversion}/g
50
s/@appname@/${pkgname%-bin}/g
51
s/@runname@/app.asar/g
52
s/@cfgdirname@/${_pkgname}/g
53
" "${srcdir}/${pkgname%-bin}.sh"
54
if [ ! -x "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage" ];then
55
chmod +x "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage"
56
fi
57
if [ -d "${srcdir}/squashfs-root" ];then
58
rm -rf "${srcdir}/squashfs-root"
59
fi
60
"${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage" --appimage-extract > /dev/null
61
_check_electron_version
62
local _app_dir=$(_get_app_dir)
63
sed -i "s/AppRun --no-sandbox/${pkgname%-bin}/g" "${_app_dir}/${pkgname%-bin}.desktop"
64
asar e "${_app_dir}/resources/app.asar" "${srcdir}/app.asar.unpacked"
65
rm -rf "${_app_dir}/resources/app.asar"
66
cd "${srcdir}/app.asar.unpacked"
67
sed -i '/"packageManager"/d' package.json
68
npm config set allow-remote all
69
npm install aria2-lib @motrix/nat-api --save
70
cd - > /dev/null
71
find "${srcdir}/app.asar.unpacked/dist" -type f \
72
-exec sed -i -e "
73
s/process.resourcesPath/\'\/usr\/lib\/${pkgname%-bin}\'/g
74
s/process.execPath/\'\/usr\/lib\/${pkgname%-bin}\'/g\
75
" {} +
76
asar p "${srcdir}/app.asar.unpacked" "${_app_dir}/resources/app.asar"
77
find "${_app_dir}/resources" -type d -perm 700 -exec chmod 755 {} +
78
}
79
package() {
80
install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}"
81
install -Dm755 -d "${pkgdir}/usr/lib/${pkgname%-bin}"
82
local _app_dir=$(_get_app_dir)
83
cp -a "${_app_dir}/resources/"* "${pkgdir}/usr/lib/${pkgname%-bin}/"
84
find "${srcdir}" -type f \( -name "*.png" -o -name "*.svg" \) -path "*share/icons/*" | while read -r _i; do
85
_extension="${_i##*.}"
86
_icon_path="${_i#*share/icons/}"
87
_target_dir="/usr/share/icons/$(dirname "${_icon_path}")"
88
install -Dm644 "${_i}" "${pkgdir}${_target_dir}/${pkgname%-bin}.${_extension}"
89
done
90
install -Dm644 "${_app_dir}/${pkgname%-bin}.desktop" -t "${pkgdir}/usr/share/applications"
91
}
92
Changes since previous scan
--- PKGBUILD @ 2026-07-30 00:17+++ PKGBUILD @ 2026-08-03 00:08@@ -1,7 +1,7 @@ # Maintainer: zxp19821005 <zxp19821005 at 163 dot com> pkgname=boxplayer-bin _pkgname=BoxPlayer-pkgver=5.0.10+pkgver=5.0.11 _electronversion=40 pkgrel=1 pkgdesc="Unified cloud drive management, smart media library, media servers, and high-speed downloads.(Prebuilt version.Use system-wide electron)小白羊网盘 BoxPlayer - 多网盘统一管理 + 智能媒体库 + 媒体服务器 + 高速下载."@@ -29,8 +29,8 @@ source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.AppImage::${_ghurl}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}-linux-arm64.AppImage") source_x86_64=("${pkgname%-bin}-${pkgver}-x86_64.AppImage::${_ghurl}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}-linux-x86_64.AppImage") sha256sums=('a774c2f54fbbeeaac3cefc0f7250796d30c86d27f0fd40b7eaf9c0fdb021623d')-sha256sums_aarch64=('57c7dc19b3c54430eea6540cdeadd504c009aa2405dc339853cfb17ab1f71f3c')-sha256sums_x86_64=('ec34c6729d5f8ce5844041bc225ef9529481cd7b812a2179a547d18f5824825f')+sha256sums_aarch64=('a8abf992b426aacef52479afb7b607e3514c559eb213cc5d72b0bc76f31b7c6b')+sha256sums_x86_64=('5b0459588e08a8f4267920c8ac0e62a267b3ebd5f5fe26fcda449428fd30fc78') _get_app_dir() { find "${srcdir}" -type f -name "resources.pak" -exec dirname {} + | head -n 1 }Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-08-03 00:08:14 | MEDIUM | 2 |
| 2026-08-02 00:16:08 | MEDIUM | 2 |
| 2026-08-01 00:11:18 | MEDIUM | 2 |
| 2026-07-31 00:14:10 | MEDIUM | 2 |
| 2026-07-30 07:14:03 | MEDIUM | 2 |
| 2026-07-30 00:17:23 | MEDIUM | 2 |
| 2026-07-29 07:10:52 | MEDIUM | 2 |
| 2026-07-29 00:25:53 | MEDIUM | 2 |
| 2026-07-28 00:07:28 | MEDIUM | 2 |
| 2026-07-27 09:34:56 | MEDIUM | 2 |
| 2026-07-27 05:34:42 | MEDIUM | 2 |
| 2026-07-21 11:16:59 | CLEAN | 0 |
| 2026-07-21 07:16:26 | CLEAN | 0 |
| 2026-07-20 03:12:42 | CLEAN | 0 |
| 2026-07-15 05:47:53 | CLEAN | 0 |
| 2026-07-14 01:43:48 | CLEAN | 0 |
| 2026-07-13 05:40:50 | CLEAN | 0 |
| 2026-07-09 03:30:04 | CLEAN | 0 |
| 2026-06-25 00:08:41 | CLEAN | 0 |
| 2026-06-24 00:08:06 | LOW | 2 |