AUR AI Reviewer

Review Results

Version #3198 of wechat-universal-bwrap · commit 00c746389b97 · status Reviewed

Risk 0/5 · Safe .SRCINFO
Result #6771

Comment

The only change in this .SRCINFO hunk is a pkgrel bump from 2 to 3. No sources, checksums, build steps, install scripts, or package metadata affecting trust boundaries were modified. On its face this is a no-op rebuild metadata change with no security impact.

@@ -1,7 +1,7 @@
 pkgbase = wechat-universal-bwrap
 	pkgdesc = WeChat (Universal) with bwrap sandbox
 	pkgver = 4.1.13.26
-	pkgrel = 2
+	pkgrel = 3
 	url = https://linux.weixin.qq.com/
 	install = wechat-universal.install
 	arch = x86_64
Risk 0/5 · Safe .SRCINFO
Result #6772

Comment

The .SRCINFO change is low risk. It adds a new desktop entry source and corresponding checksum, and bumps pkgrel to match the PKGBUILD. I checked the added desktop file and it is a static launcher alias for the existing WeChat built-in browser entry, pointing to an existing script under /usr/lib/wechat-universal with no network, privilege, or persistence behavior. No suspicious sources, build-time downloads, or install-script changes are introduced by this diff.

@@ -42,12 +42,14 @@ pkgbase = wechat-universal-bwrap
 	options = emptydirs
 	source = wechat-universal.sh
 	source = wechat-universal.desktop
+	source = wechat-universal-alias-browser.desktop
 	source = wechat-universal-alias-icon.desktop
 	source = libuosdevicea.c
 	source = libuosdevicea.Makefile
 	source = wechat-license
-	sha256sums = 4c0b62a2d5bcaab2ff23b759801a4c22c4396fdbc95a29e6496987a4eae4860e
+	sha256sums = fffa82838ce86288651862b3882a810eea079c902cb85f4a0529b3539beb35c9
 	sha256sums = 0563472cf2c74710d1fe999d397155f560d3ed817e04fd9c35077ccb648e1880
+	sha256sums = f4b744db5543e31e2be823129693e7b918be191cad5616c1054dd9c1e95cd734
 	sha256sums = 93f5363c956b7d13e0408e14fe97abe936916da8d4adf414e74ad334e308f37c
 	sha256sums = fc3ce9eb8dee3ee149233ebdb844d3733b2b2a8664422d068cf39b7fb08138f8
 	sha256sums = f05f6f907898740dab9833c1762e56dbc521db3c612dd86d2e2cd4b81eb257bf
Risk 0/5 · Safe PKGBUILD
Result #6773

Comment

This change only bumps pkgrel from 2 to 3 in PKGBUILD and does not alter sources, build steps, dependencies, install scripts, or packaging behavior. No security-relevant logic changed in the reviewed hunk.

@@ -5,7 +5,7 @@
 _pkgname=wechat-universal
 pkgname=${_pkgname}-bwrap
 pkgver=4.1.13.26
-pkgrel=2
+pkgrel=3
 pkgdesc="WeChat (Universal) with bwrap sandbox"
 arch=('x86_64' 'aarch64' 'loong64')
 url='https://linux.weixin.qq.com/'
Risk 0/5 · Safe PKGBUILD
Result #6774

Comment

The change only adds a new desktop entry source and installs it when WECHAT_ALIAS_ICON=yes. The new file is a simple launcher alias pointing to an existing script under /usr/lib/wechat-universal, with NoDisplay=true and no privilege escalation, network access, or persistence mechanism. The PKGBUILD change itself does not introduce unsafe build-time behavior; it only updates checksums and conditionally creates a symlink already consistent with the package's existing layout. Risk is low.

