Signature fix

This fixes the issues with signature verification and cleans up the de-armoring code.