WMI Collecting Windows Logs



Similar documents
Setting up DCOM for Windows XP. Research

Nagios XI Monitoring Windows Using WMI

Windows Firewall must be enabled on each host to allow Remote Administration. This option is not enabled by default

Setup non-admin user to query Domain Controller event log for Windows2003

TrueEdit Remote Connection Brief

TechNote. Contents. Overview. System or Network Requirements. Deployment Considerations

DCOM Setup. User Manual

AlienVault Unified Security Management Solution Complete. Simple. Affordable Life Cycle of a log

AlienVault. Unified Security Management (USM) 5.1 Running the Getting Started Wizard

Collecting Windows logs using Snare

Toolbox 3.3 Client-Server Configuration. Quick configuration guide. User manual. For the latest news. and the most up-todate.

Configuring IBM Cognos Controller 8 to use Single Sign- On

AlienVault. Unified Security Management 5.x Configuring a VPN Environment

Active Directory integration with CloudByte ElastiStor

Upgrading BRS Appliance from BRS version 8.10 to version 8.11

This document describes the software upgrade of BRS Appliance from v8.9 to v8.10.

IIS, FTP Server and Windows

Kepware Technologies Remote OPC DA Quick Start Guide (DCOM)

Application Note 8: TrendView Recorders DCOM Settings and Firewall Plus DCOM Settings for Trendview Historian Server

Zanibal Plug-in For Microsoft Outlook Installation & User Guide Version 1.1

Device Integration: Checkpoint Firewall-1

DCOM settings for computer-to-computer communication between OPC servers and OPC clients

Video Administration Backup and Restore Procedures

Reference and Troubleshooting: FTP, IIS, and Firewall Information

Global Image Management System For epad-vision. User Manual Version 1.10

User Management Guide

Moving the TRITON Reporting Databases

OrgPublisher 11 Web Administration Installation for Windows 2008 Server

FTP, IIS, and Firewall Reference and Troubleshooting

InduSoft Web Studio + Windows XP SP2. Introduction. Initial Considerations. Affected Features. Configuring the Windows Firewall

AlienVault Unified Security Management (USM) 4.x-5.x. Deploying HIDS Agents to Linux Hosts

How to Use Remote Access Using Internet Explorer

Enabling Remote Management of SQL Server Integration Services

rev. 31 (applies to CyBro OPC Server v3.0.4 and later)

Hyper-V Server 2008 Setup and Configuration Tool Guide

DCOM & Control List Genetec Information Systems Page i Win2003 Service Pack 1

Enabling Kerberos SSO in IBM Cognos Express on Windows Server 2008

Server Manager Performance Monitor. Server Manager Diagnostics Page. . Information. . Audit Success. . Audit Failure

SQL Server Setup for Assistant/Pro applications Compliance Information Systems

Configuring WMI Performance Monitors

Configuring WMI on Windows Vista and Windows Server 2008 for Application Performance Monitor

This means that any user from the testing domain can now logon to Cognos 8 (and therefore Controller 8 etc.).

Changing Passwords in Cisco Unity 8.x

OrgPublisher EChart Server Setup Guide

Integrating LANGuardian with Active Directory

Use the below instructions to configure your wireless settings to connect to the secure wireless network using Microsoft Windows Vista/7.

Tool Tip. SyAM Management Utilities and Non-Admin Domain Users

Installing and Configuring Active Directory Agent

Browser Client 2.0 Admin Guide

NetIQ Advanced Authentication Framework - MacOS Client

1. Set Daylight Savings Time Create Migrator Account Assign Migrator Account to Administrator group... 4

Customer Tips. Configuring Color Access on the WorkCentre 7328/7335/7345 using Windows Active Directory. for the user. Overview

DC Agent Troubleshooting

NT Authentication Configuration Guide

NetBeat NAC Version 9.2 Build 4 Release Notes

User Migration Tool. Note. Staging Guide for Cisco Unified ICM/Contact Center Enterprise & Hosted Release 9.0(1) 1

ECA IIS Instructions. January 2005

Remote Desktop access via Faculty Terminal Server Using Internet Explorer (versions 5.x-7.x)

