Skip to content

Commit

Permalink
[+] Checks against the latest baseline
Browse files Browse the repository at this point in the history
 Changes to be committed:
	modified:   src/www/httpd/cgi-bin/fw_upgrade.sh
  • Loading branch information
alienatedsec committed Feb 11, 2024
1 parent 8d13a5c commit 23a96a5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/www/httpd/cgi-bin/fw_upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,12 @@ elif [ "$VAL" == "upgrade" ] ; then
printf "No new firmware available."
exit
fi

elif [ "$BASELINE_VERSION" != "0.4.1" ]; then
printf "Content-type: text/html\r\n\r\n"
printf "Wrong baseline version"
exit
fi

/usr/bin/wget https://github.com/alienatedsec/yi-hack-v5/releases/download/$LATEST_FW/${MODEL_SUFFIX}_${LATEST_FW}.tgz

if [ ! -f ${MODEL_SUFFIX}_${LATEST_FW}.tgz ]; then
Expand Down Expand Up @@ -133,7 +138,7 @@ elif [ "$VAL" == "preupgrade" ] ; then
printf "Content-type: text/html\r\n\r\n"
printf "No new firmware available."
exit
elif [ "$BASELINE_VERSION" != "0.3.8" ]; then
elif [ "$BASELINE_VERSION" != "0.4.1" ]; then
printf "Content-type: text/html\r\n\r\n"
printf "Wrong baseline version"
exit
Expand Down

0 comments on commit 23a96a5

Please sign in to comment.