Giter Site home page Giter Site logo

of-drm's Introduction

OF-DRM

C# console app to download DRM protected videos from Onlyfans accounts

Installation

I have tried to make this a lot more simple to set up compared to OF DL.

The only thing you need to do is go to the releases page and download the latest release zip file.

Extract the zip file somewhere safe using 7zip or winrar, you should have 3 files and 2 folders:

  • OF DRM.exe
  • auth.json
  • e_sqlite3.dll
  • EXEs - this contains yt-dlp.exe, mp4decrypt.exe and ffmpeg.exe with the paths already set up correctly in the auth.json file. DO NOT TOUCH THEM IF YOU DON'T KNOW WHAT YOU ARE DOING!
  • cdm - this is where you need to put your device_client_id_blob and device_private_key files. They need to be placed in cdm/devices/chrome_1610/.

Next you need to fill out the auth.json file.

  1. Go to www.onlyfans.com and login.
  2. Press F12 to open dev tools and select the 'Network' tab.
  3. In the search box type 'api'

image

  1. Click on one of the requests (if nothing shows up refresh the page or click on one of the tabs such as messages to make something appear).
  2. After clicking on a request, make sure the headers tab is selected and then scroll down to find the 'Request Headers' section, this is where you should be able to find the information you need.
  3. Copy the values of cookie, user-agent, user-id (this should just be a number, do not include a u) and x-bc to the auth.json file where the paths to yt-dlp, ffmpeg and mp4decrypt should already be.
  4. Save the file.

You should have something like this:

"USER_ID": "123456789" - Do NOT include the u that gets exported using the Onlyfans Cookie Helper

"USER_AGENT": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/112.0.0.0 Safari/537.36" - Make sure this is set to your user-agent value

"X_BC": "2a9b28a68e7c03a9f0d3b98c28d70e8105e1f1df" - Make sure this is set to your x-bc value

"COOKIE": "auth_id=123456789; sess=k3s9tnzdc8vt2h47ljxpmwqy5r;" - Make sure you set auth_id to the same value as user-id and that you set your sess to your actual sess value, everytime you log out of Onlyfans this value will change so make sure to update it after every login.

Next you will need to get 2 files, device_client_id_blob and device_private_key. These are used to get the decryption keys needed for downloading DRM videos. You can find a tutorial on how to do this here https://forum.videohelp.com/threads/408031-Dumping-Your-own-L3-CDM-with-Android-Studio Make sure you remove the file extensions when renaming the 2 files, and move both files into cdm/devices/chrome_1610/.

Once you have filled all of the information out you can close auth.json and double click on OF DRM.exe and you should be ready to start downloading videos.

Videos

This scraper is aimed to download DRM videos only and nothing else.

You will get the choice to:

  • Download None of the videos found
  • Download All of the videos found
  • Select individual videos found, you will be able to see the Post/Message Id along with DateTime of that Post/Message.

To navigate the menu the can use the โ†‘ & โ†“ arrows, to select/deselect video(s) press the space key and after you are happy with your selection(s) press enter to start downloading.

Config Values

DownloadPaidPosts:

If set to true then any posts on the users feed that have been purchased by you and have DRM enabled videos will be scraped.

If set to false no paid posts will be scraped.

DownloadPosts:

If set to true then any posts on the users feed that have DRM enabled videos will be scraped.

If set to false no posts will be scraped.

DownloadArchived:

If set to true then any archived posts on the users feed that have DRM enabled videos will be scraped.

If set to false no archived posts will be scraped.

DownloadMessages:

If set to true then any free messages that have DRM enabled videos will be scraped.

If set to false no free messages will be scraped.

DownloadPaidMessages:

If set to true then any paid messages that have been purchased by you and have DRM enabled videos will be scraped.

If set to false no paid messages will be scraped.

IncludeExpiredSubscriptions:

If set to true then any past subscriptions that aren't currently active are included in the list of accounts you can scrape.

If set to false then any past subscriptions are excluded from the list of accounts you can scrape from.

DownloadPath:

If left blank then content will be downloaded to __user_data__/sites/OnlyFans/{username}

An example is if you set the download path to "S:/" then content will be downloaded to S:/{username}

Donations

If you would like to donate then here is a link to my ko-fi page https://ko-fi.com/sim0n00ps. Donations are not required but are very much appreciated:)

