The scripted plugin

This plugin is intended to give users the ability to create test scripts, using the facilities of Webscarab.

The scripting support is provided by the Bean Scripting Framework (BSF), which means that any BSF-supported scripting language can be used to write test scripts. The default language supported is BeanShell, which is a relaxed Java-like language. For more details of BeanShell, go to http://www.beanshell.org/. If you wish to use one of the other scripting languages such as Jython or Groovy, for example, you should place the appropriate support libraries in the ClassPath prior to running WebScarab, and make sure that your script's filenames end with the appropriate extension for your chosen language. The required extension for BeanShell scripts is ".bsh".

The Scripted plugin exports a Java Object with methods that allow you to interact with the rest of WebScarab, for example, fetching a response, or adding a conversation to the WebScarab framework for analysis by the other plugins. It is likely that this object will change, as it is a pretty new feature of WebScarab. Therefore, if the documented behaviour does not match what you observe, please check the source code!

The exported Object is documented in org/owasp/webscarab/plugins/scripted/ScriptedObjectModel.java The major methods that you will likely want to use are:

The "async" methods allow for fetching of Responses in multiple threads, while the "fetchResponse" method would be used for single-threaded operations.