baize-toolbox-git
maintainer zxp19821005
· 0 votes
· scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged
The pnpm install fetches only declared development dependencies and the project's own dependencies from npm, using locked mirrors in China; no untrusted remote code execution or hidden payloads are present.
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 pnpm install fetches only declared development dependencies and the project's own dependencies from npm, using locked mirrors in China; no untrusted remote code execution or hidden payloads are present.
1 higher static finding superseded - not the current verdict (shown for transparency)
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:80
NODE_ENV=development pnpm install -D @ant-design/icons classnames conf
PKGBUILD
1 offending line(s) highlighted
1
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2
pkgname=baize-toolbox-git
3
_pkgname='白泽工具箱'
4
pkgver=1.0.0.beta1.r4.g51b3cca
5
_electronversion=31
6
_nodeversion=20
7
pkgrel=1
8
pkgdesc="A powerful multimedia tool that provides users with a variety of multimedia processing capabilities.(Use system-wide electron)一款功能强大的多媒体工具,为用户提供了多种多样的多媒体处理功能。"
9
arch=('any')
10
url="https://baize.plume.vip/"
11
_ghurl="https://github.com/baizeteam/baize-toolbox"
12
license=("LGPL-3.0-only")
13
conflicts=("${pkgname%-git}")
14
provides=("${pkgname%-git}=${pkgver%.r*}")
15
depends=(
16
"electron${_electronversion}"
17
'ffmpeg'
18
'nodejs'
19
)
20
makedepends=(
21
'npm'
22
'pnpm'
23
'git'
24
'nvm'
25
'gendesk'
26
'icoutils'
27
)
28
source=(
29
"${pkgname%-git}.git::git+${_ghurl}.git"
30
"${pkgname%-git}.sh"
31
)
32
sha256sums=('SKIP'
33
'291f50480f5a61bc9c68db7d44cd0412071128706baa868a9cb854f8779a1980')
34
pkgver() {
35
cd "${srcdir}/${pkgname%-git}.git"
36
set -o pipefail
37
git describe --long --tags --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/v//g' ||
38
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short=7 HEAD)"
39
}
40
_ensure_local_nvm() {
41
local NVM_DIR="${srcdir}/.nvm"
42
source /usr/share/nvm/init-nvm.sh || [[ $? != 1 ]]
43
nvm install "${_nodeversion}"
44
nvm use "${_nodeversion}"
45
}
46
prepare() {
47
cd "${srcdir}/${pkgname%-git}.git"
48
sed -i -e "
49
s/@electronversion@/${_electronversion}/g
50
s/@appname@/${pkgname%-git}/g
51
s/@runname@/app.asar/g
52
s/@cfgdirname@/${pkgname%-git}/g
53
s/@options@/env ELECTRON_OZONE_PLATFORM_HINT=auto/g
54
" "${srcdir}/${pkgname%-git}.sh"
55
_ensure_local_nvm
56
gendesk -q -f -n --pkgname="${pkgname%-git}" --pkgdesc="${pkgdesc}" --categories="AudioVideo" --name="${_pkgname}" --exec="${pkgname%-git} --no-sandbox %U"
57
export ELECTRON_SKIP_BINARY_DOWNLOAD=1
58
export SYSTEM_ELECTRON_VERSION="$(electron${_electronversion} -v | sed 's/v//g')"
59
HOME="${srcdir}/.electron-gyp"
60
{
61
echo -e '\n'
62
#echo 'build_from_source=true'
63
echo 'link-workspace-packages=true'
64
echo 'fetch-retry-maxtimeout=10000'
65
echo "cache-dir="${srcdir}"/.pnpm_cache"
66
echo "store-dir="${srcdir}"/.pnpm_store"
67
echo "shamefully-hoist=true"
68
echo "virtual-store-dir-max-length=80"
69
echo "node-linker=hoisted"
70
echo "network-concurrency=10"
71
} >> .npmrc
72
if [[ "$(curl -s ipinfo.io/country)" == *"CN"* ]]; then
73
{
74
echo 'registry=https://registry.npmmirror.com'
75
echo 'electron_mirror=https://cdn.npmmirror.com/binaries/electron/'
76
echo 'electron_builder_binaries_mirror=https://npmmirror.com/mirrors/electron-builder-binaries/'
77
} >> .npmrc
78
fi
79
sed -i "s/\"electron\": \"[^\"]*\"/\"electron\": \"${SYSTEM_ELECTRON_VERSION}\"/g" package.json
80
NODE_ENV=development pnpm install -D @ant-design/icons classnames conf
81
NODE_ENV=development pnpm install
82
}
83
build() {
84
cd "${srcdir}/${pkgname%-git}.git"
85
local electronDist="/usr/lib/electron${_electronversion}"
86
NODE_ENV=production pnpm run build
87
NODE_ENV=production pnpm -c exec "electron-builder --linux dir -c.electronDist=${electronDist} --config electron-builder.yml"
88
}
89
package() {
90
install -Dm755 "${srcdir}/${pkgname%-git}.sh" "${pkgdir}/usr/bin/${pkgname%-git}"
91
install -Dm644 "${srcdir}/${pkgname%-git}.git/dist/linux-"*/resources/app.asar -t "${pkgdir}/usr/lib/${pkgname%-git}"
92
cp -Pr --no-preserve=ownership "${srcdir}/${pkgname%-git}.git/dist/linux-"*/resources/app.asar.unpacked "${pkgdir}/usr/lib/${pkgname%-git}"
93
install -Dm755 -d "${pkgdir}/usr/lib/${pkgname%-git}/app.asar.unpacked/resources/linux"
94
ln -sf "/usr/bin/ffmpeg" "${pkgdir}/usr/lib/${pkgname%-git}/app.asar.unpacked/resources/linux/ffmpeg"
95
install -Dm644 "${srcdir}/${pkgname%-git}.git/resources/icon.png" "${pkgdir}/usr/share/pixmaps/${pkgname%-git}.png"
96
install -Dm644 "${srcdir}/${pkgname%-git}.git/${pkgname%-git}.desktop" -t "${pkgdir}/usr/share/applications"
97
install -Dm644 "${srcdir}/${pkgname%-git}.git/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}"
98
}
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 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 |