of-drm's People

Contributors

exercitusmortem avatar pendragon420 avatar sim0n00ps avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

of-drm's Issues

Instant Crash

I noticed today when I open the program it instantly closes without giving me time to read anything. It worked perfectly fine before. I don't understand

An exception?

Hello I'm not really sure what this means. I placed the 2 files in the folder as requested and checked all the values and it automatically closes but says this.
Untitled

Scrape missing individual DRM video in Messages

There is a single video, sent in messages, not a paid/ppv video, but it was sent in response to a main feed "donation campaign", that isn't being detected by OF-DRM. It's definitely DRM, Internet Download Manager reads it as Protected as well as a second chrome extension I've had for years.

I was able to download it successfully with OF-DL, so I think there is something about the selection process in OF-DRM that is skipping over it. Really big fan of these utilities; I can provide data from Inspect Elements in the div class="video-js", poster="http://cdn2.onlyfans.com/files/#/##/######", etc. from both the DRM videos it is detecting correctly and the one it is missing if that will assist, but I don't necessarily want to paste them publicly in case any of the data can identify my OF account.

Not working

After i modified the auth.json.. OF website on the browser page logs out automatically and getting "Auth failed, please check the values in auth.json are correct, press any key to exit" error on the app.

i relog again and re-edit with the latest session string on the auth.json but still getting the same error above... hmmmm

Downloading purchased videos

Hello is there a way to download purchased videos form my home tab or from messages? IMHO Onlyfans changed something in the last weeks. Anyone have experienced the same situations?

What is the issue with the following error message

Exception caught: The request was canceled due to the configured HttpClient.Timeout of 100 seconds elapsing.

                                                                                                        StackTrace:    at System.Net.Http.HttpClient.HandleFailure(Exception e, Boolean telemetryStarted, HttpResponseMessage response, CancellationTokenSource cts, CancellationToken cancellationToken, CancellationTokenSource pendingRequestsCts)

at System.Net.Http.HttpClient.g__Core|83_0(HttpRequestMessage request, HttpCompletionOption completionOption, CancellationTokenSource cts, Boolean disposeCts, CancellationTokenSource pendingRequestsCts, CancellationToken originalCancellationToken)
at OF_DRM_Video_Downloader.Helpers.APIHelper.GetSubscriptions(String endpoint, Boolean includeExpiredSubscriptions, Auth auth)

Inner Exception:
Exception caught: The operation was canceled.

The tool doesn't download the video in the Onlyfans message

The tool doesn't download the video in the Onlyfans message. It show as below forever:

Getting Paid Messages
Found 1 Paid Messages with DRM Video(s)
You selected to download 1 paid message videos
Downloading 1 Video(s) ---------------------------------------- 0% 0.0/1.1 GB --:--:--

I turn off my Firewall but the tool doesn't download the video from the expired subscription although I set the value of "IncludeExpiredSubscriptions" to be true.

OF-DRM NOT WORKING

OF-DRM opens for a second , stuck in ffmpeg located successfully , mp4decrypt located successfully , yt-dlp successfully then exit itself...what's the problem ?

How to use this repo for some MPD file

Hi:
I found one MPD file from internet, which is used to protect some HLS stream, I think maybe I can use this repo to decrypt and download the HLS stream, but I don't quite understand how to use the repo, could you please provide some instructions?
Here is the MPD file I got from internet:

