org.owasp.orizon.library
Class Recipe
java.lang.Object
org.owasp.orizon.O
org.owasp.orizon.xml.Reader
org.owasp.orizon.library.Recipe
public class Recipe
- extends Reader
The Owasp Orizon Recipe.
A recipe is an XML file containing security checks. It is stored into a
CookBook and it is named as recipe_n.xml where n is an ordinal number
starting from 1.
- Since:
- 1.0pre1
- Author:
- thesp0nge
- See Also:
Report
Constructor Summary |
Recipe(java.lang.String path,
int index)
Creates a new Recipe where security checks are stored. |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Recipe
public Recipe(java.lang.String path,
int index)
- Creates a new Recipe where security checks are stored.
- Parameters:
path
- the path to the current cookbook (e.g. "library/O_CR_1/")index
- the recipe ordinal number used to build the recipe name
setProperties
public void setProperties(java.util.HashMap<java.lang.String,java.lang.String> p)
getId
public java.lang.String getId()
getName
public java.lang.String getName()
getDescription
public java.lang.String getDescription()
getWeight
public float getWeight()
getChecks
public int getChecks()
read
public boolean read()
- Specified by:
read
in class Reader
getContent
public java.lang.String getContent()
getChecksCount
public int getChecksCount()
review
public boolean review()
getFaultyChecks
public java.util.Vector<Reportable> getFaultyChecks()
getCheck
public Check getCheck(int index)
- Returns the index-th check. Index value must be between 1 and the
recipes number, otherwise nothing has been returned.
- Parameters:
index
- the check ordinal number
- Returns:
- a check or null if index is out of bound or recipe has
not been read.
disable
public void disable()
enable
public void enable()
load
public void load(Source s)