Hi,
Is there a way to catch the contents of the PHP session variable $_SESSION['user_id']
with a mod_wsgi
Python script? I'm running a script in the background that will decide whether or not the user may proceed to view the document.
I would like to do something like this:
def allow_access(environ, host):
allow_access = False
if environ['SCRIPT_NAME'] == 'forbidden_dir':
if session['user_id'] == '1':
allow_access = True
if allow_access:
return True
else:
return False
Is it possible?