• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[Magisk] [Module] liboemcrypto disabler for DRM-protected content (Netflix, My5, etc)

Search This thread

ianmacd

Senior Member
Jan 5, 2016
2,352
3,791
Amsterdam
localhost
Apps that use liboemcrypto.so to play content protected by DRM, such as Netflix and My5, will fail when playback is attempted on a rooted device.

The symptoms displayed by affected devices vary by brand and Android version. Some devices may display an obscure error message when you attempt playback. Others may just appear stuck loading the requested content.

This Magisk module fixes the problem by masking liboemcrypto.so with a zero byte replacement. Whilst the same effect could be achieved by simply deleting or renaming liboemcrypto.so with a root-enabled file manager, this has the disadvantage of altering your /system partition by writing to the file-system. The advantage of the Magisk method is that no actual changes are made to the device. The problematic file is merely concealed from the apps that attempt to use it.

To use the module, flash it in the Modules section of Magisk Manager and then reboot your device.

The module works when the library in question is located at either /system/lib/liboemcrypto.so or /system/vendor/lib/liboemcrypto.so. If your library is located elsewhere (or missing), this module will have no effect (but it's harmless to try it).

The module has been verified working on a Samsung Galaxy S9+ (SM-G965F/DS) running Magisk 16.x/17.x/18.x on a variery of ROMs, on a Samsung Tab S3 (SM-T820) running stock Android 8.0 and Magisk 16.x/17.x, and on a Samsung Tab S4 (SM-T830) running stock Android 8.1 and Magisk 17.x/18.x. It was created because a similar module on XDA did not work on my devices. It is being released by popular request, because a number of other users contacted me with the same complaint.

The module was integrated into the official Magisk module repository on 2018-06-27, and can therefore be directly downloaded from within the Magisk Manager app.

Please note that a consequence of using this module is that Widevine DRM will fall back to using L3 instead of L1. This means that Netflix will play all content in SD quality, regardless of your subscription type. Of course, without this module, you won't be able to play anything on a rooted device, so beggars can't be choosers.

Change log:

2020-12-20: v1.5
  • Updated for Magisk v21 template format.

2019-03-29: v1.4
  • Updated for Magisk v19 template format.
  • Issue a warning if installed on an S10e (G970F), S10 (G973F) or S10+ (G975F).

2018-12-06: v1.3
  • Added support for devices that have the library under either /system/lib64 or /system/vendor/lib64.
  • Added support for devices that have the library in multiple locations.

2018-07-22: v1.2
  • Added logic to install in only the appropriate library directory, rather than in both.

2018-05-29: v1.1
  • Added support for devices that have the library under /system/vendor/lib instead of /system/lib.

2018-04-23: v1.0
  • Initial release.
 
Last edited:

an0therus3r

Senior Member
Oct 19, 2009
465
21
Thanks for the module @ianmacd, finaly Netflix working again on my rooted and Widevine L1 patched Oneplus5.
I noticed this module actually reverts your device back to Widevine L3 when module is active, is that correct?
 

ianmacd

Senior Member
Jan 5, 2016
2,352
3,791
Amsterdam
localhost
Thanks for the module @ianmacd, finaly Netflix working again on my rooted and Widevine L1 patched Oneplus5.
I noticed this module actually reverts your device back to Widevine L3 when module is active, is that correct?

Yes, this is an unfortunate side-effect of the module. The module fakes the erasure of the DRM library, which enables playback, but not in HD.

If HD is important to you, there are patched Netflix binaries floating around, but I believe they are quite an old version. I mainly use my tablet to cast to the television, so it's not a problem for me. I should add something about this to the documentation.
 

mrjuniork

Forum Moderator
Staff member
Aug 29, 2015
1,163
1,887
OnePlus 5
OnePlus 6
Why did I have my device manually updated by ONEPLUS in order to enjoy HD content thru YouTube, prime, Netflix etc.. if it is conflicting with Netflix, the one I use the most?? This is pretty weird. This model is a great work around, but now I'm back to L3 and the whole point was to enjoy L1. What do you mean with patched Netflix libraries? Can you maybe point me in the right direction? That'd be greatly appreciated :)
 

ianmacd

Senior Member
Jan 5, 2016
2,352
3,791
Amsterdam
localhost
Why did I have my device manually updated by ONEPLUS in order to enjoy HD content thru YouTube, prime, Netflix etc.. if it is conflicting with Netflix, the one I use the most?? This is pretty weird. This model is a great work around, but now I'm back to L3 and the whole point was to enjoy L1. What do you mean with patched Netflix libraries? Can you maybe point me in the right direction? That'd be greatly appreciated :)

This article contains an introduction to the problem. Basically, you either need to patch the APK or find one pre-patched by someone else.

Most, if not all people use apktool for this kind of work, but later versions of the Netflix APK can't currently be decompiled, so if you look around for a patched APK, you'll necessarily find an old version.
 

zfk110

Senior Member
Jan 11, 2014
1,024
202
Atlanta
Version 1.1 has been released with support for devices that have the library under /system/vendor/lib instead.

