godmode
maintainer zxp19821005
· 1 votes
· scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged
The npx command is used to run a local build script (ts-node clean.js) during packaging, not to execute arbitrary remote code; the source is from the project's own repository and the build process is standard for an Electron app.
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 npx command is used to run a local build script (ts-node clean.js) during packaging, not to execute arbitrary remote code; the source is from the project's own repository and the build process is standard for an Electron app.
1 higher static finding superseded - not the current verdict (shown for transparency)
MEDIUM
npx/bunx/deno executes a remote package
remote_code_tool
`npx`/`bunx`/`pnpm dlx`/`deno run <url>` downloads AND runs a remote package at build time — the moral equivalent of piping a download into a shell. Severity downgraded: Node.js consumer context.
-
PKGBUILD:69
NODE_ENV=production npx ts-node ./scripts/scripts/clean.js dist
PKGBUILD
1 offending line(s) highlighted
1
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2
pkgname=godmode
3
_pkgname=GodMode
4
pkgver=1.0.0_beta.10
5
_electronversion=26
6
_nodeversion=18
7
pkgrel=8
8
pkgdesc="AI Chat Browser: Fast, Full webapp access to ChatGPT / Claude / Bard / Bing / Llama2!(Use system-wide electron)"
9
arch=('any')
10
url="https://smol.ai/"
11
_ghurl="https://github.com/smol-ai/GodMode"
12
license=('MIT')
13
depends=(
14
"electron${_electronversion}"
15
)
16
makedepends=(
17
'npm'
18
'gendesk'
19
'nvm'
20
'curl'
21
'git'
22
)
23
source=(
24
"${pkgname}-${pkgver}::git+${_ghurl}#tag=v${pkgver//_/-}"
25
"${pkgname}.sh"
26
)
27
sha256sums=('16cf9940c7415642a76b2cf74b48cf7dfdc5c5b723e26ee18d9fcb8bf0b00d7d'
28
'291f50480f5a61bc9c68db7d44cd0412071128706baa868a9cb854f8779a1980')
29
_ensure_local_nvm() {
30
local NVM_DIR="${srcdir}/.nvm"
31
source /usr/share/nvm/init-nvm.sh || [[ $? != 1 ]]
32
nvm install "${_nodeversion}"
33
nvm use "${_nodeversion}"
34
}
35
prepare() {
36
sed -e "
37
s/@electronversion@/${_electronversion}/g
38
s/@appname@/${pkgname}/g
39
s/@runname@/app.asar/g
40
s/@cfgdirname@/${_pkgname}/g
41
s/@options@/env ELECTRON_OZONE_PLATFORM_HINT=auto/g
42
" -i "${srcdir}/${pkgname}.sh"
43
_ensure_local_nvm
44
gendesk -q -f -n --pkgname="${pkgname}" --pkgdesc="${pkgdesc}" --categories="Utility" --name="${_pkgname}" --exec="${pkgname} %U"
45
cd "${srcdir}/${pkgname}-${pkgver}"
46
export ELECTRON_SKIP_BINARY_DOWNLOAD=1
47
export SYSTEM_ELECTRON_VERSION="$(electron${_electronversion} -v | sed 's/v//g')"
48
HOME="${srcdir}/.electron-gyp"
49
{
50
echo -e '\n'
51
#echo 'build_from_source=true'
52
echo "cache=${srcdir}/.npm_cache"
53
} >> .npmrc
54
if [[ "$(curl -s ipinfo.io/country)" == *"CN"* ]]; then
55
{
56
echo 'registry=https://registry.npmmirror.com'
57
echo 'electron_mirror=https://registry.npmmirror.com/-/binary/electron/'
58
echo 'electron_builder_binaries_mirror=https://registry.npmmirror.com/-/binary/electron-builder-binaries/'
59
} >> .npmrc
60
find ./ -type f -name "package-lock.json" -exec sed -i "s/registry.npmjs.org/registry.npmmirror.com/g" {} +
61
fi
62
find src -type f -exec sed -i "s/process.resourcesPath/\'\/usr\/lib\/${pkgname}\'/g" {} +
63
sed -i "s/\"electron\": \"[^\"]*\"/\"electron\": \"${SYSTEM_ELECTRON_VERSION}\"/g" package.json
64
NODE_ENV=development npm install
65
}
66
build() {
67
cd "${srcdir}/${pkgname}-${pkgver}"
68
local electronDist="/usr/lib/electron${_electronversion}"
69
NODE_ENV=production npx ts-node ./scripts/scripts/clean.js dist
70
NODE_ENV=production npm run build
71
NODE_ENV=production npm exec -c "electron-builder --linux dir -c.electronDist=${electronDist}"
72
}
73
package() {
74
install -Dm755 "${srcdir}/${pkgname}.sh" "${pkgdir}/usr/bin/${pkgname}"
75
install -Dm644 "${srcdir}/${pkgname}-${pkgver}/release/build/linux-"*/resources/app.asar -t "${pkgdir}/usr/lib/${pkgname}"
76
cp -Pr --no-preserve=ownership "${srcdir}/${pkgname}-${pkgver}/release/build/linux-"*/resources/assets "${pkgdir}/usr/lib/${pkgname}"
77
_icon_sizes=(16x16 24x24 32x32 48x48 64x64 96x96 128x128 256x256 512x512 1024x1024)
78
for _icons in "${_icon_sizes[@]}";do
79
install -Dm644 "${srcdir}/${pkgname}-${pkgver}/release/build/linux-"*/resources/assets/icons/${_icons}.png \
80
"${pkgdir}/usr/share/icons/hicolor/${_icons}/apps/${pkgname}.png"
81
done
82
install -Dm644 "${srcdir}/${pkgname}.desktop" -t "${pkgdir}/usr/share/applications"
83
install -Dm644 "${srcdir}/${pkgname}-${pkgver}/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}"
84
}
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 |