Open-AudIT

What's on your network?
It is currently Mon Feb 26, 2018 3:42 am

All times are UTC + 10 hours




Post new topic Reply to topic  [ 5 posts ] 
Author Message
PostPosted: Wed Jun 08, 2016 10:23 pm 
Offline
Newbie

Joined: Sat Jun 04, 2016 3:26 am
Posts: 9
I am attempting to run the version of the VB script that deployed with version 1.12.6 using cscript on a Windows 2003 R2 server. The script begins to execute correctly but then it will usually fail after spending about 2-3 minutes seeming stalled while auditing either Shares or Printers.

Is there anything I can do to troubleshoot this error? Please let me know.. Thanks.

You are running version 1.12.6 of Open-AudIT.
Your Host is: openaudit, and it's OS is Linux.
Your database platform is mysql (version 5.7.12).
Your web server is Apache/2.4.18 (Fedora) PHP/5.6.22 .
Your PHP version is 5.6.22 and it's running in timezone America/New_York.

-Nick

This is the script output:

C:\Documents and Settings\administrator\My Documents>cscript.exe audit_windows.vbs
Microsoft (R) Windows Script Host Version 5.6
Copyright (C) Microsoft Corporation 1996-2001. All rights reserved.

starting audit - .
Not pinging target because we're auditing localhost.
My PID is : 5424
Audit Start Time : 2016-06-08 08:20:22
Audit Location: local
-------------------
system info
Get IP Adress of adapter with default route
windows info
bios info
scsi info
processor info
memory info
motherboard info
optical info
video info
monitor info
sound info
disk info
partition info
mapped disks info
mount point info
shares info
network card info
network address info
DNS info
printer info
C:\Documents and Settings\administrator\My Documents\audit_windows.vbs(2811, 4)
Microsoft VBScript runtime error: Invalid use of Null: 'Join'


Top
 Profile  
Reply with quote  
PostPosted: Thu Jun 09, 2016 1:57 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1254
Brute force error handling. I'm not sure what objItem.CapabilityDescriptions is doing. It may be returning a Null which could probably be handled with better code. The fix below should handle anything.

Change line 2811 from
Code:
capabilities = join(objItem.CapabilityDescriptions, ", ")

to
Code:
         capabilities = ""
         on error resume next
            capabilities = join(objItem.CapabilityDescriptions, ", ")
         On Error Goto 0


Top
 Profile  
Reply with quote  
PostPosted: Thu Jun 09, 2016 3:06 am 
Offline
Site Admin
User avatar

Joined: Mon Jun 07, 2004 11:48 am
Posts: 1944
Location: Brisbane, Australia
Thanks guys - fixed for next release. I've also added some error handling to the other items using Win32_Printer that weren't utilising "on error resume next".

According to the MS page, Win32_Printer requires Vista/2008 and up.
https://msdn.microsoft.com/en-gb/library/aa394363(v=vs.85).aspx

_________________
Support and Development hours available from Opmantek.
Please consider a purchase to help make Open-AudIT better for everyone.


Top
 Profile  
Reply with quote  
PostPosted: Thu Jun 09, 2016 4:15 am 
Offline
Moderator

Joined: Fri Jul 20, 2007 8:27 am
Posts: 1254
At this point I only have one Windows 2003 SP2 server and Win32_Printer works.

I really should get rid of that machine.


Top
 Profile  
Reply with quote  
PostPosted: Fri Jun 10, 2016 12:24 am 
Offline
Newbie

Joined: Sat Jun 04, 2016 3:26 am
Posts: 9
Thanks. I was able to modify the vbscript today and I got my 2003 server to successfully audit!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 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:  
cron
Powered by phpBB® Forum Software © phpBB Group