Refactor key derivation code to be more explicit and testable
Maintainers usually reply within 2 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Refactor
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- c
- Domain
- cryptography, networking
Research direction
Start by reading srtp_stream_init_keys and the related RTP/RTCP key-derivation paths. Identify applicable RFC test vectors and use them to check the function's output; the issue does not name specific test files. Done means key and salt are passed separately, input lengths are explicit, cipher compatibility is checked, and the result can be tested against those vectors.
Written by the indexing model from the issue text.
Description
The function srtp_stream_init_keys has been the cause of several bugs, the latest being #763 / #765 . The code there uses heuristics to determine key lengths but there should be no need as this should be explicit for each cipher type.
Input key and salt length should be passed in to prevent reading out of bounds.
Key and Salt should be passed in separately.
RTCP & RTP share the kdf even though there is no check they are the same cipher.
The result of this function should be testable as there exists test vectors in a lot of RFC's.
Any public API changes should be done before 3.0 .
- Dominant language
- C
- Stars
- 1.4k
- Forks
- 523
- Avg merge
- 3d 23h
- Merged PRs (30d)
- 14
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from cisco/libsrtp
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
cisco/libsrtp#816 · 4 comments ·
Maintainers usually reply within 2 days
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
cisco/libsrtp#767 · 1 comment ·
Maintainers usually reply within 2 days
-
Difficulty 3/5 1-2 days Newbie friendliness 30/100
cisco/libsrtp#761 · 1 comment ·
Maintainers usually reply within 2 days
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
cisco/libsrtp#721 · 19 comments ·
Maintainers usually reply within 2 days
-
Review public APIOpen
Difficulty 5/5 Over a week Newbie friendliness 25/100
Maintainers usually reply within 2 days
Similar issues
-
ecs_ptr_from_json does not free the buffer of a string longer than 256 bytes on two error pathsOpen
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
SanderMertens/flecs#2444 ·
Maintainers usually reply within 1 day
-
Status: Opened
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
espressif/esp-eth-drivers#201 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 74/100
libsdl-org/SDL#16788 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
cisco/ChezScheme#1110 ·
Maintainers usually reply within 1 day