Enable End-to-End Encrypted Video Frames.

This change integrates the FrameDecryptorInterface and the FrameEncryptorInterface into
the video send and receive path. If a FrameEncryptorInterface is set on an outgoing video RTPSender
then each outgoing video frame will first pass through the provided FrameEncryptor which
will have a chance to modify the payload contents for the purposes of encryption. In addition to
this the new GenericFrameDescriptor will be added as additional data.

If a FrameDecryptorInterface is set on an incoming video RtpReceiver then each incoming
video payload will first pass through the provided FrameDecryptor which have a chance to
modify the payload contents for the purpose of decryption.

Bug: webrtc:9795
Change-Id: I9f743ce0cb63df0cf070f6144be7ada078b4e5d2
Reviewed-on: https://webrtc-review.googlesource.com/c/103920
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Commit-Queue: Benjamin Wright <benwright@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25258}
This commit is contained in:
Benjamin Wright
2018-10-17 17:27:25 -07:00
committed by Commit Bot
parent 6714bf9f18
commit 192eeec14d
26 changed files with 343 additions and 87 deletions

View File

@ -60,11 +60,21 @@ class VCMEncodedFrame : protected EncodedImage {
* Get pointer to frame buffer
*/
const uint8_t* Buffer() const { return _buffer; }
/**
* Get pointer to frame buffer that can be mutated.
*/
uint8_t* MutableBuffer() { return _buffer; }
/**
* Get frame length
*/
size_t Length() const { return _length; }
/**
* Set frame length
*/
void SetLength(size_t length) {
RTC_DCHECK(length <= _size);
_length = length;
}
/**
* Frame RTP timestamp (90kHz)
*/