Which algorithm would be ideal for ephermal key generation followed by DH key exchange?
Using ECDHE as an example, the steps are like this,


The client sends supported named curved list.
The server chooses a curve and generate key-pair, and sent back curve type and public key.
The client uses the server curve type to generate key-pair, and send back curve type and public key.


Now, both client and server can generate same secret(i.e. pre-master secret in SSL)