From 379fac795fb46071b4408767ca3a1eed7637ba30 Mon Sep 17 00:00:00 2001 From: smdigey Date: Tue, 5 Jan 2021 15:35:44 +1100 Subject: [PATCH] updated USB Creator test to use integer comparison --- linPEAS/linpeas.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/linPEAS/linpeas.sh b/linPEAS/linpeas.sh index f6cd0f8..77785e8 100755 --- a/linPEAS/linpeas.sh +++ b/linPEAS/linpeas.sh @@ -980,8 +980,9 @@ if [ "`echo $CHECKS | grep SysI`" ]; then fi if [ -n "$pc_version" ]; then pc_length=${#pc_version} - pc_numeric=$(echo "$pc_version" | cut -c1-4) - if [[ $pc_length -eq 4 && $pc_numeric -lt 0.21 ]]; then + pc_major=$(echo "$pc_version" | cut -d. -f1) + pc_minor=$(echo "$pc_version" | cut -d. -f2) + if [[ $pc_length -eq 4 && $pc_major -eq 0 && $pc_minor -lt 21 ]]; then echo "Vulnerable!!" | sed -E "s,.*,${C}[1;31m&${C}[0m," fi fi