deserialize public key before use