update for ECDH