AAACJnBzc2gAAAAAmgTweZhAQoarkuZb4IhflQAAAgYGAgAAAQABAPwBPABXAFIATQBIAEUAQQBEAEUAUgAgAHgAbQBsAG4AcwA9ACIAaAB0AHQAcAA6AC8ALwBzAGMAaABlAG0AYQBzAC4AbQBpAGMAcgBvAHMAbwBmAHQALgBjAG8AbQAvAEQAUgBNAC8AMgAwADAANwAvADAAMwAvAFAAbABhAHkAUgBlAGEAZAB5AEgAZQBhAGQAZQByACIAIAB2AGUAcgBzAGkAbwBuAD0AIgA0AC4AMAAuADAALgAwACIAPgA8AEQAQQBUAEEAPgA8AFAAUgBPAFQARQBDAFQASQBOAEYATwA+ADwASwBFAFkATABFAE4APgAxADYAPAAvAEsARQBZAEwARQBOAD4APABBAEwARwBJAEQAPgBBAEUAUwBDAFQAUgA8AC8AQQBMAEcASQBEAD4APAAvAFAAUgBPAFQARQBDAFQASQBOAEYATwA+ADwASwBJAEQAPgBCAEEANwBQAEEAcgBiADYAWQBGAG0ARQBTAGUAaAA0AHUAbABiAG0ALwBnAD0APQA8AC8ASwBJAEQAPgA8AEMASABFAEMASwBTAFUATQA+ACsAMwB4ADgAbQBtADYAbgBTAEkAYwA9ADwALwBDAEgARQBDAEsAUwBVAE0APgA8AC8ARABBAFQAQQA+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APgAxADYAPAAvAEsARQBZAEwARQBOAD4APABBAEwARwBJAEQAPgBBAEUAUwBDAFQAUgA8AC8AQQBMAEcASQBEAD4APAAvAFAAUgBPAFQARQBDAFQASQBOAEYATwA+ADwASwBJAEQAPgBCAEEANwBQAEEAcgBiADYAWQBGAG0ARQBTAGUAaAA0AHUAbABiAG0ALwBnAD0APQA8AC8ASwBJAEQAPgA8AEMASABFAEMASwBTAFUATQA+ACsAMwB4ADgAbQBtADYAbgBTAEkAYwA9ADwALwBDAEgARQBDAEsAUwBVAE0APgA8AC8ARABBAFQAQQA+ADwALwBXAFIATQBIAEUAQQBEAEUAUgA+AA== BgIAAAEAAQD8ATwAVwBSAE0ASABFAEEARABFAFIAIAB4AG0AbABuAHMAPQAiAGgAdAB0AHAAOgAvAC8AcwBjAGgAZQBtAGEAcwAuAG0AaQBjAHIAbwBzAG8AZgB0AC4AYwBvAG0ALwBEAFIATQAvADIAMAAwADcALwAwADMALwBQAGwAYQB5AFIAZQBhAGQAeQBIAGUAYQBkAGUAcgAiACAAdgBlAHIAcwBpAG8AbgA9ACIANAAuADAALgAwAC4AMAAiAD4APABEAEEAVABBAD4APABQAFIATwBUAEUAQwBUAEkATgBGAE8APgA8AEsARQBZAEwARQBOAD4AMQA2ADwALwBLAEUAWQBMAEUATgA+ADwAQQBMAEcASQBEAD4AQQBFAFMAQwBUAFIAPAAvAEEATABHAEkARAA+ADwALwBQAFIATwBUAEUAQwBUAEkATgBGAE8APgA8AEsASQBEAD4AQgBBADcAUABBAHIAYgA2AFkARgBtAEUAUwBlAGgANAB1AGwAYgBtAC8AZwA9AD0APAAvAEsASQBEAD4APABDAEgARQBDAEsAUwBVAE0APgArADMAeAA4AG0AbQA2AG4AUwBJAGMAPQA8AC8AQwBIAEUAQwBLAFMAVQBNAD4APAAvAEQAQQBUAEEAPgA8AC8AVwBSAE0ASABFAEEARABFAFIAPgA=

Windows Defender (false?)positive?!

Hi, I just now found this project, after setting up your other, yesterday... and well, Version 1.7 does cause a (false?)positive hit with windows defender for "Trojan:Win32/Sabsik.FL.B!ml" (a ransomware trojan, apparently) ... 1.6 does not, though?

Problem getting DRM keys

I followed the instructions of Dumping Your onw L3 CDM, everything loads perfectly but the problem is that it is only for previous versions of Android 11, in the tutorial it does it from android 9 and onlyfans does not load in that version, it keeps loading the onlyfans logo without entering the page. I tried it with later versions but the program to obtain the keys fails, in the android 11 version it does not generate the keys but it does not give an error either, could you tell me exactly how you do it to generate the keys please? I swear I'll make it up to you

No client id blob found, but files present

I followed the guide to get the device_client_id_blob and device_private_key files which are in the cdm folder

C:\Users\dm\Downloads\OF.DRM.V1.7\cdm\devices\chrome_1610\device_client_id_blob.bin
C:\Users\dm\Downloads\OF.DRM.V1.7\cdm\devices\chrome_1610\device_private_key.pem

