unosquare / ffmediaelement

FFME: The Advanced WPF MediaElement (based on FFmpeg)
https://unosquare.github.io/ffmediaelement/
Other
1.17k stars 240 forks source link

Is there a way to integrate cryptography? like this command : ffplay -srtp_in_suite AES_CM_128_HMAC_SHA1_80 -srtp_in_params zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz srtp://239.0.0.1:20000 #523

Closed dida1it closed 3 years ago

dida1it commented 3 years ago

Issue Title (change this title!)

Please enter a general description for the issue. Delete sections that are not relevant and provide additional sections if necessary.

Issue Categories

Version Information

Steps to Reproduce

  1. Step 1
  2. Step 2
  3. Step 3

Expected Results

Sample Code

XAML

<MainWindow>
</MainWindow>

C

System.Console.WriteLine("Change Me Please!");

Command line ffplay

ffplay "hello.mp4"

Delete This Section

dida1it commented 3 years ago

ffplay -srtp_in_suite AES_CM_128_HMAC_SHA1_80 -srtp_in_params zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz srtp://239.0.0.1:20000

dida1it commented 3 years ago

I found a solution if (e.MediaSource.StartsWith("srtp://", StringComparison.OrdinalIgnoreCase)) { e.Configuration.PrivateOptions["srtp_in_suite"] = "AES_CM_128_HMAC_SHA1_80"; e.Configuration.PrivateOptions["srtp_in_params"] = "zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz"; }

dida1it commented 3 years ago
      if (e.MediaSource.StartsWith("srtp://", StringComparison.OrdinalIgnoreCase))
        {
            e.Configuration.PrivateOptions["srtp_in_suite"] = "AES_CM_128_HMAC_SHA1_80";
            e.Configuration.PrivateOptions["srtp_in_params"] = "zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz";
        }
mariodivece commented 3 years ago

Correct! Thanks for sharing your solution!