Skip to content

Tags: icn-team/srtp

Tags

v2.0.10

Toggle v2.0.10's commit message
Use speedy XOR from pion/transport

Now that we have a speedy version of xorBytes in pion/transport,
we might as well use it.  Benchmarks indicate an improvement
of 10% to 20% in CTR encryption speed for large blocks, depending
on the architecture.

Also remove TestXorBytesBuffer, which is no longer relevant.

v2.0.9

Toggle v2.0.9's commit message
Fix SRTCP packet length check

Packet length check of DecryptRTCP was wrong on AEAD profiles.

v2.0.8

Toggle v2.0.8's commit message
Avoid buffer allocation in Write

Use a sync.Pool for buffers used by (*SessionRTP).Write
and friends.  The pool is global, so its cost can be
amortised across multiple sessions.

v2.0.7

Toggle v2.0.7's commit message
Use MarshalTo in GCM encryptRTP

Use MarshalTo to place the header directly in the destination
buffer.

v2.0.6

Toggle v2.0.6's commit message
Optimise away calls to cipher.NewCTR

This avoids the allocation of a 512-byte buffer on each packet,
which leads to a 30% to 50% speedup in the SRTP benchmaks.

```
name                        old time/op    new time/op     delta
EncryptRTP-8                  1.58µs ± 8%     1.06µs ± 2%   -33.13%
EncryptRTPInPlace-8           1.54µs ± 3%     1.00µs ± 1%   -34.82%
DecryptRTP-8                  1.44µs ± 6%     0.67µs ± 2%   -53.80%
Write-8                       1.65µs ±10%     1.08µs ± 1%   -34.60%
WriteRTP-8                    1.52µs ± 2%     1.01µs ± 3%   -33.75%

name                        old speed      new speed       delta
EncryptRTP-8                71.1MB/s ± 8%  106.1MB/s ± 2%   +49.24%
EncryptRTPInPlace-8         72.9MB/s ± 3%  111.7MB/s ± 1%   +53.26%
DecryptRTP-8                19.4MB/s ± 6%   42.0MB/s ± 2%  +116.24%
Write-8                     68.2MB/s ± 9%  103.9MB/s ± 1%   +52.42%
WriteRTP-8                  73.6MB/s ± 2%  111.0MB/s ± 3%   +50.94%

name                        old alloc/op   new alloc/op    delta
EncryptRTP-8                    884B ± 0%       292B ± 0%   -66.97%
EncryptRTPInPlace-8             756B ± 0%       164B ± 0%   -78.31%
DecryptRTP-8                    780B ± 0%       188B ± 0%   -75.90%
Write-8                         916B ± 0%       324B ± 0%   -64.63%
WriteRTP-8                      804B ± 0%       212B ± 0%   -73.63%

name                        old allocs/op  new allocs/op   delta
EncryptRTP-8                    9.00 ± 0%       7.00 ± 0%   -22.22%
EncryptRTPInPlace-8             8.00 ± 0%       6.00 ± 0%   -25.00%
DecryptRTP-8                    9.00 ± 0%       7.00 ± 0%   -22.22%
Write-8                         9.00 ± 0%       7.00 ± 0%   -22.22%
WriteRTP-8                      8.00 ± 0%       6.00 ± 0%   -25.00%
```

v2.0.5

Toggle v2.0.5's commit message
Fix broken merge

d6ae2a5 missed RTP
API changes

v2.0.4

Toggle v2.0.4's commit message
Revert "Update github.com/pion/rtp to v2"

pion/webrtc is going to use /v0 until we are ready for a new major
version

v2.0.3

Toggle v2.0.3's commit message
Fix RolloverCount calculation error

Fix Unorder interval exceeds maxROCDisorder causing
RolloverCount error.

v2.0.2

Toggle v2.0.2's commit message
Fix destination buffer handling of AEAD cipher

- Fix not to change input buffer on decrypt
- Support in-place encrypt/decrypt

v2.0.1

Toggle v2.0.1's commit message
Fix buffer type assertion

Fix buffer type assertion to set read dead line on
packetio Buffer