auth is set up and able to log me in fine. When i go to download posts i get this error and then files download as separate mp4 and m4a files which i cant get to play.

Downloading 1 Video(s) ----------------------------------------   0% 0.0/33.4 MB --:--:--
        Exception caught: The type initializer for 'WidevineClient.Widevine.CDM' threw an exception.

StackTrace:    at WidevineClient.Widevine.CDM.OpenSession(String initDataB64, String deviceName, Boolean offline, Boolean raw)
   at WidevineClient.Widevine.CDMApi.GetChallenge(String initDataB64, String certDataB64, Boolean offline, Boolean raw)
   at OF_DRM_Video_Downloader.Helpers.APIHelper.GetDecryptionKeyNew(Dictionary`2 drmHeaders, String licenceURL, String pssh)

Inner Exception:
Exception caught: No client id blob found

StackTrace:    at WidevineClient.Widevine.CDMDevice..ctor(String deviceName, Byte[] clientIdBlobBytes, Byte[] privateKey
Downloading 1 Video(s) ----------------------------------------   0% 0.0/33.4 MB --:--:--
        Exception caught: Could not find file 'C:\Users\dm\Downloads\OF.DRM.V1.7\__user_data__\sites\OnlyFans\nnnnekochan\Posts\Free\Videos\0hk08umn664sai9tupibv_source.mp4'.

StackTrace:    at System.IO.FileSystem.OpenHandleToWriteAttributes(String fullPath, Boolean asDirectory)
   at System.IO.FileSystem.SetFileTime(String fullPath, Boolean asDirectory, Int64 creationTime, Int64 lastAccessTime, Int64 lastWriteTime, Int64 changeTime, UInt32 fileAttributes)
   at System.IO.FileSystem.SetLastWriteTime(String fullPath, DateTimeOffset time, Boolean asDirectory)
   at System.IO.File.SetLastWriteTime(String path, DateTime lastWriteTime)
   at OF_DRM_Video_Downloader.Helpers.DownloadHelper.DownloadPostDRMVideo(String ytdlppath, String mp4decryptpath, Strin                                                                                     , String url, String decryption
Downloading 1 Video(s) ----------------------------------------   0% 0.0/33.4 MB --:--:--

somethong wrong with cookie

When I try to update the cookie I get an error, whenever I enter a new sess and open the of-drm.exe, my OF account automatically logs out and updates the cookie!

Android Emulator hypervisor driver is not installed

I get to the point where I need the two files.
But my virtual phone does not boot because the android emulator hypervisor driver is missing, and I have no idea how to fix this problem. The tutorial on the external website is unfortunately quite old and not very detailed.
Is there no way to get the files without having studied rocket science? Maybe with a real Android device?
Screenshot 2023-10-23 182710
Screenshot 2023-10-23 182710

Issues downloading paid messages

Hi, for some reason, the scrapper is not finding any drm paid messages. And I have two that I've bought that I'm trying to download.

Virtual Device Offline

Hey sim0n thank u for your work.

This is concerning getting 'device_client_id_blob and device_private_key', been working endlessly on it.

I can't execute the adb exe because it says "device offline", correctly so since my virtual phone is never booting up when i click Play.

Lmk

Exception caught: Unable to parse license

When trying to download paid posts from messages, I'll get this error:

image

As you can see, the regular posts download correctly. Any idea what might be causing this?

I normally use OF-DL instead of OF-DRM, but since this specific user has so much content and I only wanted to grab my latest purchase, I decided to try this version.

Where do you place the DRM files ?

I renamed the files to device_client_id_blob and device_private_key but I keep getting the following error:

Exception caught: The type initializer for 'WidevineClient.Widevine.CDM' threw an exception.

StackTrace: at WidevineClient.Widevine.CDM.OpenSession(String initDataB64, String deviceName, Boolean offline, Boolean raw)
at WidevineClient.Widevine.CDMApi.GetChallenge(String initDataB64, String certDataB64, Boolean offline, Boolean raw)
at OF_DRM_Video_Downloader.Helpers.APIHelper.GetDecryptionKeyNew(Dictionary`2 drmHeaders, String licenceURL, String pssh)

Inner Exception:
Exception caught: No client id blob found

StackTrace: at WidevineClient.Widevine.CDMDevice..ctor(String deviceName, Byte[] clientIdBlobBytes, Byte[] privateKey

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.