AUR AI Reviewer

Review Results

Version #3244 of zramswap · commit ff489b66e20d · status Reviewed

Risk 0/5 · Safe .SRCINFO
Result #7004

Comment

The change is a metadata-only update in .SRCINFO: it switches the package URL from HTTP to HTTPS and corrects the Wikipedia page capitalization. There are no build, install, source, or execution changes, and no new attack surface is introduced. This is a benign integrity improvement rather than a security concern.

@@ -2,7 +2,7 @@ pkgbase = zramswap
 	pkgdesc = Sets up zram-based swap devices on boot
 	pkgver = 7
 	pkgrel = 2
-	url = http://en.wikipedia.org/wiki/ZRam
+	url = https://en.wikipedia.org/wiki/Zram
 	arch = any
 	license = GPL
 	depends = bash
Risk 0/5 · Safe PKGBUILD
Result #7005

Comment

The change is a cosmetic PKGBUILD cleanup only: maintainer metadata updated, Wikipedia URL switched from http to https, arrays reformatted, and the contributor list adjusted. The package still installs the same three source files with the same checksums and the same package() actions, with no new network access, privilege escalation, persistence, or suspicious build-time behavior introduced. No security-relevant issues are evident in this diff.

@@ -1,29 +1,34 @@
-# Maintainer: Radek Podgorny <radek@podgorny.cz>
+# Maintainer: Heptazhou <zhou at 0h7z dot com>
 # Contributor: ifaigios <ifaigios_at_gmail_dot_com>
 # Contributor: Alyssa Hung <deciare@isisiew.org>
 # Contributor: Matt Brennan
 # Contributor: falconindy
 # Contributor: adee
 # Contributor: mystilleef
+# Contributor: Radek Podgorny <radek@podgorny.cz>
 
 pkgname=zramswap
 pkgver=7
 pkgrel=2
 pkgdesc="Sets up zram-based swap devices on boot"
-arch=('any')
-url="http://en.wikipedia.org/wiki/ZRam"
-license=('GPL')
-depends=('bash')
+arch=("any")
+url="https://en.wikipedia.org/wiki/Zram"
+license=("GPL")
+depends=("bash")
 backup=("etc/zramswap.conf")
-source=("zramctrl"
-        "zramswap.conf"
-        "zramswap.service")
-md5sums=('fb633774fb523b7107ca62b2647aec89'
-         '2137bd73c7d87a6ded0011a8f27f478e'
-         'a746969adc521826c14b0796968f3ca6')
+source=(
+	"zramctrl"
+	"zramswap.conf"
+	"zramswap.service"
+)
+md5sums=(
+	"fb633774fb523b7107ca62b2647aec89"
+	"2137bd73c7d87a6ded0011a8f27f478e"
+	"a746969adc521826c14b0796968f3ca6"
+)
 
 package() {
-  install -Dm755 zramctrl $pkgdir/usr/lib/systemd/scripts/zramctrl
-  install -Dm644 zramswap.conf $pkgdir/etc/zramswap.conf
-  install -Dm644 zramswap.service $pkgdir/usr/lib/systemd/system/zramswap.service
+	install -Dm755 zramctrl $pkgdir/usr/lib/systemd/scripts/zramctrl
+	install -Dm644 zramswap.conf $pkgdir/etc/zramswap.conf
+	install -Dm644 zramswap.service $pkgdir/usr/lib/systemd/system/zramswap.service
 }
Risk 0/5 · Safe zramctrl
Result #7006

Comment

The change is a whitespace/formatting-only edit in zramctrl: it adjusts spacing around arithmetic expressions and the procfs redirection, with no functional logic changes, no new commands, no network access, and no privilege/persistence behavior introduced. I see no security impact from this diff.

