csky-debugserver-bin

maintainer taotieren · 0 votes · scanned 2026-08-03 00:08:14.047287
MEDIUM
View on AUR ↗
Why flagged The PKGBUILD downloads a self-extracting shell installer from Alibaba Cloud OSS (occ-oss-prod.oss-cn-hangzhou.aliyuncs.com), which is the official T-Head/XuanTie distribution channel for RISC-V tooling from Alibaba's chip division. The technique of using `tail -n +285` to strip the shell header and extract an embedded tarball is a standard self-extracting installer pattern. The host is not a random personal bucket — it is the official OCC (Open Chip Community) production OSS bucket used by T-Head Semiconductor for all their toolchain releases, consistent with the upstream URL pointing to xrvm.cn. SHA256 checksums are provided and pinned. However, the binary payload is a prebuilt closed-source ELF debugserver that cannot be independently verified against source code, and the distribution host, while official for this vendor, is not a well-known tier-1 mirror. This is a legitimate medium-risk supply-chain concern (prebuilt binary from a vendor-controlled but non-mainstream host) rather than a clear attack, and the sha256 pinning mitigates substitution risk at the point of download.

Triggered rules

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:29 "${pkgname}-${pkgver}.sh.tar.gz::https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource//1732244327178/XuanTie-DebugServer-linux-x86_64-V5.18.3-20241119.sh.tar.gz"
MEDIUM AI review llm_review

An AI model (anthropic/claude-4.6-sonnet-20260217) reviewed this and agrees it is MEDIUM (confidence 72%): The PKGBUILD downloads a self-extracting shell installer from Alibaba Cloud OSS (occ-oss-prod.oss-cn-hangzhou.aliyuncs.com), which is the official T-Head/XuanTie distribution channel for RISC-V tooling from Alibaba's chip division. The technique of using `tail -n +285` to strip the shell header and extract an embedded tarball is a standard self-extracting installer pattern. The host is not a random personal bucket — it is the official OCC (Open Chip Community) production OSS bucket used by T-Head Semiconductor for all their toolchain releases, consistent with the upstream URL pointing to xrvm.cn. SHA256 checksums are provided and pinned. However, the binary payload is a prebuilt closed-source ELF debugserver that cannot be independently verified against source code, and the distribution host, while official for this vendor, is not a well-known tier-1 mirror. This is a legitimate medium-risk supply-chain concern (prebuilt binary from a vendor-controlled but non-mainstream host) rather than a clear attack, and the sha256 pinning mitigates substitution risk at the point of download.

PKGBUILD

1 offending line(s) highlighted
1# Maintainer: taotieren <admin@taotieren.com>
2
3pkgname=csky-debugserver-bin
4pkgver=5.18.3
5pkgrel=2
6epoch=
7pkgdesc="C-Sky Debugger Server"
8arch=('x86_64')
9url="https://www.xrvm.cn/community/download?id=4380347564587814912"
10license=('BSD')
11groups=()
12depends=(
13 sh
14 gcc-libs
15 glibc
16 libusb
17)
18makedepends=(libarchive)
19checkdepends=()
20optdepends=()
21provides=()
22conflicts=()
23replaces=()
24backup=()
25options=(!strip !debug)
26install=
27changelog=
28source=(
29 "${pkgname}-${pkgver}.sh.tar.gz::https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource//1732244327178/XuanTie-DebugServer-linux-x86_64-V5.18.3-20241119.sh.tar.gz"
30 "DebugServer User Guide_v5.18.pdf::https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource//1732244783846/Debugger+Server+User+Guide%28ZH-CN%29_20241122.pdf"
31)
32noextract=()
33sha256sums=('7f4de8c22050a8a591677b4cb5d783b47e53c213fd5fd5c2d93952704c578bfc'
34 'e6161264c76f5028b55e34d48cbcaeb21829d73dbe94548cdb7b55f1d87de4b9')
35#validpgpkeys=()
36
37package() {
38 tail -n +285 "${srcdir}"/*${pkgver}*.sh >"${srcdir}/${pkgname}-${pkgver}.tar.gz"
39
40 install -dm0755 "${pkgdir}/opt/t-head/${pkgname%-bin}"
41
42 bsdtar -xf "${srcdir}/${pkgname}-${pkgver}.tar.gz" --no-same-owner --no-same-permissions --strip-components=1 -C "${pkgdir}/opt/t-head/${pkgname%-bin}"
43
44 install -Dm0644 "${srcdir}"/*.pdf -t "${pkgdir}/opt/t-head/${pkgname%-bin}"
45
46 # install -Dm0644 /dev/stdin "${pkgdir}/etc/profile.d/${pkgname%-bin}.csh" <<EOF
47 # setenv PATH "${PATH}:/opt/t-head/${pkgname%-bin}"
48 # EOF
49
50 install -Dm0755 /dev/stdin "${pkgdir}/usr/bin/${pkgname%-bin}" <<EOF
51#!/bin/env bash
52export PATH=/opt/t-head/${pkgname%-bin}:\$PATH
53cd /opt/t-head/${pkgname%-bin}
54exec DebugServerConsole.elf "\$@"
55EOF
56}
57

Scan history

Scanned at (UTC)SeverityRules
2026-08-03 00:08:14 MEDIUM 2
2026-08-02 00:16:08 MEDIUM 2
2026-08-01 00:11:18 MEDIUM 2
2026-07-31 00:14:10 MEDIUM 2
2026-07-30 00:17:23 MEDIUM 2
2026-07-29 00:25:53 MEDIUM 2
2026-07-28 00:07:28 MEDIUM 2
2026-07-27 00:24:32 MEDIUM 2
2026-07-26 00:07:32 MEDIUM 2
2026-07-25 00:13:44 MEDIUM 2
2026-07-24 00:02:28 MEDIUM 2
2026-07-23 00:14:47 MEDIUM 2
2026-07-22 00:29:32 MEDIUM 2
2026-07-21 00:24:15 MEDIUM 2
2026-07-20 00:19:49 MEDIUM 2
2026-07-19 00:17:08 MEDIUM 2
2026-07-18 00:14:48 MEDIUM 2
2026-07-17 00:06:16 MEDIUM 2
2026-07-16 00:05:41 MEDIUM 2
2026-07-15 00:09:25 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