Skip to content
Jjk422 edited this page Jul 28, 2016 · 15 revisions

# SecGen schemas

SecGen currently has 5 schemas:

I - base_metadata_schema.xsd II - network_metadata_schema.xsd III - scenario_schema.xsd IV - service_metadata_schema.xsd V – vulnerability_metadata_schema.xsd

Where are the schemas found?

All schemas can be found under the directory SecGen/lib/schemas/.

What do the schemas actually do?

Each schema ensures all secgen_metadata.xml files and scenario files have a valid structure with valid values.

The base_metadata_schema.xsd schema controls the base tag. The options for the base tag are

Tag Attributes values {Required values}

name any author any module_licence MIT , Apache v2 , GPLv3 description any type server , desktop , cli platform any distro any url any {Optional values} reference any software_name any software_licence any {} conflict module_path = any name = any author = any module_licence = any description = any type = any platform = any distro = any url = any vagrantbase = any reference = any software_licence = any { } requires module_path = any name = any author = any module_licence = any description = any type = any platform = any distro = any url = any vagrantbase = any reference = any software_licence = any

In other words

Bases Minimal secgen_metadata.xml

“String” “String” MIT // Apache v2 // GPLv3 “String” server // desktop // cli “String” “String” “String”

Maximum secgen_metadata.xml

“String” “String” MIT // Apache v2 // GPLv3 “String” server // desktop // cli “String” “String” “String” “String” “String” “String” "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String" "String"

Minimal network secgen_metadata.xml module

<module_license>MIT // Apache v2 // GPLv3</module_license> public_network // private_network ... where * is 0-9

Maximum network secgen_metadata.xml module

<module_license>MIT // Apache v2 // GPLv3</module_license> public_network // private_network ... where * is 0-9 <module_license></module_licence>

Services secgen_metadata.xml

”” ”” <module_license>MIT // Apache v2</module_license> ”” ”” linux // unix // windows

”” <software_name>””</software_name> <software_license>””</software_license>

<software_name>””</software_name> <module_path>””</module_path> ”” ”” <module_license>””</module_license> ”” ”” linux // unix // windows ”” <software_name>””</software_name> <software_license>””</software_licence>

”” ”” ”” ”” ”” ”” linux // unix // windows ”” ”” ””

Vulnerability secgen_metadata.xml

”” ”” <module_license>MIT // Apache v2</module_license> ”” ”” information_leakage // user // root ←Todo - need to add information leakage to privilege remote // local linux // unix // windows

low // medium // high CVE-[0-9]{4}-[0-9]{1,39} <cvss_base_score>. where * is 0-9</cvss_base_score> <cvss_vector>AV:(L|A|N)/AC:(H|M|L)/Au:(M|S|N)/C:(N|P|C)/I:(N|P|C)/A:(N|P|C)</cvss_vector> ”” <software_name>nfsd</software_name> <software_license>GPLv2</software_license>

””

<msf_module>exploit/[a-zA-Z0-9_-/]+</msf_module> ”” ”” <module_path>””</module_path> ”” ”” <module_license>””</module_license> ”” ”” user // root remote // local linux // unix // windows <-- need to add windows to schema low // medium // high CVE-[0-9]{4}-[0-9]{1,39} <cvss_base_score>. where * is 0-9</cvss_base_score> <cvss_vector>AV:(L|A|N)/AC:(H|M|L)/Au:(M|S|N)/C:(N|P|C)/I:(N|P|C)/A:(N|P|C)</cvss_vector> ”” <software_name>””</software_name> <software_license>””</software_license> ”” <msf_module>exploit/[a-zA-Z0-9_-/]+</msf_module> ”” ”" <module_path>””</module_path> ”” ”” <module_license>””</module_license> ”” ”” user // root remote // local linux // unix // windows <-- need to add windows to schema low // medium // high CVE-[0-9]{4}-[0-9]{1,39} <cvss_base_score>. where * is 0-9</cvss_base_score> <cvss_vector>AV:(L|A|N)/AC:(H|M|L)/Au:(M|S|N)/C:(N|P|C)/I:(N|P|C)/A:(N|P|C)</cvss_vector> ”” <software_name>””</software_name> <software_license>””</software_license> ”” <msf_module>exploit/[a-zA-Z0-9_-/]+</msf_module> ”” ”"

Clone this wiki locally