[VOIPSEC] RTP or SRTP inside UDP - how understand?
Lee Dilkie
lee_dilkie at mitel.com
Mon Mar 27 16:50:07 CST 2006
Simon Horne wrote:
> AFAIK AES has a fixed block size of 128 bits or 16 bytes, A RTP payload may
> be any length (depending on the codec) but must be padded out to a multiple
> of 16kb for the cipher. So I have a payload of 28 bytes, this has to be
> padded out to 32 bytes (2x16) to put into the cipher which results in a 32
> byte encrypted block. There is a 4 byte variance.
> Reference
> http://en.wikipedia.org/wiki/Advanced_Encryption_Standard#Description_of_the_cipher
>
> Have I missed something?
>
> Simon
>
>
Yes. Counter Mode (CM) is used for SRTP. In counter mode the cipher is
not used to encrypt the payload directly, instead it's used to encrypt a
block of data consisting of incrementing counter values
(n,n+1,n+2,n+3...). This list of encrypted counters is then XORed with
the original payload, and the size doesn't change.
-lee
More information about the Voipsec
mailing list