Skip to content

enable AES-256 with all versions of libSRTP 1.5.x#1

Open
traud wants to merge 1 commit into
jfigus:masterfrom
traud:avoid_bad_parameter
Open

enable AES-256 with all versions of libSRTP 1.5.x#1
traud wants to merge 1 commit into
jfigus:masterfrom
traud:avoid_bad_parameter

Conversation

@traud
Copy link
Copy Markdown

@traud traud commented Jun 16, 2016

libSRTP API of the cipher type in is not fully symmetric:

  • for AES-GCM, you have to specify the bit length as well, like AES_256_GCM
  • for AES-ICM, instead of AES_256_ICM, you have to go for AES_ICM

With AES_256_ICM the following call chain
srtp_create(.)
srtp_add_stream(.)
→ → srtp_stream_alloc(.)
→ → → → crypto_kernel_alloc_cipher(.) returns err_status_fail = 1
→ → → → → crypto_kernel_get_cipher_type(.) returns NULL = 0
because this cipher type is not registered. AES_ICM as value works, because such a cipher type is registered. That software bug was fixed with cisco/libsrtp@b8cb577. However, that change was not backported to the libSRTP 1.5.x branch, yet. Even then, libSRTP 1.5.0 till 1.5.4 keep that software bug. If you use the symbol AES_ICM for all ICM based crypto suites, AES_128_GCM, and AES_256_GCM, you are compatible with all versions of libSRTP 1.5.x.

Here in this repository, this example is used as a guide – a role model – for libSRTP users. Therefore, please, consider this change for inclusion to avoid non-working downstream projects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant