This error occurs when the backup we have in iTunes is encrypted with a key. This is an option that iTunes offers to have our backups stored more securely in our computer. The solution is in the same iTunes uncheck the Encrypt backup iPhone security option, make the back again, restore the new backup and retry the jailbreak.
This is the option in iTunes: