Lock for Plex Google Chrome App

First Off I love how this is shaping up but I can not get this to work.

I'm running on an Ubuntu server and have installed the plugin using the default directories.  However I can not get it to work. I first tried running the bash file from the command line but was getting an error related to sqlite.  I was able to get around this by changing the bash from 

./sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "$l0ckplex" 

 to just 

sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "$l0ckplex" 

but was then getting a permissions error but by adding write permissions to the db I could then run the script files from the command line.

sudo chmod a+w /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db

So now the lock and un lock work when manually run from the command line however they do not work from the interfaces,

Here is an excerpt from my log file.

2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (core:519) - Attribute 'platformVersion' set to ' (#57-Ubuntu SMP Tue Jul 15 03:51:08 UTC 2014)'
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======Platform: Linux Version:  (#57-Ubuntu SMP Tue Jul 15 03:51:08 UTC 2014)
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======PMS Server: 0.9.11.1.678-c48ffd2
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======Plex Media Server at /var/lib/plexmediaserver/Library/Application Support/Plex Media Server
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======Plug-in bundles are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======Plug-in support files are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support
2014-11-01 23:46:53,734 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======L0ck Bundle path is /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle
2014-11-01 23:46:53,735 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======BASEPATHL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/l0ck.sh
2014-11-01 23:46:53,735 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======BASEPATHUNL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/unl0ck.sh
2014-11-01 23:46:53,735 (7f372e894740) :  DEBUG (__init__:91) - ======L0CK======L0ck plugin generated on: 1st NOV 2014
 

Looking for possible solutions to get this working in the clients.

Hello, i use Debian Wheezy.

https://twitter.com/lockforplex/status/663283582832480256

https://twitter.com/lockforplex/status/663283582832480256

hi, i have now install plex via wget. plex is now installed in \var\lib\

but also here, the l0ck will not work.

if i try to run the code in the l0ck.sh, i get this here:

login as: root
root@192.168.1.18's password:
Linux debian 3.16-0.bpo.2-amd64 #1 SMP Debian 3.16.3-2~bpo70+1 (2014-09-21) x86_64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sun Nov  2 15:01:24 2014 from buero.fritz.box
root@debian:~# l0ckplex=“UPDATE metadata_items SET metadata_type=20 WHERE library_section_id=1 and metadata_type=1; DELETE FROM library_sections WHERE id=1;”
root@debian:~# cd /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/
root@debian:/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support# ./sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db “$l0ckplex”
-bash: ./sqlite3: Datei oder Verzeichnis nicht gefunden
root@debian:/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support#

Datei oder Verzeichnis nicht gefunden -> File or directory not found

Libary Home Videos isnt lock.

https://twitter.com/lockforplex/status/663283582832480256

i had read your FAQ, but i dont know what i do  wrong :(

perhaps you can help, and give me the right code.

here my path

/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support

https://twitter.com/lockforplex/status/663283582832480256

ok, next screens in english.... ;)

var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support

lock.sh

#!/bin/bash

l0ckplex=“UPDATE metadata_items SET metadata_type=20 WHERE library_section_id=1 and metadata_type=1; DELETE FROM library_sections WHERE id=1;”

cd /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/

./sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db “$l0ckplex”

exit;

unlock.sh

#!/bin/bash

unl0ckplex=“UPDATE metadata_items SET metadata_type=1 WHERE library_section_id=1 and metadata_type=20; INSERT OR REPLACE INTO library_sections (id,name,section_type,language,agent,scanner,created_at,updated_at,scanned_at,user_fields,uuid) VALUES (1,‘Home Videos’,1,‘xn’,‘com.plexapp.agents.none’,‘Plex Video Files Scanner’,‘2014-11-03 14:12:26’,‘2014-11-03 14:12:26’,‘2014-11-03 14:12:26’,‘pr%3AincludeInGlobal=0’,‘1d67ecc8-a1db-4ff3-bc94-20f9765ed32c’);”

cd /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/

./sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db “$unl0ckplex”

exit;

https://twitter.com/lockforplex/status/663283582832480256

here the init.py

import os
PREFIX = "/video/l0ck" 
PASSWORD = "012345"
BASEPATHL0CK = (Core.storage.join_path(Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name), 'L0ck.bundle')+'/Contents/Resources/l0ck_support/l0ck.sh')
BASEPATHUNL0CK = (Core.storage.join_path(Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name), 'L0ck.bundle')+'/Contents/Resources/l0ck_support/unl0ck.sh')
GENERATE_DATE = "2nd NOV 2014"
DEV_MODE = False
NAME = 'L0ck'
ART  = 'art-default.jpg'
ICON = 'icon-default.png'
L0CK_ICON = 'L0ck.png'
UNL0CK_ICON = 'unL0ck.png'
SUCCESS_ICON = 'success.png'
ERROR_ICON = 'error.png'
UPDATES_ICON = 'updates.png'

