<div>I am trying to match the pattern for DC logs and here is my XML format</div><div><br></div><div>Here's the patterndb.xml file at /opt/syslog-ng/var/patterndb.xml"</div><div>---------------------------------------</div>
<div><div><?xml version='1.0' encoding='UTF-8'?></div><div><patterndb version='3' pub_date='2011-12-21'></div><div><ruleset id='90c9b341f4e3d63c5ed8b29950491bf8' name='Domain Ctrls'></div>
<div><rules></div><div> <rule provider='localtest' id='012c230f236d6a3f761ba956e7dff26a' class='system'></div><div> <patterns></div><div> <pattern></div>
<div>@ESTRING:user::@ Security Microsoft Windows security auditing.: [Success Audit] A computer account was changed. Subject: Security ID: S-1-5-7 Account Name: ANONYMOUS LOGON Account Domain: NT AUTHORITY Logon ID: 0x3e6 Computer Account That Was Changed: Security ID: @ESTRING:: @Account Name: @ESTRING:<b>ACC_NAME</b>: @ Account Domain: testdomain Changed Attributes: SAM Account Name: - Display Name: - User Principal Name: - Home Directory: - Home Drive: - Script Path: - Profile Path: - User Workstations: - Password Last Set: @ESTRING:: @@ESTRING:: @ Account Expires: - Primary Group ID: - AllowedToDelegateTo: - Old UAC Value: - New UAC Value: - User Account Control: - User Parameters: - SID History: - Logon Hours: - DNS Host Name: - Service Principal Names: - Additional Information: Privileges: - (EventID 4742)</div>
<div></pattern></div><div> </patterns></div><div><br></div><div></rule></div><div></rules></div><div></ruleset></div><div></patterndb></div></div><div><br></div><div>
---------------------------------------</div>Here's the syslog-ng conf extract:<div>---------------------------------------</div><div><div>parser pattern_db {</div><div> db_parser(</div><div> file("/opt/syslog-ng/var/patterndb.xml")</div>
<div> );</div><div> };</div><div><div>destination patt_d{</div><div>file("/data/test/${R_YEAR}/${R_MONTH}/${R_DAY}/Domain_Ctrl__${SOURCEIP}_${R_YEAR}_${R_MONTH}_${R_DAY}.log"</div><div>owner("test")</div>
<div> group("test")</div><div> perm(0660)</div><div> dir-owner("test")</div><div> dir-group("test")</div><div> dir-perm(0770)</div>
<div>template("$<b>ACC_NAME</b>\n $MSG\n")</div><div> );</div><div>};</div></div><div><br></div><div>---------------------------------</div><div><br></div><div>but the <b>ACC_NAME</b> returns blank, although the log contains that field.</div>
<div><br></div><div><br></div>-- <br><div>Thanks<br>Anup</div>
</div>