added decode_without_secret functionality