updated signature decryption algorithm