Fix public key fetching