Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Reverted from v. 13

Table of Contents

*(Under Review for V2)

Introduction

Introduction

As at 1.12.8 we have removed the old functionality of "Create a Windows Audit Script" and replaced it with the Scripts endpoint. You can now You can create a script with all the options for any of the existing audit scripts - not just Windows. AIX, ESX, Linux, OSX and Windows are all covered.

...

We initially setup the default list of scripts with the default options. The list of script is viewable at /scripts. These default scripts cannot be deleted. You can create additional scripts for use by you as required. Your script will be based on one of the existing scripts and have custom options applied. The scripts can then be downloaded from the list page at menu : Discover -> Admin -> Audit Scripts -> List Audit Scripts.

Creating a Script

To make another script use the menu and go to menu : Discover -> Admin -> Audit Scripts -> Create Audit Scripts> Create Script. Provide a name and optionally a description. Choose a type of script to base your custom script upon. Once you do this, the Options section will populate with the available configurable options. At present Windows and Linux scripts will have the "files" details injected. See details about files here - Files.

...

URL - If you leave the URL option as set, Open-AudIT will inject the config value for default_network_address into the URL option. With the default scripts, if left as set, Open-AudIT will inject the default network address when the script is downloaded.

 

Image RemovedImage Added
.
Image Removed

Viewing Script Details

Go to menu : Discover -> Admin -> Audit Scripts -> List Audit Scripts.

Image Added

You will see a list of available scripts. You can view a script by clicking on the

...

it's ID (in green). You can also download, edit or delete

...

the script (if delete is permitted).

Image Added

 

Image Removed

Database Schema
 

Code Block
themeEclipse
languagetext
Create Table: CREATE TABLE `scripts` (
  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(200) NOT NULL DEFAULT '',
  `org_id` int(10) unsigned NOT NULL DEFAULT '1',
  `options` text NOT NULL,
  `description` text NOT NULL,
  `based_on` varchar(200) NOT NULL DEFAULT '',
  `hash` varchar(250) NOT NULL DEFAULT '',
  `edited_by` varchar(200) NOT NULL DEFAULT '',
  `edited_date` datetime NOT NULL DEFAULT '2000-01-01 00:00:00',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8;

...

Scripts are stored in the database in the "scripts" table. A typical entry will look as below.

...

themeEclipse
languagetext

...

. The "hash" column is not used at present.

         id: 12
       name: my_audit_aix.sh

...

    

...

options: {"create_file":"n","debugging":"1","org_id

...

":"","submit_online":"y","

...

system_

...

id":"

...

","url":"http:\/\/

...

192.168.88.240\/open-audit\/index.php\/

...

system\/

...

add_system"}
description: 
   based_on: audit_aix.sh

...

     

...

  hash:

...

 
  edited_by: 

...

Administrator
edited_date: 

...

2016-

...

08-

...

04 

...

10:

...

40:

...

36

 

API / Web Access?

You can access the /scripts collection using the normal Open-AudIT JSON based API. Just like any other collection. Please see the API documentation for further details.

...