ngovil21 / RequestChannel.bundle

Request Channel - A Plex Channel to create requests
158 stars 22 forks source link

Restrict ability to clear requests (enhancement) #14

Closed guru69 closed 8 years ago

guru69 commented 8 years ago

It might be good idea to restrict the "Clear Requests" to only the Plex Server login so users aren't able to flush other users requests.

ngovil21 commented 8 years ago

This should be the case already. Currently only the admin user is allowed to clear or delete requests. Home and Shared Users shouldn't have acess to that menu.

guru69 commented 8 years ago

I have a test plex account that I use over a VPN line to see what other users see and it still appears under "View Requests". I haven't chosen Yes to clear (didn't want to lose my requests) but I assume it will clear it. I'm on the development version.

ngovil21 commented 8 years ago

Do you use Plex Home? I think my admin check might not work with users who don't use Plex Home. Does the Manage Channel item show up in the Main Menu on the 'user' account?

I will look into alternative checks.

On Fri, Feb 19, 2016, 9:36 AM guru69 notifications@github.com wrote:

I have a test plex account that I use over a VPN line to see what other users see and it still appears there. I haven't chosen Yes to clear (didn't want to lose my requests) but I assume it will clear it. I'm on the development version.

— Reply to this email directly or view it on GitHub https://github.com/ngovil21/PlexRequestChannel.bundle/issues/14#issuecomment-186262704 .

ngovil21 commented 8 years ago

@guru69 I've made a pretty big update to the channel in the development branch, using a class object with dynamically generated routes to create a session each time the channel is accessed. It seems mostly stable to me, but there may be some new bugs.

The channel will now check for the admin account against plex.tv, rather than the local machine. Hopefully this works better for you.

guru69 commented 8 years ago

@ngovil21 No, I don't use Plex Home at all, Just the "Friends" section. Will this admin acct change affect things when plex is accessed by users directly by IP? (as opposed to through plex.tv) or if plex.tv is blocked? I'll grab your latest development and try it

ngovil21 commented 8 years ago

It won't affect users who login in directly, but it won't work if plex.tv is blocked by the server. If plex.tv is blocked, then no user will be detected as admin. If that's the case, then this fix will be worse for you because you won't have any option to administer the channel.

The reason plex.tv would be necessary is that without Plex Home, all connections to the Plex Server from localhost are authenticated regardless of token. The Channel operates from the Plex Server and is authenticated.

I don't have a better way of identifying the admin user currently.

guru69 commented 8 years ago

@ngovil21 I loaded your latest dev onto a new test Plex server I setup last night (headless Ubuntu server) and all is working as expected. My outside test user is no longer able to clear requests and my lan connected admin can. In settings, what are the Couch potato Profile and Category names used for? I didn't see any reference within Couch to these.

ngovil21 commented 8 years ago

Good to hear. There's going to be an option to chose to authenticate locally or using plex.tv in the next update, so you will need to set it.

The Profile is the quality profile you want to use. It's determines the ranking of qualities. The Category is used to require or restrict certain terms in searches and can also be used to determine where files are downloaded to. Both of these settings are optional. You'll need to refer to the CouchPotato documentation if you need more information.