enable AES-256 with all versions of libSRTP 1.5.x #1
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
libSRTP API of the cipher type in is not fully symmetric:
AES_256_GCM
AES_256_ICM
, you have to go forAES_ICM
With
AES_256_ICM
the following call chainsrtp_create(.)
→
srtp_add_stream(.)
→ →
srtp_stream_alloc(.)
→ → → →
crypto_kernel_alloc_cipher(.)
returnserr_status_fail
= 1→ → → → →
crypto_kernel_get_cipher_type(.)
returnsNULL
= 0because 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 symbolAES_ICM
for all ICM based crypto suites,AES_128_GCM
, andAES_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.