I didnt fix my error -9 still getting same error sorry we couldn't get Netflix service error (-9) running on Note 4 with Magisk 16.4 on MM ROM

*edit* I went into /vendor/lib/ and delete (take a backup of it) the file liboemcrypto.so, reboot and it worked! I dont know if that the right way to fix it? this Module seems like didn't change anything
 
Last edited:

ianmacd

Senior Member
Jan 5, 2016
2,352
3,791
Amsterdam
localhost
I didnt fix my error -9 still getting same error sorry we couldn't get Netflix service error (-9) running on Note 4 with Magisk 16.4 on MM ROM

*edit* I went into /vendor/lib/ and delete (take a backup of it) the file liboemcrypto.so, reboot and it worked! I dont know if that the right way to fix it? this Module seems like didn't change anything

Thank you for the report. I will investigate the matter.

The module should have worked with that path. I have a device myself that has liboemcrypto.so in that location, and the module works fine with it. I'll look into it.
 

zfk110

Senior Member
Jan 11, 2014
1,024
202
Atlanta
Thank you for the report. I will investigate the matter.

The module should have worked with that path. I have a device myself that has liboemcrypto.so in that location, and the module works fine with it. I'll look into it.

this time I download the module direct from Magisk without using the your provided zip and then installing using from TWRP

this time it worked, now I can use Netflix without any issues I download and installed the module direct from Magisk
 

ianmacd

Senior Member
Jan 5, 2016
2,352
3,791
Amsterdam
localhost
this time I download the module direct from Magisk without using the your provided zip and then installing using from TWRP

this time it worked, now I can use Netflix without any issues I download and installed the module direct from Magisk

That's weird, too, because it's the same version in both cases.

I assume you returned liboemcrypto.so to your device before installing the module. If not, there wouldn't have been anything for the module to do.
 
  • Like
Reactions: Selva1

locuturus

Senior Member
I don't know if this is related to the liboemcrypto.so library or something very different: I would like to screen cast (as in mirror my display to a Chromecast) protected content such as Prime Video. If I do so now then the result is sound + captions and a black screen. No video. This module sort of fixed my problem with Prime Video but not entirely so I wonder if you have insights into fully resolving this. I can't believe Google's own screen cast feature isn't trusted by Google's own Chromecast!
 

MetalIris

Senior Member
Nov 29, 2017
179
71
Massive thank you to the O.P been trying for a very long time to get all 4 to work on a rooted device with this module it WORKS!!! Thank you so much for the time you put into Roms and this Module!!
 

gellmar

Senior Member
Apr 10, 2013
269
249
Massive thank you to the O.P been trying for a very long time to get all 4 to work on a rooted device with this module it WORKS!!! Thank you so much for the time you put into Roms and this Module!!

With all regards to @ianmacd efforts, this hack will enforce falling back to Widevine L3, hence make Netflix HD a no-go.
I am now trying to fix Widevine L1 on Exynos5420 stuff, and I found out that SELinux enforcing mode restricting access from untrusted apps to read "/", and "mount", as well as restricting "toybox" system() calls effectively make up-to-date Netflix happy while debugging the mediadrmserver with gdbserver using root :p Of course a small SELinux policy change is required to make gdbserver work but this is out of scope.

If there is a way to assign a custom seclabel to processes or files related to package by its name, this approach can help using SELinux as an umbrella for apps like NF.
 

frwerewolf

Senior Member
Jan 12, 2013
84
10
Apps that use liboemcrypto.so to play content protected by DRM, such as Netflix and My5, will fail when playback is attempted on a rooted device.

The symptoms displayed by affected devices vary by brand and Android version. Some devices may display an obscure error message when you attempt playback. Others may just appear stuck loading the requested content.

This Magisk module fixes the problem by masking liboemcrypto.so with a zero byte replacement. Whilst the same effect could be achieved by simply deleting or renaming liboemcrypto.so with a root-enabled file manager, this has the disadvantage of altering your /system partition by writing to the file-system. The advantage of the Magisk method is that no actual changes are made to the device. The problematic file is merely concealed from the apps that attempt to use it.

To use the module, flash it in the Modules section of Magisk Manager and then reboot your device.

The module works when the library in question is located at either /system/lib/liboemcrypto.so or /system/vendor/lib/liboemcrypto.so. If your library is located elsewhere (or missing), this module will have no effect (but it's harmless to try it).

The module has been verified working on a Samsung Galaxy S9+ (SM-G965F/DS) running Magisk 16.x/17.x on a variery of ROMs, on a Samsung Tab S3 (SM-T820) running stock Android 8.0 and Magisk 16.x/17.x, and on a Samsung Tab S4 (SM-T830) running stock Android 8.1 and Magisk 17.x. It was created because a similar module on XDA did not work on my devices. It is being released by popular request, because a number of other users contacted me with the same complaint.

The module was integrated into the official Magisk module repository on 2018-06-27, and can therefore be directly downloaded from within the Magisk Manager app.

Please note that a consequence of using this module is that Widevine DRM will fall back to using L3 instead of L1. This means that Netflix will play all content in SD quality, regardless of your subscription type. Of course, without this module, you won't be able to play anything on a rooted device, so beggars can't be choosers.

Change log:

2018-07-22: v1.2

Added logic to install in only the appropriate library directory, rather than in both.


2018-05-29: v1.1

Add support for devices that have the library under /system/vendor/lib instead of /system/lib.


2018-04-23: v1.0

Initial release.

Ianmacd thank you 10 times for this and for the module that restores on Samsung note 9 previously paired bluetooth devices that were lost after reboot. You saved my life !! Hhh
 
  • Like
Reactions: ianmacd

Top Liked Posts

  • There are no posts matching your filters.
  • 47
    Apps that use liboemcrypto.so to play content protected by DRM, such as Netflix and My5, will fail when playback is attempted on a rooted device.

    The symptoms displayed by affected devices vary by brand and Android version. Some devices may display an obscure error message when you attempt playback. Others may just appear stuck loading the requested content.

    This Magisk module fixes the problem by masking liboemcrypto.so with a zero byte replacement. Whilst the same effect could be achieved by simply deleting or renaming liboemcrypto.so with a root-enabled file manager, this has the disadvantage of altering your /system partition by writing to the file-system. The advantage of the Magisk method is that no actual changes are made to the device. The problematic file is merely concealed from the apps that attempt to use it.

    To use the module, flash it in the Modules section of Magisk Manager and then reboot your device.

    The module works when the library in question is located at either /system/lib/liboemcrypto.so or /system/vendor/lib/liboemcrypto.so. If your library is located elsewhere (or missing), this module will have no effect (but it's harmless to try it).

    The module has been verified working on a Samsung Galaxy S9+ (SM-G965F/DS) running Magisk 16.x/17.x/18.x on a variery of ROMs, on a Samsung Tab S3 (SM-T820) running stock Android 8.0 and Magisk 16.x/17.x, and on a Samsung Tab S4 (SM-T830) running stock Android 8.1 and Magisk 17.x/18.x. It was created because a similar module on XDA did not work on my devices. It is being released by popular request, because a number of other users contacted me with the same complaint.

    The module was integrated into the official Magisk module repository on 2018-06-27, and can therefore be directly downloaded from within the Magisk Manager app.

    Please note that a consequence of using this module is that Widevine DRM will fall back to using L3 instead of L1. This means that Netflix will play all content in SD quality, regardless of your subscription type. Of course, without this module, you won't be able to play anything on a rooted device, so beggars can't be choosers.

    Change log:

    2020-12-20: v1.5
    • Updated for Magisk v21 template format.

    2019-03-29: v1.4
    • Updated for Magisk v19 template format.
    • Issue a warning if installed on an S10e (G970F), S10 (G973F) or S10+ (G975F).

    2018-12-06: v1.3
    • Added support for devices that have the library under either /system/lib64 or /system/vendor/lib64.
    • Added support for devices that have the library in multiple locations.

    2018-07-22: v1.2
    • Added logic to install in only the appropriate library directory, rather than in both.

    2018-05-29: v1.1
    • Added support for devices that have the library under /system/vendor/lib instead of /system/lib.

    2018-04-23: v1.0
    • Initial release.
    3
    Thanks for the module @ianmacd, finaly Netflix working again on my rooted and Widevine L1 patched Oneplus5.
    I noticed this module actually reverts your device back to Widevine L3 when module is active, is that correct?

    Yes, this is an unfortunate side-effect of the module. The module fakes the erasure of the DRM library, which enables playback, but not in HD.

    If HD is important to you, there are patched Netflix binaries floating around, but I believe they are quite an old version. I mainly use my tablet to cast to the television, so it's not a problem for me. I should add something about this to the documentation.
    3
    Why did I have my device manually updated by ONEPLUS in order to enjoy HD content thru YouTube, prime, Netflix etc.. if it is conflicting with Netflix, the one I use the most?? This is pretty weird. This model is a great work around, but now I'm back to L3 and the whole point was to enjoy L1. What do you mean with patched Netflix libraries? Can you maybe point me in the right direction? That'd be greatly appreciated :)

    This article contains an introduction to the problem. Basically, you either need to patch the APK or find one pre-patched by someone else.

    Most, if not all people use apktool for this kind of work, but later versions of the Netflix APK can't currently be decompiled, so if you look around for a patched APK, you'll necessarily find an old version.
    2
    Version 1.1 has been released with support for devices that have the library under /system/vendor/lib instead.
    2
    I didnt fix my error -9 still getting same error sorry we couldn't get Netflix service error (-9) running on Note 4 with Magisk 16.4 on MM ROM

    *edit* I went into /vendor/lib/ and delete (take a backup of it) the file liboemcrypto.so, reboot and it worked! I dont know if that the right way to fix it? this Module seems like didn't change anything

    Thank you for the report. I will investigate the matter.

    The module should have worked with that path. I have a device myself that has liboemcrypto.so in that location, and the module works fine with it. I'll look into it.