NovaBACKUP xsp Version 15.0 Upgrade Guide

Network Connect Installation and Usage Guide

Basic Exchange Setup Guide

PRODUCT WHITE PAPER LABEL ARCHIVE. Adding and Configuring Active Directory Users in LABEL ARCHIVE

This document describes the installation of the Web Server for Bosch Recording Station 8.10.

External Authentication with Citrix Secure Gateway - Presentation server Authenticating Users Using SecurAccess Server by SecurEnvoy

Remote Desktop Web Access. Using Remote Desktop Web Access

SAP Business Objects Data Services Setup Guide

System Administration and Log Management

Sage ERP Accpac 6.0A. SageCRM 7.0 I Integration Guide

Historical Reporting Client (HRC) User Login Fails

Configuring Color Access on the WorkCentre 7120 Using Microsoft Active Directory Customer Tip

System Area Management Software Tool Tip: Integrating into NetIQ AppManager

Contents. VPN Instructions. VPN Instructions... 1

Use of Commercial Backup Software with Juris (Juris 2.x w/msde)

OSSIM. Open Source Security Information Management. Brian E. Lavender. Sac State. CSC 250, Spring Final Project

OPC Server Machine Configuration

Troubleshoot ViewMail for Outlook Issues

Oracle Enterprise Manager. Description. Versions Supported

Remote Access: Internet Explorer

How to install Small Business Server 2003 in an existing Active

Configuring a Custom Load Evaluator Use the XenApp1 virtual machine, logged on as the XenApp\administrator user for this task.

XStream Remote Control: Configuring DCOM Connectivity

Basic Exchange Setup Guide

Installation Steps for PAN User-ID Agent

WhatsUp Gold v16.1 Installation and Configuration Guide

NETWRIX ACCOUNT LOCKOUT EXAMINER

How To Connect To A Wireless Network On Windows 7 (Windows 7) On A Pc Or Mac Or Ipad (Windows) On Pc Or Ipa (Windows 8) On Your Computer Or Mac (Windows). (Windows.7) On An

Creating Home Directories for Windows and Macintosh Computers

Application Note. ShoreTel 9: Active Directory Integration. Integration checklist. AN June 2009

Troubleshooting Guide

How to configure MAC authentication on a ProCurve switch

HELP DOCUMENTATION SSRPM WEB INTERFACE GUIDE

Installing, Uninstalling, and Upgrading Service Monitor

F O U N D A T I O N. Using OPC via DCOM with Microsoft Windows XP Service Pack 2. Karl-Heinz Deiretsbacher, Siemens AG

Microsoft XP Professional Remote Desktop Connection

Assets, Groups & Networks

Dell SupportAssist Version 2.0 for Dell OpenManage Essentials Quick Start Guide

MailEnable Connector for Microsoft Outlook

Differences between Computer and User Templates

Remote Desktop Solution, (RDS), replacing CITRIX Home Access

Transcription:

WMI Collecting Windows Logs (tested on Windows 2008 Servers / Windows 7) 14.04.2011 Pascal Cronauer Version 1.0 10.11.2011 Pascal Cronauer Version 1.1

1 Introduction We are using WMI to remotely collect Microsoft Windows events and data in an agentless way. To get these logs to the AlienVault Unified SIEM (OSSIM) you have to configure a few things on OSSIM and also on the Windows machines if you want more security. We are using WMI to remotely collect Microsoft Windows events and data in an agentless way. To get these logs to the AlienVault Unified SIEM (OSSIM) you have to configure a few things on OSSIM and also on the Windows machines if you want more security. 2 Configure Windows In any case you should create a separated limited user on windows for security reason. Don t use the administrator account in an productive environment just use it for testing. In this scenario I created a limited user called wmiuser with the password wmi. To give that limited user access to remotely login and for capturing the logs, we have to configure a few permissions in the DCOM settings. To enable the using of SDEE you must have direct access to Cisco device and also administrator credentials to change configuration. Follow the next steps: 2.1. Grant DCOM remote launch and activate permissions for the new user 1. Click Start, click Run, type DCOMCNFG, and then click OK. 2. In the Component Services dialog box, expand Component Services, expand Computers, and then right-click My Computer and click Properties. 3. Go to My Computer Properties dialog box, click the COM Security tab. 4. Under Launch and Activation Permissions (picture 1), click Edit Limits. 5. In the Launch Permission dialog box, follow these steps to add our "wmiuser" user: 6. In the Launch Permission dialog box, click Add. 7. In the "Select Users, Computers, or Groups" dialog box, add your name in the "Enter the object names to select" box, and then click OK. 8. In the Launch Permission dialog box, select our user in the "Group or user names" box. In the Allow column under Permissions for User, select Remote Launch, Local Activation and Remote Activation, and then click OK.