def Start():
HTTP.CacheTime = 0
ObjectContainer.art = R(ART)
DirectoryObject.thumb = R(ICON)
Plugin.AddViewGroup(“Details”, viewMode=“InfoList”, mediaType=“items”)
Plugin.AddViewGroup(“List”, viewMode=“List”, mediaType=“items”)
ObjectContainer.view_group = ‘Details’
Logger(‘Platform: ’ + Platform.OS +’ Version: '+Platform.OSVersion, force=True)
Logger('PMS Server: ’ + Platform.ServerVersion, force=True)
Logger('Plex Media Server at ’ + Core.app_support_path, force=True)
Logger('Plug-in bundles are located in ’ + Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name), force=True)
Logger('Plug-in support files are located in ’ + Core.storage.join_path(Core.app_support_path, Core.config.plugin_support_dir_name), force=True)
Logger('L0ck Bundle path is ’ + Core.storage.join_path(Core.storage.join_path(Core.app_support_path, Core.config.bundles_dir_name), ‘L0ck.bundle’), force=True)
Logger('BASEPATHL0CK: ’ + BASEPATHL0CK, force=True)
Logger('BASEPATHUNL0CK: ’ + BASEPATHUNL0CK, force=True)
Logger('L0ck plugin generated on: ’ + GENERATE_DATE, force=True)

@handler(PREFIX, NAME, ICON, ART)
@route(PREFIX + ‘/mainmenu’)
def MainMenu():
oc = ObjectContainer(no_cache=True)
oc.add(DirectoryObject(key=Callback(L0ck, path=BASEPATHL0CK, task=‘L0cked’, query=""), title=“L0ck”, thumb=R(L0CK_ICON)))
oc.add(InputDirectoryObject(key=Callback(L0ck, path=BASEPATHUNL0CK, task=‘UnL0cked’), title=“UnL0ck”, thumb=R(UNL0CK_ICON), prompt=“Enter your password”))
oc.add(DirectoryObject(key=Callback(Updates), title=“Update Feed”, thumb=R(UPDATES_ICON)))
return oc

@route(PREFIX + ‘/Updates’)
def Updates():
oc = ObjectContainer(title2=‘You generated the L0ck plugin on [’+ GENERATE_DATE +’]’, view_group=‘List’, no_cache=True)
updatedata = ‘’
updatedate = ‘’
xml = RSS.FeedFromURL(‘https://raw.githubusercontent.com/ish0w/L0ck-for-plex-media-server/gh-pages/xml/updates.xml’)
for item in xml.entries:
updatedata = item.description
updatedate = item.title
Logger(updatedate, force=True)
Logger(updatedata, force=True)
oc.add(DirectoryObject(key=Callback(MainMenu),title=’[’ + updatedate +’] - ’ + updatedata))

	if len(oc) < 1:
		Logger('Something went wrong while pulling xml', force=True)
		return oc.add(DirectoryObject(key=Callback(MainMenu),title='Pl. ensure your connected to the internet and try again!')) 
	else:
		return oc

@route(PREFIX + ‘/L0ck’)
def L0ck(query, path, task):
oc = ObjectContainer(title2=“L0ck”, no_cache=True)
if task == ‘UnL0cked’:
if query == PASSWORD:
Logger(‘Password correct about to launch unL0ck’, force=True)
filepath = path.replace(’ ', '\ ')
os.system(‘sh ’ + filepath)
Logger(‘Launched unL0ck’, force=True)
oc.add(PopupDirectoryObject(key=Callback(MainMenu), title=“UnL0cked”, duration=3, summary=“Section(s) successfully UnL0cked!”, thumb=R(SUCCESS_ICON)))
return oc
else:
Logger(‘Password Incorrect, someone is trying to get in!’, force=True)
oc.add(PopupDirectoryObject(key=Callback(MainMenu), title=“Incorrect Password”, duration=3, summary=“Try Again!”, thumb=R(ERROR_ICON)))
return oc
elif task == ‘L0cked’:
Logger(‘L0cking’, force=True)
filepath = path.replace(’ ', '\ ')
os.system('sh ’ + filepath)
Logger(‘L0cked’, force=True)
oc.add(PopupDirectoryObject(key=Callback(MainMenu), title=“L0cked”, duration=3, summary=“Section(s) successfuly L0cked!”, thumb=R(SUCCESS_ICON)))
return oc

@route(PREFIX + ‘/logger’)
def Logger(message, force=False):
if DEV_MODE:
force = True
if force:
Log.Debug(’======L0CK======’+message)
else:
pass

https://twitter.com/lockforplex/status/663283582832480256

thx, i try all, but the plugin will not lock the "home movie" folder.

root@debian:/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support# ./l0ck.sh
./l0ck.sh: row 7: ./sqlite3: file or folder not found

here the log file, perhaps this help

2014-11-02 15:18:53,201 (7fa4444c9700) :  INFO (core:347) - Starting framework core - Version: 2.5.0, Build: a51033b (Mon Jul 28 12:19:14 UTC 2014)
2014-11-02 15:18:53,201 (7fa4444c9700) :  DEBUG (core:359) - Using the elevated policy
2014-11-02 15:18:53,202 (7fa4444c9700) :  DEBUG (core:448) - Starting runtime component.
2014-11-02 15:18:53,203 (7fa4444c9700) :  DEBUG (core:448) - Starting caching component.
2014-11-02 15:18:53,203 (7fa4444c9700) :  DEBUG (core:448) - Starting data component.
2014-11-02 15:18:53,203 (7fa4444c9700) :  DEBUG (core:448) - Starting networking component.
2014-11-02 15:18:53,203 (7fa4444c9700) :  DEBUG (networking:288) - Loaded HTTP cookies
2014-11-02 15:18:53,204 (7fa4444c9700) :  DEBUG (networking:458) - Setting the default network timeout to 20.0
2014-11-02 15:18:53,204 (7fa4444c9700) :  DEBUG (core:448) - Starting localization component.
2014-11-02 15:18:53,204 (7fa4444c9700) :  INFO (localization:408) - Setting the default locale to en-us
2014-11-02 15:18:53,204 (7fa4444c9700) :  DEBUG (core:448) - Starting messaging component.
2014-11-02 15:18:53,205 (7fa43902d700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/system/messaging/clear_events/com.plexapp.plugins.l0ckunl0ck'
2014-11-02 15:18:53,205 (7fa4444c9700) :  DEBUG (core:448) - Starting debugging component.
2014-11-02 15:18:53,206 (7fa4444c9700) :  DEBUG (core:448) - Starting services component.
2014-11-02 15:18:53,206 (7fa4444c9700) :  DEBUG (core:448) - Starting myplex component.
2014-11-02 15:18:53,206 (7fa4444c9700) :  DEBUG (core:448) - Starting notifications component.
2014-11-02 15:18:53,309 (7fa4444c9700) :  DEBUG (accessor:68) - Creating a new model access point for provider com.plexapp.plugins.l0ckunl0ck in namespace 'metadata'
2014-11-02 15:18:53,312 (7fa4444c9700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/resourceHashes'
2014-11-02 15:18:53,324 (7fa43902d700) :  DEBUG (services:265) - Plug-in is not daemonized - loading services from system
2014-11-02 15:18:53,324 (7fa4444c9700) :  DEBUG (runtime:1111) - Created a thread named 'load_all_services'
2014-11-02 15:18:53,326 (7fa43902d700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X0J1bmRsZVNlcnZpY2U6QWxsU2VydmljZXM_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMApyMAo_'
2014-11-02 15:18:53,327 (7fa43802b700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400'
2014-11-02 15:18:53,328 (7fa4444c9700) :  DEBUG (runtime:1111) - Created a thread named 'get_server_info'
2014-11-02 15:18:53,328 (7fa4444c9700) :  DEBUG (core:150) - Finished starting framework core
2014-11-02 15:18:53,328 (7fa4444c9700) :  DEBUG (core:558) - Loading plug-in code
2014-11-02 15:18:53,360 (7fa4444c9700) :  DEBUG (core:564) - Finished loading plug-in code
2014-11-02 15:18:53,361 (7fa4444c9700) :  DEBUG (runtime:640) - Adding a prefix handler for 'L0ck' ('/video/l0ck')
2014-11-02 15:18:53,363 (7fa4444c9700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400'
2014-11-02 15:18:53,365 (7fa43802b700) :  DEBUG (core:536) - Machine identifier is 5de14e0adcefdc1185d317ad0dd7e14b2b2de26b
2014-11-02 15:18:53,366 (7fa43802b700) :  DEBUG (core:537) - Server version is 0.9.11.1.678-c48ffd2
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (core:519) - Attribute 'platformVersion' set to ' (#1 SMP Debian 3.16.3-2~bpo70+1 (2014-09-21))'
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======Platform: Linux Version:  (#1 SMP Debian 3.16.3-2~bpo70+1 (2014-09-21))
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======PMS Server: 0.9.11.1.678-c48ffd2
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======Plex Media Server at /var/lib/plexmediaserver/Library/Application Support/Plex Media Server
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======Plug-in bundles are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins
2014-11-02 15:18:53,367 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======Plug-in support files are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support
2014-11-02 15:18:53,368 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======L0ck Bundle path is /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle
2014-11-02 15:18:53,368 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======BASEPATHL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/l0ck.sh
2014-11-02 15:18:53,368 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======BASEPATHUNL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/unl0ck.sh
2014-11-02 15:18:53,368 (7fa4444c9700) :  DEBUG (__init__:91) - ======L0CK======L0ck plugin generated on: 2nd NOV 2014
2014-11-02 15:18:53,368 (7fa4444c9700) :  INFO (core:609) - Started plug-in
2014-11-02 15:18:53,368 (7fa4444c9700) :  DEBUG (socketinterface:160) - Starting socket server
2014-11-02 15:18:53,371 (7fa4444c9700) :  DEBUG (runtime:1111) - Created a thread named 'start'
2014-11-02 15:18:53,371 (7fa4444c9700) :  INFO (socketinterface:184) - Socket server started on port 48689
2014-11-02 15:18:53,371 (7fa4444c9700) :  INFO (pipeinterface:25) - Entering run loop
2014-11-02 15:18:53,372 (7fa4444c9700) :  DEBUG (runtime:717) - Handling request GET /:/prefixes
2014-11-02 15:18:53,373 (7fa4444c9700) :  DEBUG (runtime:814) - Found route matching /:/prefixes
2014-11-02 15:18:53,439 (7fa43902d700) :  DEBUG (services:362) - Loaded services
2014-11-02 15:18:53,442 (7fa43882c700) :  DEBUG (services:438) - No shared code to load
2014-11-02 15:18:53,443 (7fa4444c9700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 448 bytes
2014-11-02 15:18:53,451 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:18:53,452 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:53,454 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:18:53,456 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:18:53,456 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:18:53,463 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:53,464 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:54,907 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:18:54,909 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:54,910 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:18:54,911 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:18:54,911 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:18:54,920 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:54,920 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:54,935 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 15:18:54,936 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:54,937 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 15:18:54,938 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======L0cking
2014-11-02 15:18:54,941 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======L0cked
2014-11-02 15:18:54,944 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:54,944 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 576 bytes
2014-11-02 15:18:55,700 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:18:55,701 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:55,702 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:18:55,703 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:18:55,704 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:18:55,713 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:55,713 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:55,726 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/mainmenu
2014-11-02 15:18:55,728 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:55,729 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/mainmenu
2014-11-02 15:18:55,731 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:55,731 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:56,595 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:18:56,596 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:56,598 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:18:56,599 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:18:56,599 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:18:56,609 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:56,609 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:56,632 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 15:18:56,633 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:56,634 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 15:18:56,634 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======L0cking
2014-11-02 15:18:56,638 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======L0cked
2014-11-02 15:18:56,641 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:56,641 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 576 bytes
2014-11-02 15:18:59,210 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:18:59,211 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:59,213 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:18:59,213 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:18:59,214 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:18:59,223 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:59,224 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:18:59,245 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Funl0ck.sh&task=UnL0cked&query=1234
2014-11-02 15:18:59,246 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:18:59,248 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 15:18:59,248 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======Password correct about to launch unL0ck
2014-11-02 15:18:59,251 (7fa43882c700) :  DEBUG (__init__:91) - ======L0CK======Launched unL0ck
2014-11-02 15:18:59,253 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:18:59,254 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 581 bytes
2014-11-02 15:19:00,545 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 15:19:00,547 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:19:00,548 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 15:19:00,549 (7fa43882c700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 15:19:00,550 (7fa43882c700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 15:19:00,559 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:19:00,559 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 15:19:00,574 (7fa43882c700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/mainmenu
2014-11-02 15:19:00,575 (7fa43882c700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 15:19:00,576 (7fa43882c700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/mainmenu
2014-11-02 15:19:00,578 (7fa43882c700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 15:19:00,578 (7fa43882c700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes

https://twitter.com/lockforplex/status/663283582832480256

https://twitter.com/lockforplex/status/663283582832480256

sqlite3 /var/lib/plexmediaserver/Library/Application\ Support/Plex\ Media\ Server/Plug-in\ Support/Databases/com.plexapp.plugins.library.db "$l0ckplex"

better, Home Videos is now locked.

sqlite was allready installed.

but i cant open it now ;)

This channel is not responding.

Edit (log)

2014-11-02 20:48:34,676 (7f8f8de2d700) :  INFO (core:347) - Starting framework core - Version: 2.5.0, Build: a51033b (Mon Jul 28 12:19:14 UTC 2014)
2014-11-02 20:48:34,676 (7f8f8de2d700) :  DEBUG (core:359) - Using the elevated policy
2014-11-02 20:48:34,676 (7f8f8de2d700) :  DEBUG (core:448) - Starting runtime component.
2014-11-02 20:48:34,677 (7f8f8de2d700) :  DEBUG (core:448) - Starting caching component.
2014-11-02 20:48:34,677 (7f8f8de2d700) :  DEBUG (core:448) - Starting data component.
2014-11-02 20:48:34,678 (7f8f8de2d700) :  DEBUG (core:448) - Starting networking component.
2014-11-02 20:48:34,678 (7f8f8de2d700) :  DEBUG (networking:288) - Loaded HTTP cookies
2014-11-02 20:48:34,678 (7f8f8de2d700) :  DEBUG (networking:458) - Setting the default network timeout to 20.0
2014-11-02 20:48:34,679 (7f8f8de2d700) :  DEBUG (core:448) - Starting localization component.
2014-11-02 20:48:34,679 (7f8f8de2d700) :  INFO (localization:408) - Setting the default locale to en-us
2014-11-02 20:48:34,679 (7f8f8de2d700) :  DEBUG (core:448) - Starting messaging component.
2014-11-02 20:48:34,679 (7f8f8de2d700) :  DEBUG (core:448) - Starting debugging component.
2014-11-02 20:48:34,679 (7f8f7e7fc700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/system/messaging/clear_events/com.plexapp.plugins.l0ckunl0ck'
2014-11-02 20:48:34,679 (7f8f8de2d700) :  DEBUG (core:448) - Starting services component.
2014-11-02 20:48:34,680 (7f8f8de2d700) :  DEBUG (core:448) - Starting myplex component.
2014-11-02 20:48:34,680 (7f8f8de2d700) :  DEBUG (core:448) - Starting notifications component.
2014-11-02 20:48:34,770 (7f8f8de2d700) :  DEBUG (accessor:68) - Creating a new model access point for provider com.plexapp.plugins.l0ckunl0ck in namespace 'metadata'
2014-11-02 20:48:34,773 (7f8f8de2d700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/resourceHashes'
2014-11-02 20:48:35,212 (7f8f8de2d700) :  DEBUG (runtime:1111) - Created a thread named 'load_all_services'
2014-11-02 20:48:35,213 (7f8f7e7fc700) :  DEBUG (services:265) - Plug-in is not daemonized - loading services from system
2014-11-02 20:48:35,215 (7f8f8de2d700) :  DEBUG (runtime:1111) - Created a thread named 'get_server_info'
2014-11-02 20:48:35,215 (7f8f7d7fa700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400'
2014-11-02 20:48:35,216 (7f8f8de2d700) :  DEBUG (core:150) - Finished starting framework core
2014-11-02 20:48:35,217 (7f8f8de2d700) :  DEBUG (core:558) - Loading plug-in code
2014-11-02 20:48:35,216 (7f8f7e7fc700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X0J1bmRsZVNlcnZpY2U6QWxsU2VydmljZXM_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMApyMAo_'
2014-11-02 20:48:35,266 (7f8f7d7fa700) :  DEBUG (core:536) - Machine identifier is 5de14e0adcefdc1185d317ad0dd7e14b2b2de26b
2014-11-02 20:48:35,266 (7f8f7d7fa700) :  DEBUG (core:537) - Server version is 0.9.11.1.678-c48ffd2
2014-11-02 20:48:35,268 (7f8f8de2d700) :  DEBUG (core:564) - Finished loading plug-in code
2014-11-02 20:48:35,269 (7f8f8de2d700) :  DEBUG (runtime:640) - Adding a prefix handler for 'L0ck' ('/video/l0ck')
2014-11-02 20:48:35,270 (7f8f8de2d700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400'
2014-11-02 20:48:35,273 (7f8f8de2d700) :  DEBUG (core:519) - Attribute 'platformVersion' set to ' (#1 SMP Debian 3.16.3-2~bpo70+1 (2014-09-21))'
2014-11-02 20:48:35,273 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======Platform: Linux Version:  (#1 SMP Debian 3.16.3-2~bpo70+1 (2014-09-21))
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======PMS Server: 0.9.11.1.678-c48ffd2
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======Plex Media Server at /var/lib/plexmediaserver/Library/Application Support/Plex Media Server
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======Plug-in bundles are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======Plug-in support files are located in /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======L0ck Bundle path is /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle
2014-11-02 20:48:35,274 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======BASEPATHL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/l0ck.sh
2014-11-02 20:48:35,275 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======BASEPATHUNL0CK: /var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Resources/l0ck_support/unl0ck.sh
2014-11-02 20:48:35,275 (7f8f8de2d700) :  DEBUG (__init__:91) - ======L0CK======L0ck plugin generated on: 2nd NOV 2014
2014-11-02 20:48:35,275 (7f8f8de2d700) :  INFO (core:609) - Started plug-in
2014-11-02 20:48:35,275 (7f8f8de2d700) :  DEBUG (socketinterface:160) - Starting socket server
2014-11-02 20:48:35,276 (7f8f8de2d700) :  DEBUG (runtime:1111) - Created a thread named 'start'
2014-11-02 20:48:35,276 (7f8f8de2d700) :  INFO (socketinterface:184) - Socket server started on port 56317
2014-11-02 20:48:35,276 (7f8f8de2d700) :  INFO (pipeinterface:25) - Entering run loop
2014-11-02 20:48:35,276 (7f8f8de2d700) :  DEBUG (runtime:717) - Handling request GET /:/prefixes
2014-11-02 20:48:35,279 (7f8f8de2d700) :  DEBUG (runtime:814) - Found route matching /:/prefixes
2014-11-02 20:48:35,385 (7f8f7e7fc700) :  DEBUG (services:362) - Loaded services
2014-11-02 20:48:35,386 (7f8f8de2d700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 448 bytes
2014-11-02 20:48:35,389 (7f8f7dffb700) :  DEBUG (services:438) - No shared code to load
2014-11-02 20:48:41,647 (7f8f7dffb700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:41,648 (7f8f7dffb700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:41,652 (7f8f7dffb700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:41,653 (7f8f7dffb700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:41,654 (7f8f7dffb700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 20:48:41,662 (7f8f7dffb700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:41,663 (7f8f7dffb700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:43,279 (7f8f7dffb700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:43,280 (7f8f7dffb700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:43,281 (7f8f7dffb700) :  DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:43,282 (7f8f7dffb700) :  DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:43,283 (7f8f7dffb700) :  DEBUG (networking:172) - Requesting 'http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_'
2014-11-02 20:48:43,292 (7f8f7dffb700) :  DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:43,292 (7f8f7dffb700) :  DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:43,317 (7f8f7dffb700) :  DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 20:48:43,318 (7f8f7dffb700) :  DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:43,319 (7f8f7dffb700) :  DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:48:43,320 (7f8f7dffb700) :  DEBUG (__init__:91) - ======L0CK======L0cking
2014-11-02 20:48:43,320 (7f8f7dffb700) :  CRITICAL (runtime:883) - Exception (most recent call last):
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py", line 843, in handle_request
    result = f(**d)
  File "/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/__init__.py", line 81, in L0ck
    os.system('sh ' + filepath)
NameError: global name 'filepath' is not defined

2014-11-02 20:48:43,322 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:43,322 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:48:45,418 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:45,419 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:45,421 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:45,422 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:45,422 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:48:45,431 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:45,432 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:48,301 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:48,302 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:48,303 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:48,304 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:48,305 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:48:48,314 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:48,315 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:48,336 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Funl0ck.sh&task=UnL0cked&query=1234
2014-11-02 20:48:48,338 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:48,339 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:48:48,339 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Password correct about to launch unL0ck
2014-11-02 20:48:48,339 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 70, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:48:48,341 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:48,341 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:48:55,358 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:55,360 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:55,361 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:55,362 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:55,362 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:48:55,372 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:55,372 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:56,705 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:56,706 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:56,707 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:56,708 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:56,709 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:48:56,718 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:56,718 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:48:56,743 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 20:48:56,744 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:56,745 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:48:56,746 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======L0cking
2014-11-02 20:48:56,746 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 81, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:48:56,747 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:56,748 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:48:58,455 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:48:58,456 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:48:58,457 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:48:58,458 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:48:58,459 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:48:58,468 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:48:58,468 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:49:00,200 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:49:00,201 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:00,203 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:49:00,203 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:49:00,204 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:49:00,213 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:00,213 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:49:00,245 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 20:49:00,247 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:00,248 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:49:00,248 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======L0cking
2014-11-02 20:49:00,248 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 81, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:49:00,250 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:00,250 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:49:11,306 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:49:11,307 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:11,308 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:49:11,309 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:49:11,310 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:49:11,319 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:11,319 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:49:51,229 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:49:51,231 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:51,232 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:49:51,233 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:49:51,234 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:49:51,243 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:51,243 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:49:52,665 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:49:52,666 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:52,667 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:49:52,668 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:49:52,669 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:49:52,678 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:52,678 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:49:52,711 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 20:49:52,712 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:49:52,713 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:49:52,714 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======L0cking
2014-11-02 20:49:52,714 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 81, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:49:52,715 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:49:52,716 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:50:27,513 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:27,514 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:27,515 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:27,516 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:27,517 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:27,526 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:27,526 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:31,930 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:31,931 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:31,933 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:31,934 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:31,934 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:31,943 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:31,943 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:31,962 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Fl0ck.sh&task=L0cked&query=
2014-11-02 20:50:31,963 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:31,964 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:50:31,964 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======L0cking
2014-11-02 20:50:31,965 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 81, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:50:31,966 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:31,967 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:50:34,998 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:34,999 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:35,001 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:35,002 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:35,003 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:35,011 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:35,012 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:36,346 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:36,348 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:36,349 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:36,350 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:36,350 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:36,360 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:36,360 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:36,380 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/L0ck?path=%2Fvar%2Flib%2Fplexmediaserver%2FLibrary%2FApplication+Support%2FPlex+Media+Server%2FPlug-ins%2FL0ck.bundle%2FContents%2FResources%2Fl0ck_support%2Funl0ck.sh&task=UnL0cked&query=1234
2014-11-02 20:50:36,381 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:36,383 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/L0ck
2014-11-02 20:50:36,383 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Password correct about to launch unL0ck
2014-11-02 20:50:36,383 (7f8f7dffb700) : CRITICAL (runtime:883) - Exception (most recent call last):
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/Framework.bundle/Contents/Resources/Versions/2/Python/Framework/components/runtime.py”, line 843, in handle_request
result = f(**d)
File “/var/lib/plexmediaserver/Library/Application Support/Plex Media Server/Plug-ins/L0ck.bundle/Contents/Code/init.py”, line 70, in L0ck
os.system('sh ’ + filepath)
NameError: global name ‘filepath’ is not defined

2014-11-02 20:50:36,385 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:36,385 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [500] 643 bytes
2014-11-02 20:50:49,005 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:49,006 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:49,008 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:49,009 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:49,009 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:49,018 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:49,018 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:50,292 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck
2014-11-02 20:50:50,293 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:50,294 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck
2014-11-02 20:50:50,295 (7f8f7dffb700) : DEBUG (base:125) - Checking if com.plexapp.plugins.l0ckunl0ck is broken
2014-11-02 20:50:50,296 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘http://127.0.0.1:32400/:/plugins/com.plexapp.system/messaging/function/X1N0b3JlU2VydmljZTpJc0NoYW5uZWxCcm9rZW4_/Y2VyZWFsMQoxCmxpc3QKMApyMAo_/Y2VyZWFsMQoxCmRpY3QKMQpzMzAKY29tLnBsZXhhcHAucGx1Z2lucy5sMGNrdW5sMGNrczEwCmlkZW50aWZpZXJyMAo_
2014-11-02 20:50:50,305 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:50,305 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 1181 bytes
2014-11-02 20:50:50,326 (7f8f7dffb700) : DEBUG (runtime:717) - Handling request GET /video/l0ck/Updates
2014-11-02 20:50:50,328 (7f8f7dffb700) : DEBUG (runtime:49) - Received packed state data (80 bytes)
2014-11-02 20:50:50,329 (7f8f7dffb700) : DEBUG (runtime:814) - Found route matching /video/l0ck/Updates
2014-11-02 20:50:50,330 (7f8f7dffb700) : DEBUG (networking:172) - Requesting ‘https://raw.githubusercontent.com/ish0w/L0ck-for-plex-media-server/gh-pages/xml/updates.xml
2014-11-02 20:50:50,694 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======27th OCT 2014
2014-11-02 20:50:50,694 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Added ‘Update Feed’ to channel, enabling users to check for updates from within the channel itself!
2014-11-02 20:50:50,694 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======26th OCT 2014
2014-11-02 20:50:50,695 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update changing channel icons
2014-11-02 20:50:50,695 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======26th OCT 2014
2014-11-02 20:50:50,695 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Release notes now being displayed via xml file, scope for alternative usage :wink:
2014-11-02 20:50:50,695 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======25th OCT 2014
2014-11-02 20:50:50,695 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Update on installation instructions for linux CentOS users, tested/working!
2014-11-02 20:50:50,696 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======20th OCT 2014
2014-11-02 20:50:50,696 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Update on installation instructions for linux Fedora users, tested/working!
2014-11-02 20:50:50,696 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======19th OCT 2014
2014-11-02 20:50:50,696 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Stopped support for Windows XP, since the latest Plex is supported only on Vista and newer!
2014-11-02 20:50:50,696 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======18th OCT 2014
2014-11-02 20:50:50,697 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update for linux Ubuntu users, will add Fedora and CentOS support later
2014-11-02 20:50:50,697 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======27th SEP 2014
2014-11-02 20:50:50,697 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update, download button now available instead of auto-download of L0ck.zip file
2014-11-02 20:50:50,697 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======17th SEP 2014
2014-11-02 20:50:50,697 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update to fix issues with l0ck of ‘TV Shows’ section(s)
2014-11-02 20:50:50,698 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======16th SEP 2014
2014-11-02 20:50:50,698 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update for linux users, thanks to BlitzTKO’s inputs!
2014-11-02 20:50:50,698 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======14th SEP 2014
2014-11-02 20:50:50,698 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======When Unl0cked sections DO NOT show up in the dashboard anymore(Tested on Mac/Windows7)
2014-11-02 20:50:50,698 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======11th SEP 2014
2014-11-02 20:50:50,699 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Removed ‘Donate’ button from the generator page
2014-11-02 20:50:50,699 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======11th SEP 2014
2014-11-02 20:50:50,699 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Updated some of them tacky icons lol
2014-11-02 20:50:50,699 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======11th SEP 2014
2014-11-02 20:50:50,699 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Added another build of Windows 8 users (Windows 6.3 (Build 9600)), thanks to NaDs for bring this neglected build to my notice
2014-11-02 20:50:50,700 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======11th SEP 2014
2014-11-02 20:50:50,700 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======For Linux users, eliminated the need for an additional .sql files to be created and put in the l0ck_support folder
2014-11-02 20:50:50,700 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======11th SEP 2014
2014-11-02 20:50:50,700 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======For Windows users, eliminated the need for an additional .sql files to be created and put in the l0ck_support folder
2014-11-02 20:50:50,700 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======04nd SEP 2014
2014-11-02 20:50:50,701 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Changed background and icons
2014-11-02 20:50:50,701 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======04nd SEP 2014
2014-11-02 20:50:50,701 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Improved Logger/Logging
2014-11-02 20:50:50,701 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======04nd SEP 2014
2014-11-02 20:50:50,701 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Made the notification of ‘L0cked’ and ‘Unl0cked’ more uniform over all clients
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======04nd SEP 2014
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Changed the way you are notified of an event by using icons/popupdirectoryobject as opposed to an alert(which was not working in some clients)
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======04nd SEP 2014
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Abandoning the auto-lock feature as it seems highly impractical/improbable that PMS will be able to control the OS/itself on all OS’s
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======03nd SEP 2014
2014-11-02 20:50:50,702 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Updated ghastly awful instructions that show up at zip download in the L0ck Plugin Generator page
2014-11-02 20:50:50,703 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======02nd SEP 2014
2014-11-02 20:50:50,703 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Added logging data required to help debug ‘com.plexapp.plugins.lockunlock.log’
2014-11-02 20:50:50,703 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======01st SEP 2014
2014-11-02 20:50:50,703 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======The plugin generator page is now tablet/mobile friendly (responsive layout)
2014-11-02 20:50:50,703 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======31st AUG 2014
2014-11-02 20:50:50,704 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Added the feature of detecting your Plex Media Server OS [Very basic, still needs additional data]
2014-11-02 20:50:50,704 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======31st AUG 2014
2014-11-02 20:50:50,704 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Removed the option that allows a user to select an OS as it is proving to be a lil dangerous
2014-11-02 20:50:50,704 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======28th AUG 2014
2014-11-02 20:50:50,704 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Pushed an update in an attempt to support Linux, need advanced Linux users to test/share feedback
2014-11-02 20:50:50,705 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======26th AUG 2014
2014-11-02 20:50:50,705 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Update on support for OS X 10.7.5 and below [Single ‘Lock.plugin’ file packed with required files]
2014-11-02 20:50:50,705 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======19th AUG 2014
2014-11-02 20:50:50,705 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Added support for Windows 7/8
2014-11-02 20:50:50,705 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======15th AUG 2014
2014-11-02 20:50:50,706 (7f8f7dffb700) : DEBUG (init:91) - ======L0CK======Support for OS X
2014-11-02 20:50:50,708 (7f8f7dffb700) : DEBUG (runtime:106) - Sending packed state data (111 bytes)
2014-11-02 20:50:50,708 (7f8f7dffb700) : DEBUG (runtime:918) - Response: [200] MediaContainer, 7546 bytes

https://twitter.com/lockforplex/status/663283582832480256

OK so the paths are not my problem.  I added some logging to the l0ck.sh file and found the following:

======= LOCK ======
Sun Nov  2 20:20:53 PST 2014
UPDATE metadata_items SET metadata_type=20 WHERE library_section_id=7 and metadata_type=1;
DELETE FROM library_sections WHERE id=7;
UPDATE metadata_items SET metadata_type=20 WHERE library_section_id=12 and metadata_type=1;
DELETE FROM library_sections WHERE id=12;
======= LOCK ======
Sun Nov  2 20:21:31 PST 2014
SQLite header and source version mismatch
2014-08-15 11:46:33 9491ba7d738528f168657adb43a198238abde19e
2013-12-06 14:53:30 27392118af4c38c5203a04b8013e1afdb1cebd0d

The first call was executing the l0ck.sh from the command line and the second from the plug in with in plex..  As you can see when called from within plex I get as "SQLite header and source version mismatch" error but when I call the .sh file directly it works fine.

https://twitter.com/lockforplex/status/663283582832480256

Solved my "SQLite header and source version mismatch" problem with the following:

cd /usr/lib/plexmediaserver/
sudo cp libsqlite3.so.0 libsqlite3.so.0.ori
sudo cp /usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6 libsqlite3.so.0
Everything now working great.
 
 
 
P.S. In the faq I found that I had to do the following in the __init__.py to make it work.
#filepath = path.replace(' ', '\ ')
filepath = '"' + path + '"'
os.system('sh ' + filepath)