@@ -52,6 +52,7 @@ _lib_uos='libuosdevicea'
 source=(
     "${_pkgname}.sh"
     "${_pkgname}.desktop"
+    "${_pkgname}-alias-browser.desktop"
     "${_pkgname}-alias-icon.desktop"
     "${_lib_uos}".{c,Makefile}
     'wechat-license'
Risk 1/5 · Low PKGBUILD
Result #6775

Comment

The change is low risk. It adds a new desktop entry and, when WECHAT_ALIAS_ICON=yes, installs an extra alias desktop file plus a symlink to an existing script; otherwise it removes the unused wechatappex applet from common.sh via sed. I do not see network access, privilege escalation, or installation outside pkgdir. The only security-relevant concern is that the new sed-based removal is brittle and could accidentally overmatch if upstream script structure changes, but in this diff it targets a specific function and menu entry and does not introduce an obvious backdoor or persistence mechanism.

@@ -68,8 +69,9 @@ source_loong64=("${_deb_prefix}loong64.deb::${_deb_url_common}LoongArch.deb")
 noextract=("${_deb_prefix}"{x86_64,aarch64,loong64}.deb )
 
 sha256sums=(
-    '4c0b62a2d5bcaab2ff23b759801a4c22c4396fdbc95a29e6496987a4eae4860e'
+    'fffa82838ce86288651862b3882a810eea079c902cb85f4a0529b3539beb35c9'
     '0563472cf2c74710d1fe999d397155f560d3ed817e04fd9c35077ccb648e1880'
+    'f4b744db5543e31e2be823129693e7b918be191cad5616c1054dd9c1e95cd734'
     '93f5363c956b7d13e0408e14fe97abe936916da8d4adf414e74ad334e308f37c'
     'fc3ce9eb8dee3ee149233ebdb844d3733b2b2a8664422d068cf39b7fb08138f8'
     'f05f6f907898740dab9833c1762e56dbc521db3c612dd86d2e2cd4b81eb257bf'
Risk 1/5 · Low PKGBUILD
Result #6776

Comment

The change adds an extra desktop entry and a symlink for `wechatappex.sh` when `WECHAT_ALIAS_ICON=yes`, or otherwise edits `common.sh` with `sed` to remove the `wechatappex` applet. I do not see evidence of network access, privilege escalation, or writes outside `$pkgdir`. The new desktop file is sourced via the PKGBUILD checksum list, so integrity is still pinned. The main risk is limited to packaging behavior changes: installing an additional launcher/alias that may affect how WeChat resolves its built-in browser/official-account app, and a brittle in-place `sed` transformation that could accidentally remove more than intended if upstream script formatting changes. This is a low-severity packaging change, not a clear security issue.

@@ -159,6 +161,15 @@ package() {
         # Plasma resolves WeChat's hardcoded desktop-entry=wechat to get the app icon.
         # This however conflicts with non-wrap version, so don't install the icon by default
         install -Dm644 "${_pkgname}-alias-icon.desktop" "${pkgdir}/usr/share/applications/${_upstream_name}.desktop"
+        # Addtional "fixup" for tray / window icon for built-in browser and official accounts
+        install -Dm644 "${_pkgname}-alias-browser.desktop" "${pkgdir}/usr/share/applications/com.tencent.wechatappex.desktop"
+        ln -s common.sh "${_wechat_root}"/wechatappex.sh
+    else # Strip out the wechatappex applet that we never need
+        sed '
+            /^applet_wechatappex() {$/,/^$/d
+            /^'"    'wechatappex.sh'|'wechatappex')"'$/,/;;/d
+            s/, wechatappex.sh (alias wechatappex)//
+        ' -i "${_wechat_root}"/common.sh
     fi
     echo 'Installing license...'
     install -Dm644 {,"${pkgdir}/usr/share/licenses/${_pkgname}/"}wechat-license
Risk 0/5 · Safe wechat-universal-alias-browser.desktop
Result #6777

Comment

The new desktop entry is a simple alias launcher for the existing WeChat wrapper script. It does not introduce network access, privilege escalation, persistence, or other suspicious behavior by itself. The only notable aspect is that it points to an executable script under /usr/lib, but that target is outside the reviewed diff and appears to be part of the package’s normal launch path. No security red flags are present in this change alone.

@@ -0,0 +1,7 @@
+[Desktop Entry]
+Type=Application
+Name=WeChat Built-in Browser
+Exec=/usr/lib/wechat-universal/wechatappex.sh %u
+Icon=wechat-universal
+NoDisplay=true
+X-KDE-AliasFor=wechat-universal
Risk 0/5 · Safe wechat-universal.sh
Result #6778

Comment

The change is low risk. It only narrows two existing read-only bind mounts for Fcitx Wayland candidate-window assets behind an explicit `WECHAT_IME_WORKAROUND=fcitx` check, while still binding the Wayland socket itself when present. There is no new network access, privilege escalation, persistence, or execution path introduced, and the modification reduces the amount of host configuration exposed to the container by default. I did not find any security-relevant regression in this hunk.

@@ -236,13 +236,18 @@ try_start() {
         --ro-bind "${XDG_RUNTIME_DIR}/pulse"{,}
     )
 
+    # Wayland fixups
     if [[ -S "${WAYLAND_SOCKET}" ]]; then
         BWRAP_ARGS+=(
             --ro-bind-try "${WAYLAND_SOCKET}"{,}
-            # Fcitx Qt draws its Wayland candidate window in the client process.
-            --ro-bind-try "${XDG_CONFIG_HOME:-${HOME}/.config}/fcitx5/conf/classicui.conf"{,}
-            --ro-bind-try "${XDG_DATA_HOME:-${HOME}/.local/share}/fcitx5/themes"{,}
         )
+        # Fcitx Qt draws its Wayland candidate window in the client process.
+        if [[ "${WECHAT_IME_WORKAROUND}" == 'fcitx' ]]; then
+            BWRAP_ARGS+=(
+                --ro-bind-try "${XDG_CONFIG_HOME:-${HOME}/.config}/fcitx5/conf/classicui.conf"{,}
+                --ro-bind-try "${XDG_DATA_HOME:-${HOME}/.local/share}/fcitx5/themes"{,}
+            )
+        fi
     fi
 
     case "${WECHAT_MULTIPLE_INSTANCE}" in
Risk 0/5 · Safe wechat-universal.sh
Result #6779

Comment

The change only adds a dummy shell function `applet_wechatappex()` that prints a message and returns failure. It does not introduce network access, privilege escalation, persistence, file writes, or other security-sensitive behavior. The function is not invoked by the shown diff and appears to be a harmless placeholder for an applet name mismatch or unsupported entrypoint.

@@ -472,6 +477,11 @@ applet_dde() {
     return 1
 }
 
+applet_wechatappex() {
+    echo "Dummy WeChatAppEx: you should not see this"
+    return 1
+}
+
 applet="${0##*/}"
 case "${applet}" in
     'stop.sh'|'stop')
Risk 0/5 · Safe wechat-universal.sh
Result #6780

Comment

The change is low risk. It only adds a new no-op applet handler (`wechatappex`) that prints a dummy message and exits nonzero, and it narrows the Wayland/Fcitx bind-mount workaround so the Fcitx config/theme paths are only exposed when `WECHAT_IME_WORKAROUND=fcitx`. That reduces filesystem exposure rather than increasing it. I do not see any new network access, privilege escalation, persistence, or execution of untrusted code in this diff.

@@ -486,8 +496,11 @@ case "${applet}" in
     'pdfjsfix.sh'|'pdfjsfix')
         applet_pdfjsfix "$@"
         ;;
+    'wechatappex.sh'|'wechatappex')
+        applet_wechatappex "$@"
+        ;;
     *)
-        echo "Unknown applet '${applet}', allowed: start.sh (alias start, wechat-universal, wechat-universal.sh), stop.sh (alias stop), pdfjsfix.sh (alias pdfjsfix)"
+        echo "Unknown applet '${applet}', allowed: start.sh (alias start, wechat-universal, wechat-universal.sh), stop.sh (alias stop), pdfjsfix.sh (alias pdfjsfix), wechatappex.sh (alias wechatappex)"
         false
         ;;
 esac