(picture 1) 9. Under Access Permissions (picture 2), click Edit Limits. 10. In the Access Permission dialog box, select ANONYMOUS LOGON name in the Group or user names box. In the Allow column under Permissions for User, select Remote Access, and then click OK.

(picture 2) 2.2. Set the WMIuser to the Event Log Readers Group On the Windows 2008 Server you have to do it under the Active Directory where the users are stored (picture 3). If you do it on a Windows 7 you Local Users and Groups (picture 4). (picture 3)

(picture 4) 2.3. Set namespace permissions This permissions allows you to collect the Windows security / system / application logs. 1. Click Start, click Run, type compmgmt.msc, and then click OK. 2. Go to Services and Applications 3. Right click on WMI Control, choose Properties 4. Go to Security TAB and open the Root -tree 5. Mark CLIMV2 and click on Security on the right bottom corner. 6. Add the wmiuser to the permissions list and enable the Remote Enable & Read Security sections. (picture 5)

3 Configure OSSIM Before activating the wmi plugins it is necessary to create a file with the Windows credentials and if not already installed, install the new wmic package from the repository. (apt-get install wmi-client). Attention!: Please, use the newest wmi-client if you want to get it work also on Windows 2008 Servers. Packagename: wmi-client_1%3a0.1.13-1_amd64.deb.deb. Check if you have the right version: root@ossim:~# dpkg l grep wmi-client ii wmi-client 1:0.1.13-1 DCOM/WMI client implementation If you don t have the write version, you have to upgrade to the newest version. Create the file wmi_crendentials.csv root@ossim:~# vi /etc/ossim/agent/wmi_credentials.csv Add the IP of the Windows machine(s), (domain)/users and passwords with the following formats: (Don t use password with character @ ) #without domain 192.168.1.2,user,pass 192.168.1.3,user,pass #domain 192.168.1.3,domain\\user,pass Now we can activate the wmi plugins: 1. Execute alienvault-setup 2. Go to (3) Change Sensor Settings 3. Go to (3) Select/Disable detector plugins 4. Enable wmi-application-logger 5. Enable wmi-system-logger 6. Enable wmi-securtiy-logger 7. Save and exit 8. Restart ossim-agent: root@ossim:~# /etc/init.d/ossim-agent restart That s all. Now you can view the Windows events at the framework. These events appear as Snare events with the Plugin ID 1518. They should appear in SIEM with the Signature snarewindows

