Hey Bobby,
https://bugs.chromium.org/p/chromium/issues/detail?id=713701#c22
I have also brought this up in the IETF/W3C but haven’t had much luck either.
IMO overnight this would mean a dramatic improvement for underpowered devices, high client CPU usage is in the top 5 complaints I get from people building this with Pion WebRTC. If anyone has any idea on how to get this jump started/escalated I would be so grateful 😊
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/89224011-d327-447a-b61e-04f33e1417d8%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/A7AB83D0-377C-46A9-99DB-621C0B192801%40pion.ly.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CAOqqYVGu-r4%2BzbftkKnTowKtme3KuSEjvytP1nx_Jo1OdH7N3A%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CA%2Bb7xQuHk9hsG2bOaNTEu1RveX8M6RTNJaaPp%3DR%2BmoZ07tqKbg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CAOqqYVHW_bA3a7O8iy3TbRJ3RWviL4xarE%3DkN-kj4RM0S_z%2B_Q%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CADxkKiKS0Bq2QESC%3DBqOpZQcdys3M0W0RnQ8TSy0%2BS9RO%2BuHuw%40mail.gmail.com.
On Oct 16, 2019, at 09:37, Bobby Mah <bits...@gmail.com> wrote:
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/d48b599f-92cd-429d-b772-f17d94f0656d%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/302142E8-597F-46AE-B3E8-10373A6F7020%40pion.ly.
When https://bugs.chromium.org/p/chromium/issues/detail?id=713701 is resolved Chrome will be able to use SRTP AES-GCM! You can test this today by enabling the experiment.
Chrome <-> Chrome will never use it. There is no W3C API to influence SRTP cipher suite order. The non-accelerated suites will be the default.
You can see what suites are being used today by using wireshark and looking at the DTLS ClientHello/ServerHello use_srtp values. The ClientHello is all the suites supported by the client, the ServerHello then contains the suite that was selected.
From: <discuss...@googlegroups.com> on behalf of Bobby Mah <bits...@gmail.com>
Reply-To: <discuss...@googlegroups.com>
Date: Wednesday, October 16, 2019 at 10:21 AM
To: discuss-webrtc <discuss...@googlegroups.com>
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/e636352a-b5c9-4a2d-84b4-72c34cd1378b%40googlegroups.com.
Server hello
As you can see its not choosing the GCM. Perhaps its an issue in the server and I am looking into that. Its just that I expected the chrome browser client to send GCM as the first cipher suite
Hey Bobby,
You will want to look at the use_srtp extension value. Inserted a screenshot so you can see what it looks like.
From: <discuss...@googlegroups.com> on behalf of Bobby Mah <bits...@gmail.com>
Reply-To: <discuss...@googlegroups.com>
Date: Tuesday, October 22, 2019 at 12:35 PM
To: discuss-webrtc <discuss...@googlegroups.com>
Subject: [discuss-webrtc] Re: Hardware acceleration for libsrtp
Hi Sean,
I tried the chrome flags but here is what I see in the client and server `Hellos` respectively
Client hello
Server hello
As you can see its not choosing the GCM. Perhaps its an issue in the server and I am looking into that. Its just that I expected the chrome browser client to send GCM as the first cipher suite
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/1ac479f8-8c85-4956-8b83-7ebc591906ef%40googlegroups.com.
Always happy to help! Feel free to reach out directly or on the Pion slack if you have questions better asked real-time :)AES GCM is what you want if you want hardware acceleration, no other suites support it AFAIK!How much of a issue is 6 more bytes? Would love to know what that actually looks like for the ‘average real world’ call.On Oct 16, 2019, at 09:37, Bobby Mah <bits...@gmail.com> wrote:
--
Thanks all for the informationHarald, in my scenario there's no encoding and SRTP encryption and decryption does take up 20% of CPUSean, thanks for the information about AES GCM.But, I was requesting information about hardware enabled crypto, so not sure if my question was answered.Thanks again everyone!
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss...@googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/eb9e50b6-e959-4943-8990-14d64080a6a9%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/eb9e50b6-e959-4943-8990-14d64080a6a9%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/ef482bba-67fd-4427-8bb7-247ef152d056%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/ef482bba-67fd-4427-8bb7-247ef152d056%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/fe12c34a-0ca5-41f4-a0b5-ed78a566758d%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/16988f30-5b69-444e-ae2f-28cf3b5ec170%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/80e915dc-1946-4a5d-accf-e90055ba243b%40googlegroups.com.
As my post shows that the srtp cipher is GCM. However, it's still not using the hardware support for crypto in the CPU. Any ideas why?
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/fc4fcbca-f2a5-4edc-885e-b3cf7260a8bc%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/2a70a240-2ce8-465a-a036-e0c37579dd18%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/4bd17ad2-e970-44a3-804f-df427d808cf2%40googlegroups.com.
👊Bobby, can you share more detail on your numbers? This might be useful for others to know.
On Tue, Oct 29, 2019 at 12:59 PM Sean DuBois <se...@pion.ly> wrote:
That is fantastic news! Exciting to see how much of an impact it has.--This is the best thread I have seen on this list in a while, multiple people helping out really great stuff :)
On Tuesday, October 29, 2019 at 12:46:39 PM UTC-7, Bobby Mah wrote:That worked out nicely Justin, CPU usage went from 40% to 25%.Thanks so much for your help Justin/Thanks to everyone else who contributed too!
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss...@googlegroups.com.
For SFU performance I am most excited by https://tools.ietf.org/html/draft-ietf-perc-srtp-ekt-diet-10 I have no contact with the authors, but would love to support it with Pion. Maybe I will reach out directly
I am all for improving the performance of AES-CBC-SHA1, but I hit some roadblocks and decided it wasn’t worth the effort (and pushing for AES-GCM was more realistic)
* Most of the developers I have worked with are sticking with older stuff for stability reasons, so even if things land it will take a while for them to get it. Hardware Accelerated AES-GCM works today.
* Security reviewers see AES-CBC-SHA1 and instantly say it is a problem. It might not be fair, but this has come up at multiple companies. They just are ticking box and AES-GCM wins every time.
* This isn’t just a OpenSSL/libsrtp thing. Go doesn’t have a performant primitive for AES-CBC-SHA1, but AES-GCM is hardware accelerated and available everywhere today.
If there was a clear path forward, and someone was paying me always up for an adventure! 😊
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/a9a74988-8812-4a4d-9d99-f5349759e27c%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/2E6E5B9C-40EB-4E54-B218-9D0D5AB941AD%40pion.ly.
For SFU performance I am most excited by https://tools.ietf.org/html/draft-ietf-perc-srtp-ekt-diet-10 I have no contact with the authors, but would love to support it with Pion. Maybe I will reach out directly
I am all for improving the performance of AES-CBC-SHA1, but I hit some roadblocks and decided it wasn’t worth the effort (and pushing for AES-GCM was more realistic)
* Most of the developers I have worked with are sticking with older stuff for stability reasons, so even if things land it will take a while for them to get it. Hardware Accelerated AES-GCM works today.
* Security reviewers see AES-CBC-SHA1 and instantly say it is a problem. It might not be fair, but this has come up at multiple companies. They just are ticking box and AES-GCM wins every time.
* This isn’t just a OpenSSL/libsrtp thing. Go doesn’t have a performant primitive for AES-CBC-SHA1, but AES-GCM is hardware accelerated and available everywhere today.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/22122146-0d1b-4fc7-97d6-11913f6f4bff%40googlegroups.com.
Do you know how performance of AES-CBC-SHA1 compares to AES-GCM on a machine that has SHA hardware extensions like AMD EPYC and the upcoming Intel Ice Lake?
Is it possible to use both stitching and multi-buffer or do I need to choose one?
This [1] looks like a command line example for stitching. Does OpenSSL has somthing like the EVP_ functions for stitching I can use in my project?
WARNING: this is not intended for usage outside of TLS and requires calling of some undocumented ctrl functions. These ciphers do not conform to the EVP AEAD interface.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/140837d2-319f-4c59-831a-658e6096e1e2%40googlegroups.com.
Block |
aes-128-cbc-hmac-sha1 |
aes-256-gcm |
Speedup |
16 |
45,610,752 |
46,566,133 |
1.02 |
64 |
14,598,340 |
31,844,585 |
2.18 |
256 |
5,498,918 |
11,588,535 |
2.11 |
1024 |
1,635,463 |
3,219,048 |
1.97 |
8192 |
217,085 |
414,262 |
1.91 |
16384 |
108,950 |
207,887 |
1.91 |
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/6bcf56d7-9a71-45eb-add5-cdca81794754%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/32984c46-ad3f-4b72-ae83-e5d315322ffb%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CADxkKiK3ikCV3Wg9atRKXACTAKu5%3Ds8GT57puSVVQPLWzFNMPA%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/CANdLC8XPnvNCveAp4w_O6Cuw8H%3DWr3VzRGDWMAy-M5YBMHganw%40mail.gmail.com.
Hello @RomanHow hard will it be to add stitched aes-128-hmac-sha1 (encrypt-then-mac) to OpenSSL?There is implementation of mac-then-encrypt but I'm not familiar with perl or assembly.Is it just a matter of reordering staff in [1] or will I need deep understanding?Does Intel QAT replaces stitched aes-128-hmac-sha1 or can I use both at the same time to accelerate?Do I need to compile OpenSSL with QAT manually [2] on Ubuntu? Do I need to manually call a new OpenSSL function or will it just work?Is there an implementation of multi-buffer that's easy to use for the end user?
On Thu, Oct 31, 2019 at 11:01 PM 'Philipp Hancke' via discuss-webrtc <discuss...@googlegroups.com> wrote:
We just landed https://webrtc-review.googlesource.com/c/src/+/158404 which implements the strategy of not offering this as default suggested by Justin.Will require some manual testing that this works as intended but since this does not change the default behaviour (much) it *might* just ride the release train without a flag.
Am Do., 31. Okt. 2019 um 20:33 Uhr schrieb Roman Shpount <rshp...@gmail.com>:
You are correct. New assembler routine would need to be written for SRTP, but performance will likely be the same.--Another thing to look at for hardware acceleration on the server side is Intel QAT, which should already be available on Intel Salable Xeon CPU or add-on boards.
On Thursday, October 31, 2019 at 11:19:04 AM UTC-4, pablo wrote:Roman, I don't think that OpenSSL support stitching for AES-SHA1 (encrypt-then-mac).
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/32984c46-ad3f-4b72-ae83-e5d315322ffb%40googlegroups.com.
--
---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss...@googlegroups.com.