How can you run Javascript using Rhino for Java in a sandbox?
Part of our java application needs to run javascript that is written by non-developers. These non-developers are using javascript for data formatting. (Simple logic and string concatenation mostly). My question is how can I setup the execution of these scripts to make sure scripting errors don't have a major negative impact on the rest of the application. Need to guard against infinite loops Guard against spawning new threads. Limit access to services and environment File system (Example: If a disgruntled script writer decided to delete files) Database (Same thing delete database records)