import sys
from sandbox import Sandbox, SandboxConfig

if __name__ == "__main__":
	'''
	Will run a given code in sandbox (stream stdio from cmd)
	arg[1] = code given
	to run
	python run_python_secure.py <code>  < inputfile 
	'''
	if len(sys.argv) != 2:
		print "Not enough args"
		sys.exit()
	args = sys.argv
	code = args[1]
	print "Will run: ", code
	try:
		sandbox = Sandbox(SandboxConfig('stdin', 'stdout'))
		sandbox.io(sys.stdin, sys.stdout)
		sandbox.execute(code)
	except Exception, e:
		print e
@@ -408,44 +408,8 @@
 '))%0A
-%09%09sandbox.io(sys.stdin, sys.stdout)%0A
 %09%09sa

Secure should work