shinobi-git
The npm install commands are for the project's own dependencies during build, using the source from the official GitLab repository; installing 'pg' is a declared optional dependency for PostgreSQL support, consistent with optdepends.
Triggered rules
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 npm install commands are for the project's own dependencies during build, using the source from the official GitLab repository; installing 'pg' is a declared optional dependency for PostgreSQL support, consistent with optdepends.
1 higher static finding superseded - not the current verdict (shown for transparency)
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:47
npm install --user root -
PKGBUILD:48
npm install --user root pg
PKGBUILD
2 offending line(s) highlighted# Maintainer: AlphaJack <alphajack at tuta dot io>
pkgname="shinobi-git"
pkgver=r3116.07584db3
pkgrel=2
pkgdesc="The Open Source CCTV and NVR Solution"
url="https://shinobi.video/"
license=("custom") # not free for commercial use
arch=("any")
provides=("shinobi")
depends=("ffmpeg" "nodejs")
makedepends=("npm" "git")
optdepends=("mariadb: database"
"postgresql: database"
)
source=("git+https://gitlab.com/Shinobi-Systems/Shinobi.git"
"shinobi-camera.service"
"shinobi-cron.service"
"shinobi.target"
"shinobi.sysusers"
"shinobi.tmpfiles"
"conf.json"
"super.json")
sha256sums=('SKIP'
'da346d9858dafb1a42dd43153d26763de05bc7cdabb5563b979ca62d2cc51ce3'
'adacf7a3ec970e6d5c5d8c339f56bdce3720b952ab7278f31d70a294fd0b5bdd'
'676111c7502ed43671ac5a4451ee0f89913de1c4b4f1e2120cd5c4b89e842757'
'e7c849bfcf8619a093ec75467cf5e44b34cd3621fa0d639bfacf4c88e0bad258'
'a0213eb276dfd468ed835cccceece75da92141716afa4c2426e20a06f64b5625'
'a328e61ddb909cc0216569ed08ee5f4e35ce770da53995ab7d6413479ae8e106'
'b6f2093025736770ed18141eee36b2cd2507142310bb258bf6365c4740c9aae6')
backup=("etc/shinobi/conf.json" "etc/shinobi/super.json")
install="shinobi.install"
options=("!strip")
pkgver(){
cd "Shinobi"
# git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' # -> fatal: No annotated tags can describe '07584db326ba8077f448a8383cc677469a769cbf'.
# git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g' # -> furrykitten.3.r534.g07584db3
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" # -> r3116.07584db3
}
package(){
# no /usr/bin, just systemd files
cd "Shinobi"
# program files
npm install --user root
npm install --user root pg
install -d "$pkgdir/usr/share/shinobi"
cp -r * "$pkgdir/usr/share/shinobi"
# configuration files
install -d -m 750 "$pkgdir/etc/shinobi/"
install -D -m 660 "$srcdir/conf.json" "$pkgdir/etc/shinobi/conf.json"
install -D -m 660 "$srcdir/super.json" "$pkgdir/etc/shinobi/super.json"
ln -s "/etc/shinobi/conf.json" "$pkgdir/usr/share/shinobi"
ln -s "/etc/shinobi/super.json" "$pkgdir/usr/share/shinobi"
# systemd files
install -D -m 644 "$srcdir/shinobi-camera.service" "$pkgdir/usr/lib/systemd/system/shinobi-camera.service"
install -D -m 644 "$srcdir/shinobi-cron.service" "$pkgdir/usr/lib/systemd/system/shinobi-cron.service"
install -D -m 644 "$srcdir/shinobi.target" "$pkgdir/usr/lib/systemd/system/shinobi.target"
install -D -m 644 "$srcdir/shinobi.sysusers" "$pkgdir/usr/lib/sysusers.d/shinobi.conf"
install -D -m 644 "$srcdir/shinobi.tmpfiles" "$pkgdir/usr/lib/tmpfiles.d/shinobi.conf"
# custom license
install -D -m 644 "LICENSE.md" "$pkgdir/usr/share/licenses/shinobi/LICENSE"
# version.json is used by the web server
# https://gitlab.com/Shinobi-Systems/Shinobi/-/issues/23
echo '{"Product" : "Shinobi Professional (Pro)" , "Branch" : "master" , "Version" : "'"$(git rev-parse HEAD)"'" , "Date" : "'"$(date)"'" , "Repository" : "https://gitlab.com/Shinobi-Systems/Shinobi"}' > "$pkgdir/usr/share/shinobi/version.json"
}
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-09-17 00:27:14 | Low | 2 |
| 2026-09-16 00:03:17 | Low | 2 |
| 2026-09-15 00:25:31 | Low | 2 |
| 2026-09-14 00:27:57 | Low | 2 |
| 2026-09-13 00:19:54 | Low | 2 |
| 2026-09-12 00:25:17 | Low | 2 |
| 2026-09-11 00:19:22 | Low | 2 |
| 2026-09-10 00:22:44 | Low | 2 |
| 2026-09-09 00:04:09 | Low | 2 |
| 2026-09-08 00:18:08 | Low | 2 |
| 2026-09-07 00:30:15 | Low | 2 |
| 2026-09-06 00:17:06 | Low | 2 |
| 2026-09-05 00:16:27 | Low | 2 |
| 2026-09-04 00:03:13 | Low | 2 |
| 2026-09-03 00:15:47 | Low | 2 |
| 2026-09-02 00:02:31 | Low | 2 |
| 2026-09-01 00:11:19 | Low | 2 |
| 2026-08-31 00:19:57 | Low | 2 |
| 2026-08-30 00:04:14 | Low | 2 |
| 2026-08-29 00:29:17 | Low | 2 |