org.owasp.orizon.tools.osh
Class Osh

java.lang.Object
  extended by org.owasp.orizon.core.Trackable
      extended by org.owasp.orizon.core.Engine
          extended by org.owasp.orizon.tools.osh.Osh

public class Osh
extends Engine

This is the Owasp Orizon SHell main class. OSH aims to give code reviewer a direct way to interact with the reviewing engine. It will work in a very different way than the GUI version. Using the GUI, a code reviewer will follow the workflow Orizon brings with it. With the shell, the experienced reviewer is completely free to ask services in whatever order he/she wants to.

Since:
1.1
Author:
thesp0nge

Field Summary
 
Fields inherited from class org.owasp.orizon.core.Engine
engineCantTrace, engineMissingTraceName, engineStartErrno, errno, errstr, faults, has_faults, has_output, initialized, inputName, O_E_DELIVER, O_E_ERROR, O_E_IDLE, O_E_PAUSED, O_E_READY, O_E_RUNNING, O_E_STOPPED, ps1, reader, rules, s, silence, status, t0, t1, time
 
Fields inherited from class org.owasp.orizon.core.Trackable
trace, traceName
 
Constructor Summary
Osh()
           
 
Method Summary
 boolean exec(java.lang.String command)
          Engine specific execute command routine.
 void flushOutput()
           
 java.lang.String getOutput()
           
 Folder getRawScanResults()
           
 boolean init()
          Initialize the engine.
static void main(java.lang.String[] args)
           
 boolean pause()
          Pause the engine.
protected  boolean process(java.lang.Object n)
          Engine specific freecc tree generated root node management routine.
 boolean shell()
          Engine specific interactive shell.
 boolean start()
          Start the engine.
 boolean stop()
          Stop the engine.
 
Methods inherited from class org.owasp.orizon.core.Engine
addFault, canOutput, canPause, canRun, canStop, debug, errorString, exitOnFailure, feed, getAppName, getElapsedStatement, getErrno, getFaults, getProperties, getScanMills, getStats, getTimer, hasFaults, hasOutput, isPaused, isRunning, isStopped, isTestMode, isTurnedOn, pauseTimer, reset, resetTimer, setAppName, setErrorString, setProperties, setReader, setStats, setTestMode, startTimer, stopTimer
 
Methods inherited from class org.owasp.orizon.core.Trackable
getTraceName, isTrace, setTrace, setTraceName, trace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Osh

public Osh()
Method Detail

main

public static void main(java.lang.String[] args)
Parameters:
args -

init

public boolean init()
Description copied from class: Engine
Initialize the engine. The initialization status must be stored in the initialized variable.

Specified by:
init in class Engine
Returns:
true if the engine can be initialized, or false otherwise.

pause

public boolean pause()
Description copied from class: Engine
Pause the engine.

Specified by:
pause in class Engine
Returns:
true if the engine can be paused, or false otherwise.

shell

public boolean shell()
Description copied from class: Engine
Engine specific interactive shell. OSH will permit users to interact with Orizon engines direct issuing them commands. For such a reason an interactive shell needs to be spawned.

Specified by:
shell in class Engine
Returns:
true if the shell can be spawned, or false otherwise.

start

public boolean start()
Description copied from class: Engine
Start the engine. Each engine will implement in this method its task.

Specified by:
start in class Engine
Returns:
true if the engine started and performed its task, or false otherwise

stop

public boolean stop()
Description copied from class: Engine
Stop the engine. Freeze engine's activities preparing it to release results.

Specified by:
stop in class Engine
Returns:
true if the engine can be stopped, or false otherwise

exec

public boolean exec(java.lang.String command)
Description copied from class: Engine
Engine specific execute command routine. Each engine has to be able to receive commands from the outside (the shell o the SkyLine object), process them and giving back a result. This method will executes a command.

Specified by:
exec in class Engine
Parameters:
command - the command to execute
Returns:
true if the command has been executed, or false otherwise

process

protected boolean process(java.lang.Object n)
Description copied from class: Engine
Engine specific freecc tree generated root node management routine. This method will be called in exec() or shell() method giving the root node from the tree generated by each engine parser.

Specified by:
process in class Engine
Parameters:
n - the root node
Returns:
true or false if the caller routine has to exit upon return.

getOutput

public java.lang.String getOutput()

flushOutput

public void flushOutput()

getRawScanResults

public Folder getRawScanResults()