@@ -19,22 +19,22 @@ start() {
 		test "$Item" != "MemTotal:" && continue
 		# echo "|$Item|$Amount|$Multiplier|"
 		case $Multiplier in
-			kB)	RAM_TOTAL_BYTES=$((Amount * 1024)) ;;
-			mB)	RAM_TOTAL_BYTES=$((Amount * (1024**2) )) ;;
-			gB)	RAM_TOTAL_BYTES=$((Amount * (1024**3) )) ;;
-			*)	RAM_TOTAL_BYTES=$Amount ;;
+			kB) RAM_TOTAL_BYTES=$((Amount * 1024)) ;;
+			mB) RAM_TOTAL_BYTES=$((Amount * (1024 ** 2))) ;;
+			gB) RAM_TOTAL_BYTES=$((Amount * (1024 ** 3))) ;;
+			*) RAM_TOTAL_BYTES=$Amount ;;
 		esac
 		# echo "$RAM_TOTAL_BYTES $RAM_PERCENT"
-	done </proc/meminfo
+	done < /proc/meminfo
 
 	# SIZE=8
 	# Manual size config?
 	if test $SIZE -gt 0; then
 		case "${SIZE_TYPE:-GiB}" in
-			KiB)	ZRAM_SIZE_REQ=$((SIZE * 1024)) ;;
-			MiB)	ZRAM_SIZE_REQ=$((SIZE * (1024**2) )) ;;
-			GiB)	ZRAM_SIZE_REQ=$((SIZE * (1024**3) )) ;;
-			*)		ZRAM_SIZE_REQ=$SIZE ;;
+			KiB) ZRAM_SIZE_REQ=$((SIZE * 1024)) ;;
+			MiB) ZRAM_SIZE_REQ=$((SIZE * (1024 ** 2))) ;;
+			GiB) ZRAM_SIZE_REQ=$((SIZE * (1024 ** 3))) ;;
+			*) ZRAM_SIZE_REQ=$SIZE ;;
 		esac
 		if test $ZRAM_SIZE_REQ -gt $((RAM_TOTAL_BYTES * ZRAM_MAX_PERCENT / 100)); then
 			ZRAM_SIZE=$((RAM_TOTAL_BYTES * ZRAM_MAX_PERCENT / 100))
Risk 0/5 · Safe zramctrl
Result #7007

Comment

The change is a harmless whitespace fix in a shell redirection: `$(</sys/block/zram0/comp_algorithm)` -> `$(< /sys/block/zram0/comp_algorithm)`. It does not alter command execution, data flow, privileges, network access, or packaging behavior. No security impact is apparent from this diff hunk alone.

@@ -52,7 +52,7 @@ start() {
 	modprobe zram
 	if test -n "$ZRAM_COMPRESSION_ALGO"; then
 		# Iterate over available compression algorithms.
-		for AVAILABLE_ALGO in $(</sys/block/zram0/comp_algorithm); do
+		for AVAILABLE_ALGO in $(< /sys/block/zram0/comp_algorithm); do
 			# Remove brackets from active one
 			AVAILABLE_ALGO=${AVAILABLE_ALGO#[}
 			AVAILABLE_ALGO=${AVAILABLE_ALGO%]}
Risk 0/5 · Safe zramctrl
Result #7008

Comment

This change is a pure whitespace/formatting edit in zramctrl: it only changes indentation in stop() and the case pattern spacing. No commands, paths, privileges, downloads, or persistence behavior are altered. The script still only runs swapoff on /dev/zram0 and unloads the zram module, which is expected for zramswap. No security impact identified.

@@ -75,10 +75,10 @@ start() {
 }
 
 stop() {
-  swapoff /dev/zram0
-  rmmod zram
+	swapoff /dev/zram0
+	rmmod zram
 }
 
 case $1 in
-  start|stop) "$1" ;;
-esac
\ No newline at end of file
+	start | stop) "$1" ;;
+esac
Risk 0/5 · Safe zramswap.service
Result #7009

Comment

The change is a no-op formatting update to zramswap.service: it only adds a trailing newline and does not alter any unit directives, execution context, dependencies, or install behavior. No security-relevant behavior changes are introduced in this diff hunk.

@@ -9,4 +9,4 @@ ExecStop=/usr/lib/systemd/scripts/zramctrl stop
 RemainAfterExit=yes
 
 [Install]
-WantedBy=multi-user.target
\ No newline at end of file
+WantedBy=multi-user.target