Skip to content

Instantly share code, notes, and snippets.

@rastreador
Created January 2, 2022 19:51
Show Gist options
  • Save rastreador/66b9fdfd1c653a04b745be3ae8114e52 to your computer and use it in GitHub Desktop.
Save rastreador/66b9fdfd1c653a04b745be3ae8114e52 to your computer and use it in GitHub Desktop.
#!/bin/bash
echo "SCRIPT DE DESCIFRADO"
echo "-----------------"
echo ""
echo -n "Clave de encriptación: "
read -s CLAVE
echo ""
echo -n "Texto a descifrar: "
read -s TEXTO
echo ""
echo ""
echo "El texto descifrado es:"
SALIDA=$(echo $TEXTO | openssl aes-256-cbc -d -pbkdf2 -a -A -salt -pass pass:$CLAVE)
echo $SALIDA
echo ""
unset CLAVE
unset TEXTO
read -n 1 -s -r -p "Pulsa cualquier tecla para terminar y borrar la pantalla"
clear
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment