tradingview

maintainer xiota · 37 votes · scanned 2026-08-03 00:08:14.047287
LOW
View on AUR ↗
Why flagged The package downloads a Snap file from the official Snapcraft API and extracts it; this is a standard, verifiable source for official software, not a swappable host, and the binary content is from the project's own distribution, making the risk low despite the non-whitelisted domain.

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 package downloads a Snap file from the official Snapcraft API and extracts it; this is a standard, verifiable source for official software, not a swappable host, and the binary content is from the project's own distribution, making the risk low despite the non-whitelisted domain.

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:31 "$_pkgsrc.snap"::"https://api.snapcraft.io/api/v1/snaps/download/${_snap_id}_${_snap_rev}.snap"
  • PKGBUILD:32 "$_terms_of_use.html"::"https://www.tradingview.com/policies/"

PKGBUILD

2 offending line(s) highlighted
1# Maintainer:
2# Contributor: Ivan Gabaldon <aur[at]inetol.net>
3# Contributor: archlinuxbits <archlinuxbits at proton.me>
4
5: ${_snap_id:=nJdITJ6ZJxdvfu8Ch7n5kH5P99ClzBYV}
6: ${_snap_rev:=72}
7
8_pkgname="tradingview"
9pkgname="$_pkgname"
10pkgver=3.3.0
11pkgrel=1
12pkgdesc='Charting platform for traders and investors'
13arch=('x86_64')
14url="https://www.tradingview.com/desktop/"
15license=('LicenseRef-TradingView')
16
17depends=(
18 'libsecret'
19)
20makedepends=(
21 'html-xml-utils'
22 'squashfs-tools'
23 'w3m'
24)
25
26options=('!debug' '!strip')
27
28_terms_of_use="$_pkgname-$pkgver-$_snap_rev-eula"
29_pkgsrc="$_pkgname-$pkgver-$_snap_rev"
30source=(
31 "$_pkgsrc.snap"::"https://api.snapcraft.io/api/v1/snaps/download/${_snap_id}_${_snap_rev}.snap"
32 "$_terms_of_use.html"::"https://www.tradingview.com/policies/"
33)
34sha256sums=(
35 'e4343ff1a62a67a75f05720d4762392f44fa0c70ecf4858049366632043bf118'
36 'SKIP'
37)
38
39prepare() {
40 hxextract .tv-policies "$_terms_of_use.html" \
41 1> "$_terms_of_use-2.html" \
42 2> /dev/null
43
44 w3m -O UTF-8 -cols 80 -dump "$_terms_of_use-2.html" > "$_terms_of_use.txt"
45
46 # unpack
47 mkdir -p "$_pkgsrc"
48 unsquashfs -q -n -f -d "$_pkgsrc/" "$_pkgsrc.snap"
49}
50
51package() {
52 local _electron_version=$(strings "$_pkgsrc/tradingview" | grep -Pom1 'Electron/\K[0-9]+')
53 depends+=("electron${_electron_version}")
54
55 # asar
56 mkdir -pm755 "$pkgdir/usr/lib/$_pkgname"
57 cp -r "$_pkgsrc/resources/"* "$pkgdir/usr/lib/$_pkgname/"
58
59 # launcher
60 sed -E -e '/^Comment=/d' \
61 -e 's&^(Icon)=.*$&\1='"$_pkgname&" \
62 -e 's&^(Categories)=(Finance;)$&\1=Office;\2&' \
63 -i "$_pkgsrc/meta/gui/$_pkgname.desktop"
64
65 install -Dm644 "$_pkgsrc/meta/gui/$_pkgname.desktop" -t "$pkgdir/usr/share/applications/"
66
67 # icon
68 install -Dm644 "$_pkgsrc/meta/gui/icon.png" "$pkgdir/usr/share/icons/hicolor/512x512/apps/$_pkgname.png"
69
70 # license
71 install -Dm644 "$_terms_of_use.txt" -t "$pkgdir/usr/share/licenses/$pkgname/"
72
73 # script
74 install -Dm755 /dev/stdin "$pkgdir/usr/bin/$_pkgname" << END
75#!/usr/bin/env bash
76
77name=$_pkgname
78flags_file="\${XDG_CONFIG_HOME:-\$HOME/.config}/\${name}-flags.conf"
79
80lines=()
81if [[ -f "\${flags_file}" ]]; then
82 mapfile -t lines < "\${flags_file}"
83fi
84
85flags=()
86for line in "\${lines[@]}"; do
87 if [[ ! "\${line}" =~ ^[[:space:]]*#.* ]] && [[ -n "\${line}" ]]; then
88 flags+=("\${line}")
89 fi
90done
91
92: \${ELECTRON_IS_DEV:=0}
93export ELECTRON_IS_DEV
94: \${ELECTRON_FORCE_IS_PACKAGED:=true}
95export ELECTRON_FORCE_IS_PACKAGED
96
97exec electron${_electron_version} "\${flags[@]}" "/usr/lib/$_pkgname/app.asar" "\$@"
98END
99}
100

Scan history

Scanned at (UTC)SeverityRules
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

Report a package

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

0 / 4000
Your suggestion