Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DRM videos not downloaded when running natively on Linux #629

Open
modelfe opened this issue Nov 9, 2024 · 4 comments
Open

DRM videos not downloaded when running natively on Linux #629

modelfe opened this issue Nov 9, 2024 · 4 comments

Comments

@modelfe
Copy link

modelfe commented Nov 9, 2024

Running this natively on Linux as described here isn't downloading any DRM videos.

Non-DRM content downloads fine. No problem downloading DRM videos on Windows. I haven't tried running it in Docker yet.

Output example:

cd "OF-DL/OF DL/bin/Release/net8.0"
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT=1 ./'OF DL'
 __        __         _                                       _             
 \ \      / /   ___  | |   ___    ___    _ __ ___     ___    | |_    ___    
  \ \ /\ / /   / _ \ | |  / __|  / _ \  | '_ ` _ \   / _ \   | __|  / _ \   
   \ V  V /   |  __/ | | | (__  | (_) | | | | | | | |  __/   | |_  | (_) |  
    \_/\_/     \___| |_|  \___|  \___/  |_| |_| |_|  \___|    \__|  \___/   
                                                                            
   ___    _____           ____    _     
  / _ \  |  ___|         |  _ \  | |    
 | | | | | |_     _____  | | | | | |    
 | |_| | |  _|   |_____| | |_| | | |___ 
  \___/  |_|             |____/  |_____|
                                        
config.json located successfully!
You are running OF-DL version 1.7.83
Latest GitHub Release version: 1.7.83
auth.json located successfully!
rules.json located successfully!
FFmpeg located successfully. Path auto-detected: /usr/bin/ffmpeg
device_client_id_blob and/or device_private_key missing, 
https://cdrm-project.com/ will be used instead for DRM protected videos
Logged In successfully as xxx
Downloading from List(s): xxx
Scraping Data for xxx
Folder for xxx already created
Getting Messages
Found 5 Media from xxx Messages
                                                                    
Downloading 5 Messages ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━   0%
                                                                    Exception caught: Object reference not set to an instance of an object.

StackTrace:    at OF_DL.Helpers.DownloadHelper.OnError(Object sender, ConversionErrorEventArgs e) in /home/xxx/OF-DL/OF DL/Helpers/DownloadHelper.cs:line 942
   at FFmpeg.NET.Engine.OnError(ConversionErrorEventArgs e)
   at FFmpeg.NET.FFmpegProcess.OnConversionError(ConversionErrorEventArgs eventArgs)
   at FFmpeg.NET.FFmpegProcess.OnException(List`1 messages, FFmpegParameters parameters, Int32 exitCode, Exception caughtException)
   at FFmpeg.NET.FFmpegProcess.ExecuteAsync(ProcessStartInfo startInfo, FFmpegParameters parameters, CancellationToken cancellationToken)
   at FFmpeg.NET.FFmpegProcess.ExecuteAsync(CancellationToken cancellationToken)
   at FFmpeg.NET.Engine.ExecuteAsync(FFmpegParameters parameters, CancellationToken cancellationToken)
   at FFmpeg.NET.Engine.ExecuteAsync(String arguments, CancellationToken cancellationToken)
   at OF_DL.Helpers.DownloadHelper.DownloadDrmMedia(String user_agent, String policy, String signature, String kvp, String sess, String url, String decryptionKey, String folder, DateTime lastModified, Int64 media_id, String api_type, Progre                                                                     

@melithine
Copy link
Collaborator

What version of ffmpeg?

@modelfe
Copy link
Author

modelfe commented Nov 9, 2024

What version of ffmpeg?

ffmpeg version 4.4.2-0ubuntu0.22.04.1

@melithine
Copy link
Collaborator

You really want 7.0.2 or newer. Some older 6.x releases are fine, too, but I'm not sure which, and people have had the most luck with 7.0.2+.

@cactus1902
Copy link

cactus1902 commented Nov 21, 2024

On Linux I can confirm that on the latest snapshot of ffmpeg (https://ffmpeg.org/releases, scroll down to "ffmpeg-snapshot.tar.bz2", version is 2024-11-20 19:26 at the time of writing this), as well as on the latest commit of this repo (6b823f4), DRM videos do not work. Regular videos do. DRM videos also download fine on Windows as OP said.

Unlike OP, I'm also using my own device_client_id_blob and device_private_key, which do work (I can download DRM videos on Windows, as I said).

All other versions of ffmpeg that I have (version 6, 7.0.2, 20240504, and 20240629) have the same issue with DRM content.

The error message is also identical:

Exception caught: Object reference not set to an instance of an object.

StackTrace:    at OF_DL.Helpers.DownloadHelper.OnError(Object sender, ConversionErrorEventArgs e) in /mnt/mpathac/xxx/OF-DL/OF DL/Helpers/DownloadHelper.cs:line 940
   at FFmpeg.NET.Engine.OnError(ConversionErrorEventArgs e)
   at FFmpeg.NET.FFmpegProcess.OnConversionError(ConversionErrorEventArgs eventArgs)
   at FFmpeg.NET.FFmpegProcess.OnException(List`1 messages, FFmpegParameters parameters, Int32 exitCode, Exception caughtException)
   at FFmpeg.NET.FFmpegProcess.ExecuteAsync(ProcessStartInfo startInfo, FFmpegParameters parameters, CancellationToken cancellationToken)
   at FFmpeg.NET.FFmpegProcess.ExecuteAsync(CancellationToken cancellationToken)
   at FFmpeg.NET.Engine.ExecuteAsync(FFmpegParameters parameters, CancellationToken cancellationToken)
   at FFmpeg.NET.Engine.ExecuteAsync(String arguments, CancellationToken cancellationToken)
   at OF_DL.Helpers.DownloadHelper.DownloadDrmMedia(String user_agent, String policy, String signature, String kvp, String sess, String url, String decryptionKey, String folder,                                                                                        mFileName, String filename, String path) in /mnt/mpathac/xxx/OF-DL/OF DL/Helpers/Dow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants