nvllsvm / emby-unlocked

Emby with the premium Emby Premiere features unlocked.
GNU General Public License v2.0
271 stars 61 forks source link

Installing #30

Closed NerdPotato closed 6 years ago

NerdPotato commented 6 years ago

Very little documentation is provided in order for any users to install this.

I've managed to find where connectionmanager.js is located, however, I haven't found any hint on where I would be able to find where to patch PluginSecurityManager.

I would appreciate any help on how to install this, and would like documentation on how to do any of this.

I really appreciate your work, and I hope you keep doing exactly what you're doing.

flexy123 commented 6 years ago

I "installed" this a few days ago here on my Win machine, that is I am recompiling it with Visual Studio 2017. The patch itself is "simple", I hand-patched this since the patch shows clearly what to add and what to strip from the original...so it's not too complex. (I didn't find a properly working "patch" utility for Windows and was too lazy to install MingGW or whatever just for this measly patch).

As for connectionmanager.js, there are several instances of if in the Emby archive (6 or so, they're all identical). It's also relatively straight-forward since you only have to replace these with the changed one.

While I personally think that "patch" is not too difficult to do by hand, I admit it DOES require some expertise...afterall I am recompiling this with Visual Studio and not everyone might be familiar with it.

So or so...the Pluginsecuritymanager.cs is ALSO part of the official Emby distribution, in the folder Emby.Sever.Implementation.Security and MediaBrowser.Model.Entities. And since this is a .CS (c sharp) source file you will have to recompile emby. (Get Visual Studio 2017, download emby distribution from Github, apply these patches, and then "build" using Visual Studio).

NerdPotato commented 6 years ago

Where can the connectionmanager.js be found in the emby repo?

flexy123 commented 6 years ago

Get the (free) tool "Agentransack", it's one of the essentials I am using on all of my PCs. (I am also using this often when I code). Right click repo folder (or start Agentransack directly) and specify "subfolders" to search as well. Search for file location. It shows where it is. It is 5-6x in the repo. AgentRansack also allows searching for contents within files.

flexy123 commented 6 years ago

D:\Repos\Emby\MediaBrowser.WebDashboard\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js

(after compiling, the identical file also gets copied to the bin folders) D:\Repos\Emby\MediaBrowser.WebDashboard\bin\x64\Release\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js D:\Repos\Emby\MediaBrowser.Tests\bin\x64\Release\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js D:\Repos\Emby\MediaBrowser.ServerApplication\bin\x64\Release\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js D:\Repos\Emby\MediaBrowser.Server.Mono\bin\x64\Release\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js D:\Repos\Emby\Emby.Server.Implementations\bin\x64\Release\dashboard-ui\bower_components\emby-apiclient\connectionmanager.js

Add: Some plugins and especially Emby Theater download these components live off the web and cache them in a coded format, they cannot be edited otherwise it redownloads. "Hacking" Emby Theater would be relatively complex, it would have to be rewritten a bit so it doesn't use these online files. But there is an Emby Theater App Version for Window which uses these local files, including Connectionmanager.js, but this version of Emby Theater is only for phones etc. and doesn't use madvr.

And then editing local Connectionmanager.js to remove these checks like shown in the patch.

konstantinblaesi commented 6 years ago

This repository is used to build a docker image. You are not supposed to use the source unless you insist on

As an enduser you use the docker container, see

I agree though that it's not super obvious for those less familiar with concepts like docker. Maybe @nvllsvm could add a link to the docker instructions on the main README.md?

nvllsvm commented 6 years ago

Build instructions for Alpine Linux can be found here https://github.com/nvllsvm/emby-unlocked/blob/master/docker/build.sh

For anything else, you're on your own.