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 Fri Mar 29, 2024 5:37 am

All times are UTC + 10 hours




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 
Author Message
PostPosted: Thu Mar 03, 2011 5:48 pm 
Offline
Newbie

Joined: Thu Apr 01, 2010 7:35 pm
Posts: 25
In Software Register audit now lists computers.
Is it possible to list users?


Top
 Profile  
Reply with quote  
PostPosted: Fri Mar 04, 2011 9:46 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1259
I'm guessing you want something like this:

Patch software_register_details.php
[code]
Index: software_register_details.php
===================================================================
--- software_register_details.php (revision 1251)
+++ software_register_details.php (working copy)
@@ -36,7 +36,7 @@
$sql2 = "SELECT sum(license_purchase_number) as number_purchased FROM ";
$sql2 .= "software_licenses, software_register WHERE ";
$sql2 .= "license_software_id = software_reg_id AND ";
- $sql2 .= "software_title = '" . $myrow['software_title'] . "'";
+ $sql2 .= "software_title = '" . mysql_real_escape_string($myrow['software_title']) . "'";
$result2 = mysql_query($sql2, $db);
$myrow2 = mysql_fetch_array($result2);

@@ -112,7 +112,7 @@
} else {}

$bgcolor = "#F1F1F1";
-$sql = "select sys.system_uuid, sys.system_os_name, sys.system_description, sys.net_ip_address, sys.system_name, sw.software_name from ";
+$sql = "select sys.system_uuid, sys.system_os_name, sys.system_description, sys.net_ip_address, sys.system_name, sw.software_name, sys.net_user_name from ";
$sql .= "software sw, system sys where ";
$sql .= "sw.software_name = '" . addslashes($name) . "' AND ";
$sql .= "sw.software_uuid = sys.system_uuid AND ";
@@ -123,12 +123,13 @@
if ($myrow = mysql_fetch_array($result)){
echo "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\" class=\"content\">\n";
echo "<tr><td class=\"contenthead\" colspan=\"3\"><br />Systems with \"" . $name . "\" installed.</td></tr>\n";
- echo "<tr><td>&nbsp;&nbsp;<b>IP Address</b></td><td>&nbsp;&nbsp;<b>Name</b></td><td>&nbsp;&nbsp;<b>Description</b></td></tr>\n";
+ echo "<tr><td>&nbsp;&nbsp;<b>IP Address</b></td><td>&nbsp;&nbsp;<b>Name</b></td><td>&nbsp;&nbsp;<b>Description</b></td><td>&nbsp;&nbsp;<b>Current User</b></td></tr>\n";
do {
echo "<tr bgcolor=\"" . $bgcolor . "\">\n";
- echo " <td width=\"33%\">&nbsp;&nbsp;" . $myrow["net_ip_address"] . "&nbsp;&nbsp;</td>\n";
- echo " <td width=\"33%\">&nbsp;&nbsp;<a href=\"system.php?pc=" . $myrow["system_uuid"] . "&amp;view=summary\" class=\"content\">" . $myrow["system_name"] . "</a>&nbsp;&nbsp;</td>\n";
- echo " <td width=\"33%\">&nbsp;&nbsp;" . $myrow["system_description"] . "</td>\n";
+ echo " <td width=\"20%\">&nbsp;&nbsp;" . $myrow["net_ip_address"] . "&nbsp;&nbsp;</td>\n";
+ echo " <td width=\"25%\">&nbsp;&nbsp;<a href=\"system.php?pc=" . $myrow["system_uuid"] . "&amp;view=summary\" class=\"content\">" . $myrow["system_name"] . "</a>&nbsp;&nbsp;</td>\n";
+ echo " <td width=\"30%\">&nbsp;&nbsp;" . $myrow["system_description"] . "</td>\n";
+ echo " <td width=\"25%\">&nbsp;&nbsp;" . $myrow["net_user_name"] . "</td>\n";
echo "</tr>\n";

if ($bgcolor == "#F1F1F1") { $bgcolor = "#FFFFFF"; } else { $bgcolor = "#F1F1F1"; }
[/code]

Or replace it with the following file after removing the .txt extension.


Attachments:
software_register_details.php.txt [7.41 KiB]
Downloaded 417 times
Top
 Profile  
Reply with quote  
PostPosted: Wed Mar 09, 2011 1:14 am 
Offline
Newbie

Joined: Thu Apr 01, 2010 7:35 pm
Posts: 25
How do I use that one?


Top
 Profile  
Reply with quote  
PostPosted: Wed Mar 09, 2011 3:09 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1259
Download the attached "software_register_details.php.txt" file
Remove the .txt extension
Overwrite the existing software_register_details.php file in your web directory with the downloaded one

Go to your OpenAudit site
Select "Software Register" from the menu then the "Software Register" submenu
Click on a software package name
See that I've added a current user to the Systems with <software> installed

Then realize that I might have misunderstood you completely and you want to audit software that is installed per-user and not per-computer. I am not psychic and your original request is pretty terse. You'll need to give more detail in your request if you want something different.


Top
 Profile  
Reply with quote  
PostPosted: Wed Mar 09, 2011 7:51 pm 
Offline
Newbie

Joined: Thu Apr 01, 2010 7:35 pm
Posts: 25
Worked like a charm :)

Is it possible to see in audit when a software was last used by the user?


Top
 Profile  
Reply with quote  
PostPosted: Thu Mar 10, 2011 2:51 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1259
No.

Although most things are possible you'll not get this data without a massive amount of work.


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.  [ 6 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