Something like this should work on linux or mac. On windows you'll probably need to use wsl or convert it to powershell if you can't install the dependencies natively. The script requires bash, unrar, and find.
#!/usr/bin/env bash
while read -r rarfile; do
while read -r password; do
if unrar t -p"$password" "$rarfile" >/dev/null 2>&1; then
echo "$rarfile $password"
break
fi
echo "$rarfile password not found"
done < /path/to/passwords.list
done < <(find /path/to/rars -type f -iname '*.rar')
LibreTube is probably what you want. There's no g**gle sign-in in third party yt clients though (vanced only has it bc it patches the official client) so you'll need to export and import your subscriptions https://github.com/libre-tube/LibreTube