Registrations to Open-AudIT forums are now closed. To ask any new questions please visit Opmantek Community Questions.

Open-AudIT

What's on your network?
It is currently Thu Mar 28, 2024 7:19 pm

All times are UTC + 10 hours




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 
Author Message
 Post subject: nmap linux
PostPosted: Tue Dec 07, 2010 5:16 am 
Offline
Newbie

Joined: Tue Dec 07, 2010 4:20 am
Posts: 3
Hi !

I am giving a try to OA. Not that easy, regarding the lack of documentation...
Especially for Linux version, I would say.

Anyhow, I succeeded in grabbing info from both Linux or Windows hosts.

Now, I am stuck with scanning my network with nmap.
I ran the following script, very simplified version of nmap_linux.sh script available in OA package :

[code]#!/bin/bash
nmap_file="./nmap_file.txt"
nmap_input=`nmap -v -O -oN $nmap_file 192.168.0.1`
nmap_output=`cat $nmap_file`
wget --post-data="submit=submit&add=$nmap_output" http://my_server/OpenAudit/admin_nmap_input.php
[/code]

No success. There is no entry in 'Discover ports >> All active ports" on OA server :(

Find below the last lines of admin_nmap_input.php :
[code]<td valign="top">
<div class="main_each"><p class="contenthead">NMap</p>
IP Address: 192.168.0.1<br />Name: my-dhcp-0-1<br />Device Type: general purpose<br />Running: Microsoft Windows Vista|2008|7<br />Windows.<br />SELECT net_uuid FROM network_card WHERE net_ip_address = '192.168.0.1'<br />SELECT other_id FROM other WHERE other_ip_address = '192.168.000.001'<br /></div>
</div>
</td>
</body>
</html>
[/code]

Notes :

  • Of course, 192.168.0.1 is a running host, with many active ports.

  • Of course, my OA server is available at http://my_server/OpenAudit :)

  • I run this script from another linux host that the one hosting OA server (but it should not make any difference, I guess...)


Any idea why the NMAP table on OA server remains empty ?
Thanks in advance for support.


Top
 Profile  
Reply with quote  
 Post subject: Re: nmap linux
PostPosted: Wed Dec 08, 2010 1:16 pm 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1259
Documentation is not fun!

Make sure you're on the latest version of OpenAudit from SVN ([url=http://www.open-audit.org/phpBB3/viewtopic.php?f=6&t=1430]using SVN client[/url] or [url=http://www.open-audit.org/phpBB3/viewtopic.php?f=8&t=2414#p17091]not[/url]). Nmap [url=http://www.open-audit.org/phpBB3/viewtopic.php?f=10&t=3724#p16437]output changed[/url] at some point and OpenAudit needed some changes to work.

Hopefully this does it for you.


Top
 Profile  
Reply with quote  
 Post subject: Re: nmap linux
PostPosted: Sat Dec 11, 2010 4:14 am 
Offline
Newbie

Joined: Tue Dec 07, 2010 4:20 am
Posts: 3
Thanks for the answer.

I cleaned everything (webroot and mysql DB) and start with last version I have found in trunk folder (Version 10.09.01, according to what I can read on my OA server).

I tried the nmap script. And still no success :(
Did I miss something ?

Any way to debug this quickly (before I decide to dive into PHP code...!) ??

Thanks for help.


Top
 Profile  
Reply with quote  
 Post subject: Re: nmap linux
PostPosted: Sat Dec 11, 2010 4:29 am 
Offline
Newbie

Joined: Tue Dec 07, 2010 4:20 am
Posts: 3
I saved a version of generated admin_nmap_input.php, renamed it and copied into webroot folder.
I then opened this PHP document in my browser (http://my_oa_server/oa/my_renamed_admin_nmap_input.php), and this is what I can read on the page :

[quote]NMap

IP Address: 192.168.0.1
Name: dhcp-0-1
Device Type: general purpose
Running: Microsoft Windows Vista|2008|7
Windows.
SELECT net_uuid FROM network_card WHERE net_ip_address = '192.168.000.001'
SELECT other_id FROM other WHERE other_ip_address = '192.168.000.001'


Now is it supposed or not to add new records in mysql DB ??

Am I supposed to see something in 'Discovered ports >> All active ports' ??

Thanks.

Top
 Profile  
Reply with quote  
 Post subject: Re: nmap linux
PostPosted: Sun Dec 12, 2010 9:53 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1259
Without seeing the contents of nmap_file.txt my guess would be nmap is not outputting a MAC addresss which admin_nmap_input.php is expecting. If there's nothing too confidential in the nmap_file.txt post it here for further debugging.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 posts ] 

All times are UTC + 10 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group