How does ZRTP setup the SRTP keys?
In principle ZRTP uses three phases to negotiate and setup the SRTP master keys and to switch to SRTP mode. • Discovery phase – detecting if the peers supports ZRTP • Key agreement phase – exchanging the key material • Secure phase – confirm the cryptographic data and switch to SRTP mode During the first phase both ZRTP peers exchange information about the encryption, key agreement, and authentications modes they support. Currently the ZRTP specification defines the following encryption modes: • AES Counter Mode with 128 bit key length • AES Counter Mode with 256 bit key length To exchange the key material ZRTP uses the Diffie-Helman key agreement algorithm. For this algorithm ZRTP can use different modes: • 3072 bit Diffie-Helman values • Diffie-Helman based on elliptic curves (no commonly used yet) The SRTP authentication modes can be set to either 32 bit authentication or 80 bit authentication. During the next phase the peers generate their Diffie-Helman values and exchange the publ