qsc-cli

LOW
maintainer KarthikJay 0 votes scanned 2026-10-22 00:13:10.488046
View on AUR
Why flagged

Downloads a prebuilt .deb from softwarecenter.qualcomm.com, which is Qualcomm's own official domain, with a pinned SHA-256 checksum; the prepare() patches are in-place fixes for Arch compatibility (VERSION_ID fallback, RUNPATH hardening), not malicious modifications; no exfiltration, obfuscation, or redirection to unrelated hosts observed.

Triggered rules

Low Few votes, recently uploaded zero_votes_recent

Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.

Low AI review downgraded a static finding llm_review

The static rules flagged this MEDIUM, but an AI model (anthropic/claude-sonnet-4.6) reviewed the full PKGBUILD and judged it LOW (confidence 80%): Downloads a prebuilt .deb from softwarecenter.qualcomm.com, which is Qualcomm's own official domain, with a pinned SHA-256 checksum; the prepare() patches are in-place fixes for Arch compatibility (VERSION_ID fallback, RUNPATH hardening), not malicious modifications; no exfiltration, obfuscation, or redirection to unrelated hosts observed.

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:63 source=("$pkgname-$pkgver.deb::https://softwarecenter.qualcomm.com/api/download/software/tools/Qualcomm_Software_Center/Linux/Debian/$pkgver/QualcommSoftwareCenter$pkgver.Linux-x86.deb"

PKGBUILD

1 offending line(s) highlighted
1# Maintainer: Karthik Jayakumar <valliyilkarthik@gmail.com>
2
3pkgname=qsc-cli
4pkgver=1.28.3
5pkgrel=1
6pkgdesc="Qualcomm Software Center CLI, with QIK and the QSC desktop app"
7arch=('x86_64')
8url="https://softwarecenter.qualcomm.com/"
9license=('LicenseRef-Qualcomm' 'MIT' 'Apache-2.0')
10depends=(
11 # qsc-cli, qik and the libraries bundled for tools QSC installs
12 'bash'
13 'ca-certificates'
14 'e2fsprogs'
15 'fontconfig'
16 'glibc'
17 'gnutls'
18 'icu'
19 'libgcc'
20 'libsasl'
21 'libstdc++'
22 'libxcrypt-compat'
23 'openssl'
24 'polkit'
25 'sqlite'
26 'sudo'
27 'util-linux-libs'
28 'xdg-utils'
29 'zlib'
30 # Desktop app (Electron)
31 'alsa-lib'
32 'at-spi2-core'
33 'cairo'
34 'dbus'
35 'expat'
36 'glib2'
37 'gtk3'
38 'libcups'
39 'libx11'
40 'libxcb'
41 'libxcomposite'
42 'libxdamage'
43 'libxext'
44 'libxfixes'
45 'libxkbcommon'
46 'libxrandr'
47 'mesa'
48 'nspr'
49 'nss'
50 'pango'
51 'systemd-libs'
52)
53makedepends=('patchelf' 'perl')
54# Upstream's dependencies_installer.sh apt-installs these for chip-software
55optdepends=('android-tools: adb and fastboot for chip-software device and flash'
56 'docker: chip-software compile and open-build-env run in containers'
57 'git: workspace setup for chip-software compile'
58 'python: build scripts run by chip-software compile'
59 'unzip: unpacking downloaded builds')
60conflicts=('qualcomm-software-center' 'qualcommsoftwarecenter')
61options=('!strip' '!debug') # Node SEA and .NET single-file binaries carry appended payloads
62install=$pkgname.install
63source=("$pkgname-$pkgver.deb::https://softwarecenter.qualcomm.com/api/download/software/tools/Qualcomm_Software_Center/Linux/Debian/$pkgver/QualcommSoftwareCenter$pkgver.Linux-x86.deb"
64 LICENSE.Qualcomm
65 $pkgname.tmpfiles)
66noextract=("$pkgname-$pkgver.deb")
67sha256sums=('b53377df60621c9660a42f1e91f0b3d1453002a59c43cbd9976cacadc6dfa95b'
68 '5a3947b37a2f86749407785914abca3d1befcecb3a45d3767e2e41cdcb33af8c'
69 'deb6336a82682c896075aa383ba0cb7bd99c3318624c96ad9eaf67f4ce38295b')
70
71_bin=/opt/qcom/softwarecenter/bin
72_deps=/opt/qcom/tools-common/libs/system-deps # RUNPATH of the bundled libs
73
74# Replace one exact byte string with another of the same length, so offsets
75# inside single-file executables stay valid
76_patch_bytes() {
77 perl -0777 -pi -e '
78 BEGIN { ($o, $n) = splice @ARGV, 0, 2; length($o) == length($n) or die "length mismatch\n" }
79 ($c = s/\Q$o\E/$n/g) == 1 or die "expected 1 match, found " . ($c || 0) . "\n";
80 ' "$2" "$3" "$1"
81}
82
83prepare() {
84 rm -rf deb && mkdir -p deb/control
85 bsdtar -xOf "$pkgname-$pkgver.deb" 'control.tar.*' | bsdtar -xf - -C deb/control
86 bsdtar -xOf "$pkgname-$pkgver.deb" 'data.tar.*' | bsdtar -xf - -C deb
87
88 local _ver
89 _ver=$(sed -n 's/^Version: //p' deb/control/control)
90 if [[ $_ver != "$pkgver" ]]; then
91 error "The .deb is QSC $_ver, not $pkgver"
92 return 1
93 fi
94
95 cd "deb$_bin"
96
97 # Arch's /etc/os-release has no VERSION_ID, which makes every qsc-cli command
98 # (even --version) and the desktop app's server throw at startup. Fall back to
99 # "", which makes them leave the host OS filter out of backend queries.
100 # qsc-cli is a Node SEA binary, so its embedded JS is patched in place; the
101 # shorter quote-stripping regex makes room for the fallback.
102 _patch_bytes qsc-cli/qsc-cli \
103 'distribution:t.get("NAME").replace(/^"|"$/g,""),version:t.get("VERSION_ID").replace(/^"|"$/g,"")' \
104 'distribution:t.get("NAME").replace(/"/g,""),version:(t.get("VERSION_ID")||"").replace(/"/g,"") '
105 sed -i 's/osReleaseInfoMap\.get("VERSION_ID")\.replace/(osReleaseInfoMap.get("VERSION_ID") || "").replace/' \
106 resources/app/dist/start-server.js
107 if grep -q 'version: osReleaseInfoMap\.get("VERSION_ID")' resources/app/dist/start-server.js; then
108 error "start-server.js VERSION_ID patch did not apply"
109 return 1
110 fi
111
112 # qik's RUNPATH starts with /tmp/qikv3sfx, where any local user could plant
113 # libraries that load when qik runs as root. Drop it; the shorter RUNPATH is
114 # rewritten in place, which keeps the .NET single-file bundle intact.
115 local _size
116 _size=$(stat -c %s qik/qik)
117 patchelf --set-rpath /opt/qcom/tools-common/libs/openssl3.0.0:$_deps/ qik/qik
118 if [[ $(stat -c %s qik/qik) != "$_size" ]]; then
119 error "patchelf resized qik"
120 return 1
121 fi
122}
123
124build() {
125 # The bundled libldap needs libsasl2.so.2 with symbol version SASL2. Arch
126 # ships the same library as libsasl2.so.3 without versioning, so this stub
127 # defines SASL2 and pulls in the real library, where the symbols then resolve
128 # (a plain symlink works too, but warns on every run).
129 echo 'SASL2 { local: *; };' > sasl2.map
130 gcc -shared -o libsasl2.so.2 -Wl,-soname,libsasl2.so.2 \
131 -Wl,--version-script=sasl2.map -x c /dev/null -Wl,--no-as-needed -lsasl2
132
133 # QIK's record of QSC itself, as upstream's postinst writes it; the install
134 # scriptlet copies it into /var/lib/qcom/data/qik/components
135 local _date
136 _date=$(date -d "@${SOURCE_DATE_EPOCH:-$(date +%s)}" '+%Y-%m-%d %H:%M:%S')
137 cat > qikcomponent_abc31016-7831-11ee-b4ae-026b10d3716b.dat <<EOF
138{"Branch":null,"ComponentID":"abc31016-7831-11ee-b4ae-026b10d3716b","ComponentName":"Qualcomm_Software_Center.Core","ComponentType":"Core","DependsOn":null,"Description":"Qualcomm_Software_Center.Core","FeatureID":"ab64288f-7831-11ee-b4ae-026b10d3716b","FeatureName":"Core","GUID":"3b59d03c-d624-4c78-ad52-a516b8ec85b4","InstallLocation":"\/opt\/qcom\/softwarecenter\/bin","InstallLocationRoot":"\/opt\/qcom\/softwarecenter","InstallationDate":"$_date","MultipleVersions":0,"Name":"Qualcomm® Software Center","ProductID":"ab2423ae-7831-11ee-b4ae-026b10d3716b","ProductName":"Qualcomm_Software_Center","PublishedDate":"2024-02-23 13:31:44","Publisher":"Qualcomm Technologies, Inc.","ReferenceCounter":0,"RequiredBy":null,"SpaceReq":"","Subtitle":"Qualcomm® Software Center","Version":"$pkgver","packageFile":""}
139EOF
140}
141
142package() {
143 local _deb="$srcdir/deb"
144
145 install -d "$pkgdir/opt/qcom"
146 cp -a --no-preserve=ownership "$_deb/opt/qcom/softwarecenter" "$pkgdir/opt/qcom/"
147 # OpenSSL 3.0.0 copy that nothing loads; everything uses the system libcrypto
148 rm "$pkgdir$_bin"/qik/lib{ssl,crypto}.so.3
149
150 # Libraries for tools that QSC installs, which look in either directory.
151 # The bundled OpenSSL 3.0.0 is left out here too.
152 install -Dm755 "$_deb"/tmp/qcom/qsc_installer/external-dependencies/libs/system-deps/* \
153 "$srcdir/libsasl2.so.2" -t "$pkgdir$_deps/"
154 install -d "$pkgdir/opt/qcom/QPM3/bin"
155 ln -s "$_deps" "$pkgdir/opt/qcom/QPM3/bin/system-deps"
156
157 install -d "$pkgdir/opt/qcom/qik3/bin"
158 ln -s "$_bin/qik/qik" "$pkgdir/opt/qcom/qik3/bin/qik"
159
160 install -d "$pkgdir/usr/bin"
161 ln -s "$_bin/qsc-cli/qsc-cli.sh" "$pkgdir/usr/bin/qsc-cli"
162 ln -s "$_bin/qik/qik" "$pkgdir/usr/bin/qikv3" # the desktop app looks for qikv3 in /usr/bin
163
164 install -Dm644 "$srcdir"/qikcomponent_*.dat -t "$pkgdir/usr/share/$pkgname/qik-components/"
165 install -Dm644 "$srcdir/$pkgname.tmpfiles" "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
166
167 install -Dm644 "$_deb/usr/share/applications/qualcommsoftwarecenter.desktop" -t "$pkgdir/usr/share/applications/"
168 install -Dm644 "$_deb/usr/share/pixmaps/qualcommsoftwarecenter.png" -t "$pkgdir/usr/share/pixmaps/"
169
170 install -Dm644 "$_deb/usr/share/doc/softwarecenter/NOTICE.txt" -t "$pkgdir/usr/share/doc/$pkgname/"
171 install -Dm644 "$_deb/usr/share/doc/softwarecenter/html/license.html" -t "$pkgdir/usr/share/doc/$pkgname/html/"
172
173 install -Dm644 "$srcdir/LICENSE.Qualcomm" -t "$pkgdir/usr/share/licenses/$pkgname/"
174 install -Dm644 "$_deb$_bin/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.electron"
175 install -Dm644 "$_deb/opt/qcom/softwarecenter/cosign/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.cosign"
176 ln -s "$_bin/LICENSES.chromium.html" "$pkgdir/usr/share/licenses/$pkgname/"
177}
178

Scan history

Scanned at (UTC)SeverityRules
2026-10-22 00:13:10 Low 3
2026-10-21 01:31:15 Low 3
2026-10-21 01:29:42 Medium 2

Report a package

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

0 / 4000
Your suggestion