Requirements
The individual performing this installation has some Linux experience.
Root level server access.
Pre-requisites are installed as per the RedHat/CentOS or Debian/Ubuntu guides.
NOTE - This guide is for a new install of Open-AudIT. If you wish to upgrade an existing installation, see the upgrade Linux - Upgrading (old pre v1.3.1) guide.
You should be able to determine the IP Address of your Open-AudIT server via the following command:
...
This will be required later, so make a note of it now.
Install Steps
All local commands should be run as root.
...
The file will now likely be in the users home directory.
Change into the /usr/local directory.
Code Block | ||
---|---|---|
| ||
cd /usr/local |
Untar the file.
Code Block | ||
---|---|---|
| ||
tar xvf ~/OAE-Linux-x86_64-1.0.5.tar.gz |
Fix the file ownership and permissions.
Code Block | ||
---|---|---|
| ||
cd /usr/local chown -R root:root omk chmod -R 700 /usr/local/omk chmod -R 755 omk/log find /usr/local/omk/log chmod -R 770open-audit -type f -print0 | xargs -0 chmod 664 find /usr/local/open-audit -type chmodd -print0 | xargs -R0 777 /usr/local/open-audit/code_igniter/application/views/lang/chmod 755 chmod 770 /usr/local/open-audit/other/audit_linux*.sh chmod 770666 /usr/local/open-audit/other/open-audit_subnet.shlog chmod -R chmod 660777 /usr/local/open-audit/other/open-audit.log code_igniter/application/uploads |
Change permissions
Section | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Install the Daemon
Copy the daemon startup script.
Code Block | ||
---|---|---|
| ||
cp /usr/local/omk/install/omkd.init.d /etc/init.d/omkd |
Edit the start up script
Section | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Add the daemon
Section | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Copy the config files.
Code Block | ||
---|---|---|
| ||
cpcd /usr/local/omk/install/ cp users.dat /usr/local/omk/conf/ cp /usr/local/omk/install/oae_reports.json /usr/local/omk/conf/ cp /usr/local/omk/install/opCommon.nmis /usr/local/omk/conf/ cp /usr/local/omk/install/opModules.nmis /usr/local/omk/conf/../conf |
Edit the config files.
Make sure you set both oae_server and oae_link. They will likely be the same address.Set Set omkd_require_nmis
to 'false' if you do not have NMIS installed on this server.
Code Block | ||
---|---|---|
| ||
nano /usr/local/omk/conf/opCommon.nmis |
OAE_SERVER variable - Edit the "openauditenterprise" section and By default this should be "http://127.0.0.1/open-audit/". You should not need to change this. If you do, insert the ip address of the server (127.0.0.1 or localhost are also fine) in to the oae_server variable (along with http:// and don't forget the trailing /). If you have Open-AudIT installed into a sub directory in your web root, be sure to add that to the end of the oae_server variable above. On On the Opmantek virtual appliance (for example) it would be http://<SERVER_IP>/open-audit/
OAE_LINK variable - Edit the "openauditenterprise" section and insert the actual ip address of the server (127.0.0.1 or localhost are NOT fine) in to the oae_link variable (along with http:// and don't forget the trailing /)By default this should be "/open-audit/". You should not need to change this. If you have Open-AudIT installed into a sub directory in your web root, be sure to add that to the end of the oae_link variable above. On On the Opmantek virtual appliance (for example) it would be http://<SERVER_IP>"/open-audit/" NOTE - If your Open-AudIT Enterprise and Open-AudIT installations are on the same machine, the oae_link variable can should be set to only the directory of Open-AudIT. IE - if you have an Open-AudIT install in the root of your web directory, you can set the variable to "/". On the Opmantek virtual appliance it would be set to "/open-audit/".
Optional - change and note the oae_username and oae_password values. These are changed in opCommon.nmis and the Open-AudIT web GUI. They must be changed in both locations.
If you have other Opmantek software installed (NMIS, opMaps, etc) you can also edit the module_configs -> module_host variable in opCommon.nmis. Replace http://localhost with the address of the server.
The email section is described in the Open-AudIT Enterprise - Configuration Guide document.
Set the permissions to writeable.
Code Block | ||
---|---|---|
| ||
chmod -R 755 /usr/local/omk/conf |
Create the nmis user.
Code Block | ||
---|---|---|
| ||
useradd nmis |
Start the daemon.
Code Block | ||
---|---|---|
| ||
service omkd start |
...
You should now be able to point a web browser at http://SERVER:8042/omk/oae
The default credentials for the Dashboard are user: nmis, password: nm1888.
Configure Apache
Copy the apache config file to the correct location and restart apache.
Section | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Copy the required files into the webroot
Section | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
...
|
Ensure index.php is pointed at contains the correct locationlocations for finding the OpenAudit files.
Edit
/var/www/open-audit/index.php (for Debian/Ubuntu prior to 14.04) or
/var/www/html/open-audit/index.php (for Ubuntu 14.04) or
/var/www/html/open-audit/index.php (for RedHat/CentOS)
and check the lines that specify the $system_path and $application_folder. There are two lines for each variable. Ensure the windows paths are commented out by placing a # at the start of the line. The linux paths should correspond to /usr/local/open-audit/code_igniter/ (system or application).
Remove index.html
The index.html file (if it exists) in the webroot is not required.
...
Column | |||||
---|---|---|---|---|---|
| |||||
for Debian / Ubuntu
|
...
width | 40% |
---|
for RedHat / CentOS
...
language | bash |
---|
...
.
...
Configure MySQL
...
- The root password for MySQL
...
- needs to be set next; if you have used
mysql_secure_installation
ormysqladmin
before to set the password, then you can skip this step.
In the command below
...
- replace the token
PASSWORD
(and only the
...
- all-uppercase token
PASSWORD
) with a suitable password of your choosing.
Code Block | ||
---|---|---|
| ||
mysql -u root -e "USE mysql; UPDATE user set Password = password('PASSWORD') WHERE User = 'root'; FLUSH PRIVILEGES;" |
...
- Now create the Open-AudIT database and the database user to be used by the application. Make sure you replace the token
PASSWORD
with the actual database password that you set.
Code Block | ||
---|---|---|
| ||
mysql -u root -pPASSWORD -e "CREATE DATABASE openaudit;" mysql -u root -pPASSWORD -e "CREATE USER openaudit@localhost IDENTIFIED BY 'openauditpassword';" mysql -u root -pPASSWORD -e "GRANT ALL PRIVILEGES ON openaudit.* TO openaudit@localhost IDENTIFIED BY 'openauditpassword';" mysql -u root -pPASSWORD -e "FLUSH PRIVILEGES;" |
- Insert the database schema
Code Block | ||
---|---|---|
| ||
mysql -u root -pPASSWORD openaudit < /usr/local/open-audit/other/openaudit_mysql.sql |
Set some configuration items. NOTE - replace IPADDRESS with your actual IP Address as obtained at the start of this document. Setting these details will activate the icon links in the header of Open-AudIT. These fields can also contain relative URL's, thus /omk/oae/map for a link to Maps for Open-AudIT on the same server. Links containing a port number must contain a full URL at this stage.
Code Block | ||
---|---|---|
| ||
mysql -u root -popenauditrootuserpassword -e "USE openaudit; DELETE FROM oa_config WHERE config_name = 'maps_url'; INSERT INTO oa_config (config_name, config_value, config_editable, config_description) VALUES ('maps_url', 'http://IPADDRESS/omk/oae/map', 'y', 'The web server address of Maps for Open-AudIT Enterprise.');"
mysql -u root -popenauditrootuserpassword -e "USE openaudit; DELETE FROM oa_config WHERE config_name = 'oae_url'; INSERT INTO oa_config (config_name, config_value, config_editable, config_description) VALUES ('oae_url', 'http://IPADDRESS/omk/oae', 'y', 'The web server address of Open-AudIT Enterprise.');" |
Test the Website
You should now be able to access the web page at http://IPADDRESS/open-audit/index.php Assuming you can, proceed to the next section.
Enter Your License
Go to the URL http://<server>/omk/oae/
Enter the default credentials of nmis and nm1888.
Click the "View and enter licenses" button.
Click "Enter a license key".
Paste your license key text into the text box and click "Add License".
You should see a message at the top of the screen saying "Success: You have added a license for Open-AudIT Enterprise."
Close the browser tab.
Click the "License Entered, Continue" button.
Accept the End User License Agreement.
You should now see the Open-AudIT Enterprise dashboard.
Log in to Open-AudIT Enterprise
Go to the URL http://IPADDRESS/omk/oae
Log in to Open-AudIT
Go to the URL http://IPADDRESS/open-audit/index.php/login/index/main/list_groups
If you don't have a valid license, you should be able to log in to Open-AudIT at http://IPADDRESS/open-audit/index.php/login/index/main/list_groups
Modify your Audit Scripts
If you have installed Open-AudIT into a sub directory on your webserver, you must alter the audit scripts to submit to the correct URL, which means the URL needs to include this sub directory as well.. The files that need to be modified are all in in /usr/local/open-audit/other
and are named named
- audit_subnet.sh
- audit_linux.sh
- audit_osx.sh
- audit_subnet.vbs
- audit_windows.vbs
You should reset the variable "url" (sans quotes) to include this subdirectory.
For example, on the Opmantek VM reset the audit_subnet.sh script from
url="http://localhost/index.php/system/add_nmap"
to