<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.1" -->
<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/"
	>

<channel>
	<title>Dinis Cruz Blog</title>
	<link>http://blogs.owasp.org/diniscruz</link>
	<description>A place to post my research (and my comments) on Security and on the .NET Framework</description>
	<pubDate>Thu, 24 Jan 2008 15:21:03 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.1</generator>
	<language>en</language>
			<item>
		<title>DN_BOFinder - Dot Net Buffer Overflow Finder</title>
		<link>http://blogs.owasp.org/diniscruz/2007/06/29/dn_bofinder-dot-net-buffer-overflow-finder/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/06/29/dn_bofinder-dot-net-buffer-overflow-finder/#comments</comments>
		<pubDate>Fri, 29 Jun 2007 18:15:57 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/06/29/dn_bofinder-dot-net-buffer-overflow-finder/</guid>
		<description><![CDATA[The DN_BOFinder (DotNet Buffer Overflow Finder) is a semi-inteligent tool designed to find Buffer Overflows type vulnerabilities in COM objects used by .NET Assemblies (and mistakes in unsafe .Net code blocks), itÂ makes extended use of Reflection toÂ dynamicaly createÂ live instances ofÂ classes and invoke its non static methods.
I just uploaded the latest version of this tool to [...]]]></description>
			<content:encoded><![CDATA[<p>The DN_BOFinder (DotNet Buffer Overflow Finder) is a semi-inteligent tool designed to find Buffer Overflows type vulnerabilities in COM objects used by .NET Assemblies (and mistakes in unsafe .Net code blocks), itÂ makes extended use of Reflection toÂ dynamicaly createÂ live instances ofÂ classes and invoke its non static methods.</p>
<p>I just uploaded the latest version of this tool to sourceforge and updated its page at owasp.org : <a href="https://www.owasp.org/index.php/DN_BOFinder">https://www.owasp.org/index.php/DN_BOFinder</a>.</p>
<p>Let me know what you think of it.</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/06/29/dn_bofinder-dot-net-buffer-overflow-finder/feed/</wfw:commentRss>
		</item>
		<item>
		<title>OWASP, Evangelism and Ounce</title>
		<link>http://blogs.owasp.org/diniscruz/2007/04/19/owasp-evangelism-and-ounce/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/04/19/owasp-evangelism-and-ounce/#comments</comments>
		<pubDate>Thu, 19 Apr 2007 14:01:00 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/04/19/owasp-evangelism-and-ounce/</guid>
		<description><![CDATA[Hi, today I would like to make an  announcement about a change in my
professional live which should have very  positive site effects on my
contributions to the community (and hopefully to  the state of the
security of the applications we all use.
I basically  decided to accept a very generous (and flexible) offer by
OunceLabs [...]]]></description>
			<content:encoded><![CDATA[<p>Hi, today I would like to make an  announcement about a change in my<br />
professional live which should have very  positive site effects on my<br />
contributions to the community (and hopefully to  the state of the<br />
security of the applications we all use.</p>
<p>I basically  decided to accept a very generous (and flexible) offer by<br />
OunceLabs (<a href="http://www.ouncelabs.com/">http://www.ouncelabs.com</a>) to (as a contractor and  special<br />
advisor) help with the development of their product and on  their<br />
technical consultancy services.</p>
<p>As you know I value my  independence and integrity very highly and am<br />
happy to say that the contract  with Ounce will still allow me to work on<br />
other projects (i.e. I am only  committed to Ounce a certain number of<br />
days per month). Basically I am  replacing my current recurring contact<br />
with a global bank with a recurring  contract with source code security<br />
scanner vendor.</p>
<p>This changes  nothing on my current OWASP responsibilities and<br />
commitment. If anything it  will increase it since Ounce benefits<br />
enormously with OWASP&#8217;s growth,  maturity and reach.</p>
<p>I am still 100% committed to OWASP values, and please  let me know (and<br />
hit me on the head) if I go off on weird  tangents.</p>
<p>One of the reasons I chose to accept Ounce&#8217;s proposal was  the<br />
opportunity to work and help to develop the next generation of  source<br />
code scanners (especially in the .NET area). As you know I do  have<br />
strong views on how they should work, what they should do and where  they<br />
should be used, and it is my plans to document and blog about it as  much<br />
as possible.</p>
<p>Of course that when I speak with my OWASP hat I will  have to be<br />
independent which means that I will not make those posts  &#8216;under-<br />
cover marketing messages&#8217; or anti-Fortify (the main competitor)  rants.</p>
<p>This will also be an opportunity to start defining better how  OWASP<br />
<!-- D(["mb","materials should be referenced since OunceLabs is one of the  companies\u003cbr\&amp;gt;that currently 'abuses' OWASP's top 10 (them and every other web  app\u003cbr\&amp;gt;scanner). So I view as one of my responsibilities to sort this mess  out\n\u003cbr\&amp;gt;and really clarify what (using the Top 10 as an example) can and  can't\u003cbr\&amp;gt;be detected using XYZ tool/technique.\u003cbr\&amp;gt;\u003cbr\&amp;gt;This means that OWASP's  board will now be made of 1 member from a vendor\u003cbr\&amp;gt;organization (me) and 3 from  a training/consulting company (Jeff, Andrew\n\u003cbr\&amp;gt;and Dave (all from Aspect)). Side  Note, it would be interesting to do a\u003cbr\&amp;gt;similar analysis about our project and  chapter leaders.\u003cbr\&amp;gt;\u003cbr\&amp;gt;As committed as always to OWASP,\u003cbr\&amp;gt;",1] ); D(["mb","\u003cspan class\u003dsg\&amp;gt;\u003cbr\&amp;gt;Dinis  Cruz\u003cbr\&amp;gt;Chief OWASP Evangelist\n\u003cbr\&amp;gt;\u003ca href\u003d\"http://www.owasp.org\" target\u003d\"_blank\" onclick\u003d\"return top.js.OpenExtLink(window,event,this)\"\&amp;gt;http://www.owasp.org\u003c/a\&amp;gt;\u003cbr\&amp;gt; \u003cbr\&amp;gt;\n\u003c/span\&amp;gt;",0] );  //-->materials should be referenced since OunceLabs is one of the  companies<br />
that currently &#8216;abuses&#8217; OWASP&#8217;s top 10 (them and every other web  app<br />
scanner). So I view as one of my responsibilities to sort this mess  out<br />
and really clarify what (using the Top 10 as an example) can and  can&#8217;t<br />
be detected using XYZ tool/technique.</p>
<p>This means that OWASP&#8217;s  board will now be made of 1 member from a vendor<br />
organization (me) and 3 from  a training/consulting company (Jeff, Andrew<br />
and Dave (all from Aspect)). Side  Note, it would be interesting to do a<br />
similar analysis about our project and  chapter leaders.</p>
<p>As committed as always to OWASP,</p>
<p>Dinis  Cruz<br />
Chief OWASP Evangelist<br />
<a href="http://www.owasp.org/">http://www.owasp.org</a><font><br />
</font></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/04/19/owasp-evangelism-and-ounce/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Lists of tools for VMWare box</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/26/lists-of-tools-for-vmware-box/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/26/lists-of-tools-for-vmware-box/#comments</comments>
		<pubDate>Mon, 26 Mar 2007 10:08:52 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/26/lists-of-tools-for-vmware-box/</guid>
		<description><![CDATA[One of the questions that I always have during my classes is: &#8220;Can you give me a list of tools that are installed on the VWMare that we use&#8221;. So here is it (everything apart from the Microsoft OS is free, evaluation versins or Open Source)
1) Microsoft Develoment Environment:
* IIS with ASP.NET
* Windows 2003 Web [...]]]></description>
			<content:encoded><![CDATA[<p>One of the questions that I always have during my classes is: &#8220;Can you give me a list of tools that are installed on the VWMare that we use&#8221;. So here is it (everything apart from the Microsoft OS is free, evaluation versins or Open Source)</p>
<p>1) Microsoft Develoment Environment:</p>
<p>* IIS with ASP.NET<br />
* Windows 2003 Web edition with SP1<br />
* .Net Framework 1.1<br />
* .Net Framework 2.0<br />
* .Net Framework SDK 2.0<br />
* Visual Studio C#  Express<br />
* Visual Studio C++ Express<br />
* Visual Studio Web Developer Express<br />
* MSSQL Server 2005 Express<br />
* MSDN Express Library</p>
<p>2) other non-security windows tools</p>
<p>* Winzip (evaluation)<br />
* FireFox<br />
* Adobe Acrobat Reader<br />
* Java Runtime<br />
* VMWare Tools<br />
* SnagIt (evaluation)<br />
* TrueCrypt<br />
* Eclipse<br />
* Regulator - RegEx builder tool</p>
<p>3) OWASP Tools</p>
<p>* OWASP WebScarab<br />
* OWASP WebGoat<br />
* OSG - OWASP Site Generator<br />
* ORG - OWASP Report Generator<br />
* OWASP Tiger<br />
* CAL 9000<br />
* Sprajax<br />
* offline copy of the<br />
- OWASP  Top 10<br />
- OWASP Testing Guide (new one)<br />
- OWASP Guide</p>
<p>4) Network / Infrastructure tools:<br />
* WinPCap &amp; WireShark<br />
* Cain &amp; Able<br />
* Echo Mirage - C++ Tcp Trafic hooking tool<br />
* IIS 6.0 Resource kit (mainly for the IIS Metabase tools: MetaAcl.exe and MtaEdt22.exe)<br />
* MSBA (Microsoft Baseline Security Analyzer)<br />
* Microsoft Threat Modeling tool (both versions)<br />
* Metasploit 2.6 &amp; 3.0<br />
* Nessus<br />
* SysInternals tools:<br />
- Process Explorer<br />
- FileMon<br />
- RegMon<br />
- TCPView<br />
- TDIMon<br />
- DbgView<br />
- TokenMon<br />
- AccessChk<br />
- Autoruns<br />
- Handle<br />
- RootkitRevealer<br />
- WinObj</p>
<p>4) Debuggers</p>
<p>* Microsoft Debugging tools for Windows<br />
* OllyDbg<br />
* PEBrowse Pro<br />
* PEBrowse Debugger</p>
<p>5) Web attack tools<br />
* SQL Power Injector<br />
* GnuCitizen AttackAPI - XSS attack toolkit<br />
* WinHTTrack<br />
* Brutus<br />
* Nikto</p>
<p>6) .Net tools<br />
* Reflector<br />
* Fiddler - Web Proxy<br />
* CLRProfiler 2.0<br />
* FxCop<br />
* Managed SPY - .Net manipulation Tool (for local .Net processes)<br />
* NProf - .Net Profiler<br />
* WoanWare tools (from www.woany.co.uk):<br />
- Requester<br />
- HttpCodeGen<br />
- Encoder<br />
- HttpLibrary<br />
* Enterprise Library<br />
* WSE 3.0</p>
<p>7) Browser extensions<br />
* Sleuth (Evaluation) - Has a great IE browser plug-in that allows the direct editing of Web  pages<br />
* for IE<br />
- IE Dev Toolbar<br />
- Tamper IE<br />
- WoanWare Quick&#8217;n'Dirty<br />
* for Firefox<br />
- Tamper Data<br />
- Add N Edit Cookies<br />
- WebDeveloper<br />
- Switch Proxy<br />
- Header Monitor<br />
- LiveHttp Headers<br />
- JavaScript Debugger<br />
- View Source Chart<br />
- IE View</p>
<p>8 ) Foundstone tools<br />
* Hacme Bank<br />
* Validator .Net<br />
* Code Scout<br />
* CookieDiger<br />
* dotNetMon - tool trace .Net methods in real time<br />
* SiteDigger<br />
* WSDigger</p>
<p>9) Web Applications</p>
<p>* Community Server<br />
* DNN<br />
* ASPNuke</p>
<p>10) Additional material (I usually put this on a separate folder called &#8216;Additional .Net tools&#8217;</p>
<p>[.]                                                           [GotDotNet Win32Security]<br />
[..]                                                      [LogParser]<br />
[2.0 Membership Provider]                          [MS Solution for Windows-based Hosting version 3.0]<br />
Absinthe-1.4.1-Source.tar.gz                       [NET Profiling API material]<br />
Absinthe-1.4.1-Windows.zip                        [Nunit]<br />
[ASP.NET user authentication]                    [Partially Trusted Material]<br />
[ASPNET WatchDog]                                   [Strong Naming]<br />
[ASPNET windows authentication]             [Using PersonalizationStarter (2.0)]<br />
[CLR SPY]                                                 [SharpDevelop]<br />
[DotNet Hook Library 2.1]                            [Snippet Compiler (C# Development Environment)]<br />
[Encryption and Key Management]             [_XSD Object Generator]<br />
[GotDotNet RoleBasedSecurityExample]</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/26/lists-of-tools-for-vmware-box/feed/</wfw:commentRss>
		</item>
		<item>
		<title>DNS Pinning</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/09/dns-pinning/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/09/dns-pinning/#comments</comments>
		<pubDate>Fri, 09 Mar 2007 08:45:35 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/09/dns-pinning/</guid>
		<description><![CDATA[As described here:

Practical Anti-DNS Pinning Writeup
Circumventing DNS Pinning for XSS
(somewhat) breaking the same-origin policy by undermining dns-pinning
http://t3.dotgnu.info/blog/insecurity/dns-pinning-explored.html

This looks to me to be a much bigger problem that is seems (and is being acknowleged).
Basically to exploit DSN Pinning &#8216;all&#8217; the attacker needs to do is to:
1) get the victim to open a page from www.atacker.com (the [...]]]></description>
			<content:encoded><![CDATA[<p>As described here:</p>
<ul>
<li><a href="http://ha.ckers.org/blog/20070308/practical-anti-dns-pinning-writeup/" rel="bookmark" title="Practical Anti-DNS Pinning Writeup">Practical Anti-DNS Pinning Writeup</a></li>
<li><a href="http://ha.ckers.org/blog/20060815/circumventing-dns-pinning-for-xss/" rel="bookmark" title="Circumventing DNS Pinning for XSS">Circumventing DNS Pinning for XSS</a></li>
<li><a href="http://www.securityfocus.com/archive/1/443209/30/0/threaded">(somewhat) breaking the same-origin policy by undermining dns-pinning</a></li>
<li><a href="http://t3.dotgnu.info/blog/insecurity/dns-pinning-explored.html">http://t3.dotgnu.info/blog/insecurity/dns-pinning-explored.html</a></li>
</ul>
<p>This looks to me to be a much bigger problem that is seems (and is being acknowleged).</p>
<p>Basically to exploit DSN Pinning &#8216;all&#8217; the attacker needs to do is to:</p>
<p>1) get the victim to open a page from www.atacker.com (the www.atacker.com DNS will give out two IPs: the first will be the real www.atacker.com IP and the 2nd will be the IP of the www.targetwebsite.com (which could be internal))</p>
<p>2) the attacker drops the www.atacker.com server (dinamic firewall rule or other) so that the victim&#8217;s browser will clear that DNS entry</p>
<p>3) the script loaded in the victim&#8217;s browser opens another page from www.atacker.com/target.html which will now be fetched not from www.atacker.com but from the IP of www.targetwebsite.com (and having access to it&#8217;s contents since from the browser point of view it is still the same website/DNS name).</p>
<p>As with CSRF, this means that most websites out there are vulnerable.</p>
<p>I actually want to do a bit more research on this since this is sounding too bad to be true. Hopefully there will be some variations that will reduce the exploitability (one for example will be that this will not work if the server is doing virtual DNS name mappings and doesn&#8217;t accept direct IP requests or requests from other domains)</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/09/dns-pinning/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Roadmap to a Partial Trust Managed Code world</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/05/roadmap-to-a-partial-trust-managed-code-world/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/05/roadmap-to-a-partial-trust-managed-code-world/#comments</comments>
		<pubDate>Mon, 05 Mar 2007 23:41:54 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/05/roadmap-to-a-partial-trust-managed-code-world/</guid>
		<description><![CDATA[Following my &#8216;On Microsoftâ€™s lack of Partial Trust Managed Code (PTMC) focus and ideas for the future&#8216; and â€˜Security Awareness Modesâ€™ &#38; the â€˜day Microsoft changes which defend (and give ideas for) the need to go to a Partial Trust Managed world, here is an interesting &#8216;big vision&#8217; table:


Code Execution Location
Today
2011
2015/2020


Kernel (Unmanaged &#38; Managed Full [...]]]></description>
			<content:encoded><![CDATA[<p>Following my &#8216;<a href="http://blogs.owasp.org/diniscruz/2007/03/05/on-microsofts-lack-of-partial-trust-managed-code-ptmc-focus-and-ideas-for-the-future/" rel="bookmark" title="Permanent Link to On Microsoftâ€™s lack of Partial Trust Managed Code (PTMC) focus and ideas for the future">On Microsoftâ€™s lack of Partial Trust Managed Code (PTMC) focus and ideas for the future</a>&#8216; and <a href="http://blogs.owasp.org/diniscruz/2007/03/05/security-awareness-modes-the-day-microsoft-changes/" rel="bookmark" title="Permanent Link to â€˜Security Awareness Modesâ€™ &amp; the â€˜day Microsoft changesâ€™">â€˜Security Awareness Modesâ€™ &amp; the â€˜day Microsoft changes</a> which defend (and give ideas for) the need to go to a Partial Trust Managed world, here is an interesting &#8216;big vision&#8217; table:</p>
<table width="100%">
<tr>
<td><strong>Code Execution Location</strong></td>
<td><strong>Today</strong></td>
<td><strong>2011</strong></td>
<td><strong>2015/2020</strong></td>
</tr>
<tr>
<td><strong>Kernel </strong>(Unmanaged &amp; Managed Full Trust)</td>
<td>10%</td>
<td>9.5%</td>
<td>1%</td>
</tr>
<tr>
<td><strong>Kernel </strong>(Partial Trust Managed Code)</td>
<td>0%</td>
<td>0.5%</td>
<td>9%</td>
</tr>
<tr>
<td><strong>Admin/System code </strong>(Unmanaged &amp; Managed Full Trust)</td>
<td>30%</td>
<td>25%</td>
<td>1%</td>
</tr>
<tr>
<td><strong>Admin/System code</strong> (Partial Trust Managed Code)</td>
<td>0%</td>
<td>5%</td>
<td>19%</td>
</tr>
<tr>
<td><strong>User-land code</strong> (Unmanaged &amp; Managed Full Trust)</td>
<td>59%</td>
<td>20%</td>
<td>1%</td>
</tr>
<tr>
<td><strong>User-land code</strong> (Partial Trust Managed Code)</td>
<td>1%</td>
<td>20%</td>
<td>29%</td>
</tr>
<tr>
<td><strong>Virtual PC environments</strong></td>
<td>0%</td>
<td>20%</td>
<td>40%</td>
</tr>
</table>
<p>So the logic here is that by 2011 there as been a clear and hard move to to execute non-kernel code in Partial Trust Managed  Code environments (note that I group Full Trust with unmanaged code) together with the use of VPCs (or VMware) to execute certain type of applications which don&#8217;t need direct access to the user&#8217;s assets (for example games)</p>
<p>And that by 2015/2020, the conversion is made and most of the code executed is Partial Trust Managed Code. The issue will then be the security of that 1% of unmanaged &amp; Full Trust code, and the CAS policies that control the rest of the code (and that will be a job for the security companies).</p>
<p>The good news is that altough we will probably still need some types of AV,IDS, HPS (or whatever they will call themselves at the time), in this managed and verifiable world these tools will actually have a chance to detect and contain malicious behaviour / activities.</p>
<p>The reason I am moving a lot of code into the Virtual PC world is because I was looking at some of the use-cases of the software that it is used everyday, and there are large types of applications which only need &#8220;hardware + OS resources&#8221; to run (games are the best example), and don&#8217;t need any (or very limited) access to user&#8217;s assets. So in those cases it makes sense to run those apps in virtual pc environments,  and here think &#8216;Citrix Application Virtualization&#8217; ( <a href="http://www.citrix.com/English/ps2/products/product.asp?contentID=186">http://www.citrix.com/English/ps2/products/product.asp?contentID=186</a>) and not &#8216;VMWare&#8217; (note that those applications don&#8217;t need an entire OS, they only should need the hardware, the kernel, the win32 APIs and a couple of supporting services).</p>
<p>Ideally that &#8216;bridge&#8217; between the Virtual PC environment and the user assets would be implemented via a PTMC (Partial Trust Managed Code) application which would then envorce CAS rules to user&#8217;s assets accesses</p>
<p>Even I with my focus on PTMC application I know that PTMC games will NOT happen anytime soon, and since most games NEED almost full access to the user&#8217;s hardware (and admin/system access) there is NO way they will be written in user-land PTMC (on that note, we might want to make some changes in our hardware access so that code running under admin / system inside one of those VMs can  NOT rootkit my network card by patching it&#8217;s flash memory.</p>
<p>So I think that with time we will find that large parts of the apps we run everyday are executed inside this &#8217;sandboxed&#8217; OS environments.</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p>Final comment, don&#8217;t agree with this ideas? no problem, show me your solution?</p>
<p>Vista, XP  (and soon) Mac OSX /Linux clearly shown the limitations of trying to control and sandbox unmanaged code (oh, I forgot UAC is not a security feature anymore!).</p>
<p>So what is the plan to secure the user&#8217;s assets in 2,5, 10 years from now?&#8221;</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/05/roadmap-to-a-partial-trust-managed-code-world/feed/</wfw:commentRss>
		</item>
		<item>
		<title>&#8216;Security Awareness Modes&#8217; &#38; the &#8216;day Microsoft changes&#8217;</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/05/security-awareness-modes-the-day-microsoft-changes/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/05/security-awareness-modes-the-day-microsoft-changes/#comments</comments>
		<pubDate>Mon, 05 Mar 2007 22:54:54 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/05/security-awareness-modes-the-day-microsoft-changes/</guid>
		<description><![CDATA[While analyzing the different responses and attitudes that companies have in relationship with security, I came up with the following 4 Awareness Modes which I am now calling the &#8216;Security Awareness Modes&#8217;

&#8216;Awareness Mode 1) Blissful ignorance&#8217; - When companies have no idea of their vulnerabilities. This changes when they are attacked or pay for a [...]]]></description>
			<content:encoded><![CDATA[<p>While analyzing the different responses and attitudes that companies have in relationship with security, I came up with the following 4 Awareness Modes which I am now calling the &#8216;Security Awareness Modes&#8217;</p>
<ul>
<li><strong>&#8216;Awareness Mode 1) Blissful ignorance&#8217;</strong> - When companies have no idea of their vulnerabilities. This changes when they are attacked or pay for a competent and thorough security penetration test</li>
<li><strong>&#8216;Awareness Mode 2) The Patching Dance&#8217;</strong> - When companies know where the problems are, and issue regular patches to solve them (this mode usually contains a healthy security full-discosure market)</li>
<li><strong>&#8216;Awareness Mode 3) The SDL Dream&#8217; </strong>- After a while in mode 2, companies start to fall for the dream that &#8216;we can detect, solve or greatly reduce these issues using a strong, security focused SDL&#8217;</li>
<li><strong>&#8216;Awareness Mode 4) The Alignment&#8217; </strong>- Once the limitations of Mode 3 are apparent (and correctly diagnosed) the companies realize that the only &#8216;real&#8217; solution is to change their business model (</li>
</ul>
<p>Microsoft is currently in Mode 3 with its 2007 releases (Vista, Office, Sharepoint, etc&#8230;) and on Mode 2 with its other OSes (and products) and Mode 1 with its online services.</p>
<p>The day the following happens, will be the day that Microsoft is aligning its business model to its security requirements:</p>
<ul>
<li>De-coupling of OS and it&#8217;s current bundled applications (i.e. stop selling Megalomaniac Operation Systems, and start selling each major component separately (Kernel, windows GUI, User Applications, IE, IIS, etc&#8230;.)</li>
<li>De-coupling of the .NET framework and its core components</li>
<li>Focus on Managed/Verifiable code (creating the &#8216;Brand&#8217; that will make clients recognize such products)</li>
<li>Really embracing Open Standards and stopping &#8216;lock-in predatorial behaviour&#8217;</li>
<li>Running online services under partial trust (making their clients aware of it, and tying its SLA to it)</li>
</ul>
<p>Note that moving software in-house to provide it as a service (as google will soon find out) is not something that has less security requirements than a normal &#8216;desktop/server packaged applications&#8217;, it has MORE security requirements since its security exploitation will affect ALL customers (i.e. in a &#8217;software by service&#8217; mode, Awareness Mode 4 is even more important)</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/05/security-awareness-modes-the-day-microsoft-changes/feed/</wfw:commentRss>
		</item>
		<item>
		<title>On Microsoft&#8217;s lack of Partial Trust Managed Code (PTMC) focus and ideas for the future</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/05/on-microsofts-lack-of-partial-trust-managed-code-ptmc-focus-and-ideas-for-the-future/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/05/on-microsofts-lack-of-partial-trust-managed-code-ptmc-focus-and-ideas-for-the-future/#comments</comments>
		<pubDate>Mon, 05 Mar 2007 22:49:40 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/05/on-microsofts-lack-of-partial-trust-managed-code-ptmc-focus-and-ideas-for-the-future/</guid>
		<description><![CDATA[This post is a variation of an email that I sent before I had a meeting last Friday (2nd March 2007) with 4 senior technical Microsoft employees (two from the .NET Security side and two from the office security team)
As with all my previous meetings/lunches with Microsoft employees, it was an interesting intellectual discussion but [...]]]></description>
			<content:encoded><![CDATA[<p>This post is a variation of an email that I sent before I had a meeting last Friday (2nd March 2007) with 4 senior technical Microsoft employees (two from the .NET Security side and two from the office security team)</p>
<p>As with all my previous meetings/lunches with Microsoft employees, it was an interesting intellectual discussion but with no tangible results or actionable actions since they (and Microsoft) are currently  not focused on this problem (or don&#8217;t think that Partial Trust Managed Code is a valid solution). I also think that I need to speak with their bosses, but unfortunately their bosses are not talking to me.<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p>There are numerous reasons that explain the current lack of focus (and faith) by Microsoft (and others) on Partial Trust Managed Code (PTMC), the main ones being:</p>
<ul>
<li>the lack of attacks to Full Trust environments (think of all those ISPs selling Full Trust <a href="http://asp.net/">ASP.NET</a> accounts which are trivial to exploit and 0wn)</li>
<li>the failure by Microsoft&#8217;s .NET team to implement certain types of applications and OS components in Partial Trust Managed Code (you can just hear the C++ crowd saying <em>&#8220;man those guys can&#8217;t even do it in Full Trust!!!&#8221;</em>)</li>
<li>the non existent of public attacks that exploit the fact that our &#8220;main security defence method is the reliance of the non execution of malicious code in our environments&#8221; (this would had changed if WinZip, Flash or Adobe (for example) had been infected with malicious code that was successfully exploited in a spectacular and public way)</li>
<li>(from Microsoft&#8217;s point of view) the fact that it&#8217;s main competitors are also in denial and not going in that direction</li>
</ul>
<p>To solve it, changes will need to occur in multiple areas (and will need to address them all in order to have a real solution)</p>
<ul>
<li><strong> Technological</strong></li>
<li><strong>Political</strong></li>
<li><strong>Strategical</strong></li>
<li><strong>Economical</strong></li>
<li><strong>Social</strong></li>
<li><strong>Educational</strong></li>
</ul>
<p><strong>Technological</strong></p>
<p>We need better tools to write Partial Trust Managed Code (PTMC), manage its environment and prevent/detect/stop malicious code. For example:</p>
<ul>
<li><strong>Dynamically calculate required CAS permissions </strong>(don&#8217;t get me started on PermCalc)</li>
<li><strong>Refactor code that requires higher permissions into separate assemblies </strong>(so that only 1% of the code will need to run outside the Sandbox)</li>
<li><strong>Converters of unmanaged code to managed code</strong> (i.e. C++ to C#, VB6 to VB.Net, etc&#8230;)</li>
<li>Source code audit tools that identify vulnerabilities or areas that might have vulnerabilities</li>
<li><strong>&#8220;.Net Time-machine (ala Flight Recorder)&#8221; </strong>- ability to record the entire state of all objects during a .Net Execution and allow the execution, debugging and fuzzing from any arbitrary point (see Java&#8217;s  <a href="http://www.research.ibm.com/dejavu/">DeJaVu </a>and <a href="http://www3.interscience.wiley.com/cgi-bin/abstract/107615962/ABSTRACT?CRETRY=1&amp;SRETRY=0">  JaRec </a>Projects (I remember seeing another PoC of this type of tool, but can&#8217;t seem to be able to find the link))</li>
<li><strong>Smart fuzzers </strong>(to find run-time vulnerabilities)</li>
<li>&#8216;Security rating calculators&#8217; which will give a product (or dll) a rating based on the &#8216;threat profile of that application&#8217; (for example the more unmanaged code, the worse rating) . This will be a very important part of the &#8216;Partial Trust Brand&#8217;</li>
<li><strong>Development environments that allow the development of complex and feature rich partial Trust applications  </strong>like IE in managed code</li>
<li><strong>New execution environments (aka mini CLRs) t</strong>hat allow the execution of Managed/Verifiable code in : Services, Drivers, plug-ins etc&#8230;</li>
<li><strong>New Virtual PC Execution environments that allow the safe execution of &#8216;potential malicious applications&#8217; </strong>whose interface with the user&#8217;s assets are controlled by a managed/verifiable application (and CAS policies)</li>
<li> <strong>&#8216;What is going on&#8217; tools. </strong>When I run an application I need to know EVERYTHING it does. And if the application somehow escapes the &#8216;execution monitoring system&#8217; I want to know that it did. Now that Microsoft bought SysInternals, can we have a massive boast on those tools capabilities?. This tools must also build CAS polices based on what they detected the target application needs.</li>
<li><strong>Tools that allow the easy development and use of CAS and RBS  (Role Base Security) and frameworks for securing an application&#8217;s Business-Logic </strong>(for example using a CAS to prevent the user account&#8217;s from being changed, or an bank account from being accessed)</li>
<li><strong>Code Coverage Tools </strong>- To know how much of an application has been tested, fuzzed or executed</li>
<li><strong>   &#8216;Real time Hot Patching of Jitted methods </strong>(without using the .NET profiler)&#8217; - For advanced defence solutions we will need the capability to make changes to jitted code (i.e   . writing patches in C#)</li>
<li>For <strong>ASP.NET</strong> we need:
<ul>
<li><strong>WAF  (Web Application Firewalls) </strong>with pluggable modules for: Data Validation, Authentication, Authorization, Anti-CSRF, DoS, Business-Logic vulnerabilities, etc&#8230;</li>
<li><strong>A framework similar to Struts </strong>(which force the developers to do the right thing (i.e. explicitly define all inputs into their application)</li>
<li><strong>IDS (Intrusion Detection Systems) </strong>with the capability to change the application&#8217;s behaviour when under attack</li>
<li><strong>Native Http Pipeline for IIS 5 and 6 </strong>(similar to what seems that will happen in IIS 7)
<ul>
<li>This will be very important to protect ASP Classic pages . I know several companies that are trying to implement such modules, and they will not have the resources and knowledge to implement a comprehensive and secure solution</li>
</ul>
</li>
<li><strong>CAS demands for dangerous methods </strong>(for example methods and classes that allow SQL Injections, XSS, etc&#8230;)
<ul>
<li>The current CAS permission&#8217;s model is designed to protect the server and the other co-hosted applications. This needs to be extended so that CAS can be used to protect the actual application from vulnerabilities in its code</li>
</ul>
</li>
<li><strong>CAS demands for methods or code that &#8217;should&#8217; exist </strong>(for example data valiation checks, authorization, etc&#8230;.)</li>
</ul>
</li>
</ul>
<p>We also need to normalize the windows security features into a common framework. I would propose that we used the current CAS model for all security related decisions and configurations (for example using CAS to define: Windows ACLs, Firewall rules, UAC settings, etc..).  But for this to be practical, CAS (and all it&#8217;s pluming) should be removed from the .NET Framework&#8217;s BLOB and be implemented as a separate, de-coupled module</p>
<p><strong>Political</strong></p>
<p>Microsoft needs to come out loud and clear and say <strong>&#8216;Managed Verifiable code is the way to go, and we all (MS and its community) need to go that way&#8217;</strong></p>
<p>The fact that Sun, Apple, Google and the Linux crowd are not doing this should not be seen as an excuse but it should be seen as an opportunity.</p>
<p>We need a <strong>&#8216;Towards a Managed and Verifiable world&#8217; </strong>memo (Ray are you listening?)</p>
<p><strong>Strategic</strong></p>
<p>Microsoft needs to change its core business model from selling massive highly-coupled applications (best examples are OSes the .NET Framework and the online web services: MSN, Live , etc..) and go to a model where each application and component is developed, executed and sold separately (note that online services need even MORE security than normal software packaged applications).</p>
<p>For this to work, Microsoft would need to &#8216;really&#8217; embrace open standards and multi-layer application models where each layer (or component) is 100% independent and the only communication channels between layers are simple, open and well documented.</p>
<p><strong>Economical</strong></p>
<p>It must make commercial sense to write managed/verifiable code  (in both Windows and <a href="http://asp.net/">ASP.NET</a> worlds). Which means that the paying clients that are purchasing software/applications/services MUST demand such code (and MUST reward the companies that write them)</p>
<p>It also must make commercial sense (and be realistic) for companies to provide &#8216;Application security verification services&#8217; . And this is a big opportunity for security vendors: &#8220;give me a service that checks and certifies applications and I will pay for it (as a monthly subscription).&#8221;</p>
<p><strong>Social</strong></p>
<p>We have to stop blaming the users for using our products the way they where supposed to be used. The current security model where the user is expected to make a major security decision on every prompt doesn&#8217;t work (and will not hold much longer).</p>
<p>It is not the User&#8217;s responsibility to restrict malicious code execution, it is the OS (and application audit security teams) responsibility.</p>
<p>Also remember that the browser is becoming the target, and for example:</p>
<ul>
<li>the users will not care if their OS (or kernel) is not compromized if they just lost their assets</li>
<li>   the attackers will not care if their exploit doesn&#8217;t survive a reboot if they are able to steal/exploit the user&#8217;s assets</li>
</ul>
<p><strong>Educational</strong></p>
<p>There will need to be a big push on how to program for Partial Trust environments, and there must be a special focus in teaching the Network and Infrastructure teams since they should be the ones that define the CAS policies (not the developers)</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/05/on-microsofts-lack-of-partial-trust-managed-code-ptmc-focus-and-ideas-for-the-future/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Software Security and Quality Blog</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/05/software-security-and-quality-blog/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/05/software-security-and-quality-blog/#comments</comments>
		<pubDate>Mon, 05 Mar 2007 22:36:44 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/05/software-security-and-quality-blog/</guid>
		<description><![CDATA[Cigital has recentely lauched http://www.cigital.com/justiceleague/ which so far has produced a good number of high quality and relevant posts (defenitely one for the blog roll)

Aspect-Oriented Service Architecture: â€œBuilt Inâ€? or â€œBolted Onâ€? Security?
I Hate to Admit It, but Those Network Guys Are Pretty Smart
Penetration Testing
Darn the SOX, We Need More Security Ahead
Keeping up with the [...]]]></description>
			<content:encoded><![CDATA[<p>Cigital has recentely lauched <a href="http://www.cigital.com/justiceleague/">http://www.cigital.com/justiceleague/</a> which so far has produced a good number of high quality and relevant posts (defenitely one for the blog roll)</p>
<ul>
<li><a href="http://www.cigital.com/justiceleague/2007/03/01/aspect-oriented-service-architecture-built-in-or-bolted-on-security/" title="Aspect-Oriented Service Architecture: â€œBuilt Inâ€? or â€œBolted Onâ€? Security?">Aspect-Oriented Service Architecture: â€œBuilt Inâ€? or â€œBolted Onâ€? Security?</a></li>
<li><a href="http://www.cigital.com/justiceleague/2007/02/28/i-hate-to-admit-it-but-those-network-guys-are-pretty-smart/" title="I Hate to Admit It, but Those Network Guys Are Pretty Smart">I Hate to Admit It, but Those Network Guys Are Pretty Smart</a></li>
<li><a href="http://www.cigital.com/justiceleague/2007/02/28/penetration-testing/" title="Penetration Testing">Penetration Testing</a></li>
<li><a href="http://www.cigital.com/justiceleague/2007/02/23/darn-the-sox-we-need-more-security-ahead/" title="Darn the SOX, We Need More Security Ahead">Darn the SOX, We Need More Security Ahead</a></li>
<li><a href="http://www.cigital.com/justiceleague/2007/02/22/keeping-up-with-the-jones-security-initiatives/" title="Keeping up with the Jonesâ€™ Security Initiatives">Keeping up with the Jonesâ€™ Security Initiatives</a></li>
<li><a href="http://www.cigital.com/justiceleague/2007/02/20/welcome/" title="Welcome">Welcome</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/05/software-security-and-quality-blog/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Simple Backdoor on WordPress</title>
		<link>http://blogs.owasp.org/diniscruz/2007/03/03/simple-backdoor-on-wordpress/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/03/03/simple-backdoor-on-wordpress/#comments</comments>
		<pubDate>Sat, 03 Mar 2007 21:36:44 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/03/03/simple-backdoor-on-wordpress/</guid>
		<description><![CDATA[The Wordpress development team has posted an announcement that the download server had been hacked, and wordpress 2.1.1 had a backdoor included in it allowing for remote code execution.URL: http://wordpress.org/development/2007/03/upgrade-212/Â 
[update: the exploit code is here: http://www.securityfocus.com/archive/1/461794/30/0/threadedÂ (how come I am still one of the few that think that we need Sandboxes?)]
nice, the business model is evolving.
But [...]]]></description>
			<content:encoded><![CDATA[<p><em>The Wordpress development team has posted an announcement that the download server had been hacked, and wordpress 2.1.1 had a backdoor included in it allowing for remote code execution.</em><em>URL: <a href="http://wordpress.org/development/2007/03/upgrade-212/"><font color="#0000cc"><em>http://wordpress.org/development/2007/03/upgrade-212/</em></font></a>Â </p>
<p></em>[update: the exploit code is here: <a href="http://www.securityfocus.com/archive/1/461794/30/0/threaded">http://www.securityfocus.com/archive/1/461794/30/0/threaded</a>Â (how come I am still one of the few that think that we need Sandboxes?)]</p>
<p>nice, the business model is evolving.</p>
<p>But this is still a very &#8216;inefficient&#8217; attack since:</p>
<p>Â Â </p>
<p>Â a) the final binaries were the ones infected (very easy to detect (imagine if the infected code was actuallyÂ from &#8216;real&#8217; SVN source code and made from a &#8216;trusted&#8217; developer))</p>
<p>Â b) by the speed this was detected the exploit (and the blog page didn&#8217;t give a lot of details about it) must have been a very &#8216;HEY I AM A BACKDOOR!!!!&#8217; kind of code.Â  A real exploit would be one that (using a .NET example)Â used a type confusion attack to insert a buffer overflow on a remotely accessible method (which would be inserted in day X and only used a couple months later).</p>
<p>but it&#8217;s evolving&#8230;..</p>
<p>Can everybody that writes code and has a Browser window open under the same user account (even if non admin) raise their hand? &#8230; nice so many hands (including mine)&#8230;. guess what, if your browser is 0wned, so will be your code..</p>
<p>And OWASP uses WordPress (although Mike tells me that we were not affected) for our blogs (<a href="http://blogs.owasp.org/"><font color="#0000cc">blogs.owasp.org</font></a>), nice <img src='http://blogs.owasp.org/diniscruz/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>I am still waiting for the day that we will be maliciously hackedÂ for commercial reasons since that will be another step in the evolution of the malicious guy&#8217;s business model</p>
<p>Dinis in San Jose</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/03/03/simple-backdoor-on-wordpress/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Sanboxes on OLPC and WMF, MAF</title>
		<link>http://blogs.owasp.org/diniscruz/2007/02/20/sanboxes-on-olpc-and-wmf-maf/</link>
		<comments>http://blogs.owasp.org/diniscruz/2007/02/20/sanboxes-on-olpc-and-wmf-maf/#comments</comments>
		<pubDate>Tue, 20 Feb 2007 23:17:29 +0000</pubDate>
		<dc:creator>diniscruz</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blogs.owasp.org/diniscruz/2007/02/20/sanboxes-on-olpc-and-wmf-maf/</guid>
		<description><![CDATA[From the One Laptop Per Child: Development site we have the Bitfrost platform specification &#8212; public release  which seems to be (haven&#8217;t read it all) an amazing description of the security measures implemented in this laptop. I really like their efforts in containing malicious code by limiting what it can do.
Here Windows Presentation Foundation [...]]]></description>
			<content:encoded><![CDATA[<p>From the <a href="http://dev.laptop.org/">One Laptop Per Child: Development site</a> we have the <a href="http://dev.laptop.org/git.do?p=security;a=commit;h=HEAD">Bitfrost platform specification &#8212; public release</a>  which seems to be (haven&#8217;t read it all) an amazing description of the security measures implemented in this laptop. I really like their efforts in containing malicious code by limiting what it can do.</p>
<p>Here <a href="http://msdn2.microsoft.com/en-us/library/aa480229(d=printer).aspx">Windows Presentation Foundation Security Sandbox </a>is a presentation on WPF partial trust enviroments, where it gives details on what (from the WPF) will work in Partial Trust and what will not.</p>
<ul>
<li>This is from Sep 2005 so it might be a bit out of date</li>
<li>I wonder how many real-world, usable and &#8216;buyable&#8217; apps we will see that will work in WPF Partial trust</li>
<li>There seemed to be a more in depth paper here <a href="http://winfx.msdn.microsoft.com/library/default.asp?url=/library/en-us/wcp_conceptual/html/c9c3d961-46db-4a9b-81da-c62da237f210.asp">Windows Presentation Foundation Security Whitepaper</a> but this document doesn&#8217;t seem to be online</li>
</ul>
<p>And on the subject of safely handling potential malicious adds, here is an interresting Framework (need to look more into it, has anybody used this stuff?) from MS<a href="http://blogs.msdn.com/jackg/archive/2005/09/15/468068.aspx"><br />
</a></p>
<ul>
<li><a href="http://blogs.msdn.com/jackg/archive/2005/09/15/468068.aspx">MAF (Managed AddIn Framework)</a></li>
<li><a href="http://msdn.microsoft.com/msdnmag/issues/06/08/AddInPower/default.aspx">Let Users Customize Your Apps With Visual Studio Tools For Applications</a></li>
<li><a href="http://blogs.msdn.com/andreww/archive/2006/02/21/536179.aspx">VSTO Embraces MAF</a></li>
<li><a href="http://blogs.msdn.com/tq/archive/2006/12/05/vsta-and-generics.aspx">VSTA and Generics</a></li>
</ul>
<p>And on the Java camp here is an interresting tool: <a href="http://metal.hurlant.com/jexplore/">Java Explorer</a>  <em>A tool to easily explore the java sandbox from javascript, for the purpose of better understanding what java makes available to web applications nowadays.</em></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.owasp.org/diniscruz/2007/02/20/sanboxes-on-olpc-and-wmf-maf/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
