google-calender-widget-bin

MEDIUM
maintainer zxp19821005 0 votes scanned 2026-09-21 03:33:45.762125
View on AUR
Why flagged

The package extracts and modifies code from a prebuilt AppImage downloaded from GitHub Releases, which is an unverifiable binary executable; while the source host is plausible, the lack of transparency in the AppImage's contents creates a supply-chain risk.

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.

Medium AI review of an ambiguous pattern llm_review

The static rules found a suspicious pattern they could not resolve, so an AI model (qwen/qwen3-235b-a22b-2507) reviewed it and judged it MEDIUM (confidence 95%): The package extracts and modifies code from a prebuilt AppImage downloaded from GitHub Releases, which is an unverifiable binary executable; while the source host is plausible, the lack of transparency in the AppImage's contents creates a supply-chain risk.

PKGBUILD

1# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
2pkgname=google-calender-widget-bin
3pkgver=1.1.7
4_electronversion=38
5pkgrel=1
6pkgdesc="An unofficial google calendar desktop widget."
7arch=('x86_64')
8url="https://github.com/p32929/google-calender-widget"
9license=('MIT')
10provides=("${pkgname%-bin}=${pkgver}")
11conflicts=("${pkgname%-bin}")
12depends=(
13 "electron${_electronversion}"
14 'asar'
15)
16source=(
17 "${pkgname%-bin}-${pkgver}-x86_64.AppImage::${url}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}.AppImage"
18 "LICENSE-${pkgver}::https://raw.githubusercontent.com/p32929/google-calender-widget/v${pkgver}/LICENSE"
19 "${pkgname%-bin}.sh"
20)
21sha256sums=('4f01997550a85591ae385902d163da1cc811838fb271c243cd5bda3831f510a5'
22 '5d1bcace68c53fffb3c60e8bd1d065a29c5af4fc64c8fdb079b7b2bdce796f09'
23 'a774c2f54fbbeeaac3cefc0f7250796d30c86d27f0fd40b7eaf9c0fdb021623d')
24_get_app_dir() {
25 find "${srcdir}" -type d -name "node_modules" -prune -o -type f -name "resources.pak" -print0 | xargs -0 dirname | head -n 1
26}
27_check_electron_version() {
28 echo "Verifying Electron version..."
29 local _main_exe=$(find "$(_get_app_dir)" -maxdepth 1 -type f -executable -printf '%s %p\n' | sort -nr | head -1 | cut -d' ' -f2-)
30 [[ -z "${_main_exe}" ]] && echo -e "\033[1;33mNote: Could not find Electron binary.\033[0m" && return
31 local _elec_ver=$(strings "${_main_exe}" | grep -oP 'Electron/\K[0-9]+' | head -1)
32 [[ -z "${_elec_ver}" ]] && echo -e "\033[1;33mNote: Could not determine Electron version.\033[0m" && return
33 [[ "${_elec_ver}" != "${_electronversion}" ]] &&
34 echo -e "\033[1;31mWarning: Electron version mismatch! Detected: ${_elec_ver}, Expected: ${_electronversion}\033[0m" ||
35 echo -e "Electron version verified: \033[1;31m${_elec_ver}\033[0m"
36}
37prepare() {
38 sed -i -e "
39 s/@electronversion@/${_electronversion}/g
40 s/@appname@/${pkgname%-bin}/g
41 s/@runname@/app.asar/g
42 s/@cfgdirname@/${pkgname%-bin}/g
43 " "${srcdir}/${pkgname%-bin}.sh"
44 if [ ! -x "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage" ];then
45 chmod +x "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage"
46 fi
47 if [ -d "${srcdir}/squashfs-root" ];then
48 rm -rf "${srcdir}/squashfs-root"
49 fi
50 "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage" --appimage-extract > /dev/null
51 _check_electron_version
52 local _app_dir=$(_get_app_dir)
53 sed -i "s/AppRun --no-sandbox/${pkgname%-bin}/g" "${_app_dir}/${pkgname%-bin}.desktop"
54 asar e "${_app_dir}/resources/app.asar" "${srcdir}/app.asar.unpacked"
55 sed -i -e "
56 s/process.resourcesPath/\'\/usr\/lib\/${pkgname%-bin}\'/g
57 s/icon.ico/icon.png/g
58 " "${srcdir}/app.asar.unpacked/index.js"
59 asar p "${srcdir}/app.asar.unpacked" "${_app_dir}/resources/app.asar"
60}
61package() {
62 install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}"
63 install -Dm755 -d "${pkgdir}/usr/lib/${pkgname%-bin}"
64 local _app_dir=$(_get_app_dir)
65 cp -a "${_app_dir}/resources/." "${pkgdir}/usr/lib/${pkgname%-bin}/"
66 find "${srcdir}" -type f \( -name "*.png" -o -name "*.svg" \) -path "*share/icons/*" | while read -r _i; do
67 _extension="${_i##*.}"
68 _icon_path="${_i#*share/icons/}"
69 _target_dir="/usr/share/icons/$(dirname "${_icon_path}")"
70 install -Dm644 "${_i}" "${pkgdir}${_target_dir}/${pkgname%-bin}.${_extension}"
71 done
72 install -Dm644 "${_app_dir}/${pkgname%-bin}.desktop" -t "${pkgdir}/usr/share/applications"
73 install -Dm644 "${srcdir}/LICENSE-${pkgver}" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
74}

Scan history

Scanned at (UTC)SeverityRules
2026-09-21 03:33:45 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