4 wmi-security-logger.cfg ;; wmi testing plugin ;; Warning: events will appear as "Snare" events [DEFAULT] plugin_id=1518 [config] type=detector enable=yes source=wmi credentials_file=/etc/ossim/agent/wmi_credentials.csv sleep=10 process= start=no stop=no [start_cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required cmd=wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select LogFile,RecordNumber from Win32_NTLogEvent Where Logfile = 'Security'" head -n 3 tail -n 1 cut -f 2 -d \ regexp= [cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required. OSS_COUNTER is a *must* and is the integer returned above cmd = wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select ComputerName,EventCode,Logfile,Message,RecordNumber,SourceName,TimeWritten,User from Win32_NTLogEvent Where Logfile = 'Security' and RecordNumber > OSS_COUNTER" cat start_regexp=^([^\ ]+)\ (\d+)\ ([^\ ]+)\ regexp="^(?p<system_name>[^\ ]+)\ (?P<plugin_sid>\d+)\ (?P<logfile>[^\ ]+)\ (?P<message>[^\ ] +)\ (?P<recordnumber>[^\ ]+)\ (?P<sourcename>[^\ ]+)\ (?P<timewritten>[^\ ]+)\ (?P<username>. *)$" plugin_sid={$1} userdata2={$2} userdata3={$3} userdata4={$4} userdata5={$5} userdata6={$6} username={$7}

5 wmi-application-logger.cfg ;; wmi testing plugin ;; Warning: events will appear as "Snare" events [DEFAULT] plugin_id=1518 [config] type=detector enable=yes source=wmi credentials_file=/etc/ossim/agent/wmi_credentials.csv sleep=10 process= start=no stop=no [start_cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required cmd=wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select LogFile,RecordNumber from Win32_NTLogEvent Where Logfile = 'Application'" head -n 3 tail -n 1 cut -f 2 -d \ regexp= [cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required. OSS_COUNTER is a *must* and is the integer returned above cmd = wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select ComputerName,EventCode,Logfile,Message,RecordNumber,SourceName,TimeWritten,User from Win32_NTLogEvent Where Logfile = 'Application' and RecordNumber > OSS_COUNTER" cat start_regexp=^([^\ ]+)\ (\d+)\ ([^\ ]+)\ regexp="^(?p<system_name>[^\ ]+)\ (?P<plugin_sid>\d+)\ (?P<logfile>[^\ ]+)\ (?P<message>[^\ ] +)\ (?P<recordnumber>[^\ ]+)\ (?P<sourcename>[^\ ]+)\ (?P<timewritten>[^\ ]+)\ (?P<username>. *)$" plugin_sid={$1} userdata2={$2} userdata3={$3} userdata4={$4} userdata5={$5} userdata6={$6} username={$7}

6 wmi-system-logger.cfg ;; wmi testing plugin ;; Warning: events will appear as "Snare" events [DEFAULT] plugin_id=1518 [config] type=detector enable=yes source=wmi credentials_file=/etc/ossim/agent/wmi_credentials.csv sleep=10 process= start=no stop=no [start_cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required cmd=wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select LogFile,RecordNumber from Win32_NTLogEvent Where Logfile = 'System'" head -n 3 tail -n 1 cut -f 2 -d \ regexp= [cmd] ;; OSS_WMI_USER, OSS_WMI_PASS and OSS_WMI_HOST should be used if substitutions are required. OSS_COUNTER is a *must* and is the integer returned above cmd = wmic -U OSS_WMI_USER%OSS_WMI_PASS //OSS_WMI_HOST "Select ComputerName,EventCode,Logfile,Message,RecordNumber,SourceName,TimeWritten,User from Win32_NTLogEvent Where Logfile = 'System' and RecordNumber > OSS_COUNTER" cat start_regexp=^([^\ ]+)\ (\d+)\ ([^\ ]+)\ regexp="^(?p<system_name>[^\ ]+)\ (?P<plugin_sid>\d+)\ (?P<logfile>[^\ ]+)\ (?P<message>[^\ ] +)\ (?P<recordnumber>[^\ ]+)\ (?P<sourcename>[^\ ]+)\ (?P<timewritten>[^\ ]+)\ (?P<username>. *)$" plugin_sid={$1} userdata2={$2} userdata3={$3} userdata4={$4} userdata5={$5} userdata6={$6} username={$7}

7 Troubleshooting 7.1 How to check if you have a connection with the Windows machine You can check it by using the wmic command on the command line manually: Without domain: root@ossim:~# wmic U <user>%<pass> \\<windows_ip_address> select from Win32_Process Domain: root@ossim:~# wmic U <domain>\\<user>%<pass> \\<windows_ip_address> select from Win32_Process 7.2 How to check if the agent is receiving events. You can monitor agent.log and check if the events wmi events arriving. root@ossim:~# tail f /var/log/ossim/agent.log If you have a lot of logs, check it with the plugin ID: root@ossim:~# tail f /var/log/ossim/agent.log grep plugin_id= 1518 7.3 How to check if the server is receiving events. You can monitor server.log and show events. root@ossim:~# tail f /var/log/ossim/server.log