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

<channel>
	<title>Digicorp &#187; Software Development Lifecycle</title>
	<atom:link href="http://dev.digi-corp.com/category/software-development-lifecycle/feed/" rel="self" type="application/rss+xml" />
	<link>http://dev.digi-corp.com</link>
	<description>&#62;&#62; Developer Blog</description>
	<lastBuildDate>Wed, 22 Jun 2011 14:13:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>SQL Injection and Prevention of SQL Injection</title>
		<link>http://dev.digi-corp.com/2009/05/sql-injection-prevention-of-sql-injection/</link>
		<comments>http://dev.digi-corp.com/2009/05/sql-injection-prevention-of-sql-injection/#comments</comments>
		<pubDate>Wed, 06 May 2009 10:51:08 +0000</pubDate>
		<dc:creator>dhaval.shah</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[coverage]]></category>
		<category><![CDATA[Software Development Lifecycle]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[Prevent SQL Injection]]></category>
		<category><![CDATA[SQL Injection]]></category>

		<guid isPermaLink="false">http://dev.digi-corp.com/?p=162</guid>
		<description><![CDATA[What is SQL Injection? SQL injection is a technique that exploits a security vulnerability occurring in the database layer of an application. This vulnerability is present when user input is manipulated for string literal escape characters embedded in SQL statements or user input is not sufficiently filtered and thereby unexpectedly executed. How SQL Injection looks [...]]]></description>
			<content:encoded><![CDATA[<p style="margin-bottom: 13.7pt;"><strong><span style="text-decoration: underline;"><span style="font-family: Verdana; font-size: 10pt;">What is SQL  Injection?</span></span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">SQL injection  is a technique that exploits a security vulnerability occurring in the database  layer of an application. This vulnerability is present when user input is  manipulated for string literal escape characters embedded in SQL statements or  user input is not sufficiently filtered and thereby unexpectedly  executed.</span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="text-decoration: underline;"><span style="font-family: Verdana; font-size: 10pt;">How SQL Injection looks  like?</span></span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="font-family: Verdana; font-size: 10pt;">Basic SQL  Injections</span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">If anybody  want to pull up the records of particular user name from the user information  table and if “username” variable is set as</span></strong></p>
<p style="margin-bottom: 13.7pt; text-align: center;"><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">X<span style="color: #ff0000;">&#8216; OR &#8216;</span>Y<span style="color: #ff0000;">&#8216; = &#8216;</span>Y</span></p>
<p style="margin-bottom: 13.7pt; text-align: left;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">By inputting  the above code as user name , Let see how’s it work at back end?</span></strong></p>
<p style="margin-bottom: 13.7pt; text-align: center;"><span style="color: #0000ff;">SELECT </span><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">* <span style="color: #0000ff;">FROM </span>UserInformation <span style="color: #0000ff;">WHERE </span>UserName = <span style="color: #ff0000;">&#8216;</span></span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;"><span style="color: #ff0000;">X&#8217;</span> <span style="color: #0000ff;">OR</span><span style="color: #ff0000;"><span style="color: #0000ff;"> </span>&#8216;Y&#8217;</span> =<span style="color: #ff0000;"> &#8216;Y&#8217;</span></span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">If we use  this type of code were in an authentication procedure then this example could be  used to force the selection of a valid “username” because the evaluation of  &#8216;Y&#8217;='Y&#8217; is always true and you will be logged in as the user on top of the SQL  table.</span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Same way if  the “username” variable is set as</span></strong></p>
<p style="margin-bottom: 13.7pt; text-align: center;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">X<span style="color: #ff0000;">&#8216; OR 1 = 1 </span></span></strong><span style="color: #ff0000;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">–-</span></strong></span></p>
<p style="margin-bottom: 13.7pt; text-align: left;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">If we use  double dashes (–) than at the back end these dashes at the end tell the SQL  server to ignore the rest of the query. </span></strong></p>
<p style="margin-bottom: 13.7pt; text-align: center;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;"><span style="color: #0000ff;">SELECT </span>* <span style="color: #0000ff;">FROM </span>UserInformation <span style="color: #0000ff;">WHERE </span>UserName = <span style="color: #ff0000;">&#8216;</span></span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;"><span style="color: #ff0000;">X&#8217;</span> <span style="color: #0000ff;">OR </span>1 = 1 </span></strong><span style="color: #339966;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">–-</span></strong></span><span style="color: #339966;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">&#8216;</span></strong></span></p>
<p style="margin-bottom: 13.7pt; text-align: left;"><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Same way more  SQL Injection syntaxes are:</span></strong></p>
<p style="margin-bottom: 13.7pt; text-align: left;"><!--[if gte mso 9]&gt;  Normal 0   false false false        MicrosoftInternetExplorer4  &lt;![endif]--><!--[if gte mso 9]&gt;   &lt;![endif]--> <!--[if gte mso 10]&gt;--> <!--[endif]--></p>
<p style="margin-bottom: 13.7pt; padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">‘) OR (‘1’ = ‘1</span></strong></p>
<p style="margin-bottom: 13.7pt; padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">‘ OR ‘1’ = ‘1</span></strong></p>
<p style="margin-bottom: 13.7pt; padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">‘ OR 1 = 1</span></strong></p>
<p style="margin-bottom: 13.7pt; padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">“ OR “1”= “1</span></strong></p>
<p class="MsoNormal" style="padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">“ OR 1 = 1 –-</span></strong></p>
<p class="MsoNormal"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;"> </span></strong></p>
<p class="MsoNormal" style="padding-left: 30px;"><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">OR 1 = 1 </span></strong><strong><span style="font-size: 10pt; font-family: Verdana; font-weight: normal;">–-</span></strong></p>
<p style="margin-bottom: 13.7pt;"><strong><span style="text-decoration: underline;"><span style="font-family: Verdana; font-size: 10pt;">How can we get free from SQL  Injection?</span></span></strong></p>
<ul>
<li><strong><span style="font-family: Verdana; font-size: 10pt;">Validate all  input</span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;"> before using  it.</span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">We can  validate the input by this way.</span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Reject the  input that contains the following characters:</span></strong></li>
</ul>
<p style="margin: 5pt 0in 13.7pt 2.5in; text-indent: -0.25in;"><strong><span style="font-family: Wingdings; font-size: 10pt;">1. </span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Single  Quote(&#8216;)</span></strong></p>
<p style="margin: 5pt 0in 13.7pt 2.5in; text-indent: -0.25in;"><strong></strong><strong><span style="font-family: Wingdings; font-size: 10pt;">2. <span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Dash ( &#8211;  )</span></strong></p>
<p style="margin: 5pt 0in 13.7pt 2.5in; text-indent: -0.25in;"><strong><span style="font-family: Wingdings; font-size: 10pt;">3. <span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">/* and  */</span></strong></p>
<p style="margin: 5pt 0in 13.7pt 2.5in; text-indent: -0.25in;"><span style="font-family: Wingdings; font-size: 10pt;"><strong>4. </strong><span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Semicolon ( ;  )</span></strong></p>
<ul>
<li><span style="font-family: Symbol; font-size: 10pt;"><span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span><strong><span style="font-family: Verdana; font-size: 10pt;">User parameterized input with  stored procedures:</span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;"> Stored  procedures may be susceptible to SQL injection if they use unfiltered input. So  all the input provided to the stored Procedures is provided in the form of  parameters</span></strong></li>
</ul>
<ul>
<li><strong><span style="font-family: Symbol; font-size: 10pt; font-weight: normal;"><span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span></strong><strong><span style="font-family: Verdana; font-size: 10pt;">Filtering input: </span></strong><strong><span style="font-family: Verdana; font-size: 10pt; font-weight: normal;">Replace a  Single Quote (‘) with two Single Quotes (‘’) to filter the  input.</span></strong></li>
</ul>
<ul>
<li><strong><span style="font-family: Verdana; font-size: 10pt;">Limit the database permission: </span></strong><span style="font-family: Verdana; font-size: 10pt;">Use a  limited access account to connect to the database</span></li>
</ul>
<ul>
<li><strong><span style="font-family: Verdana; font-size: 10pt;">Don’t store secrets in plain text: </span></strong><span style="font-family: Verdana; font-size: 10pt;">Encrypt or  hash passwords and other sensitive data; you should also encrypt connection  strings </span></li>
</ul>
<ul>
<li><span style="font-family: Symbol; font-size: 10pt;"><span style="font-family: 'Times New Roman'; font-style: normal; font-variant: normal; font-weight: normal; font-size: 7pt; line-height: normal; font-size-adjust: none; font-stretch: normal; -x-system-font: none;"> </span></span><strong><span style="font-family: Verdana; font-size: 10pt;">Exceptions should divulge minimal  information: </span></strong><span style="font-family: Verdana; font-size: 10pt;">Don&#8217;t expose too much information  in error messages; display minimal information in the event of error  handling.</span></li>
</ul>
<p><span style="font-family: Verdana; font-size: 10pt;">Reference : </span><!--[if gte mso 9]&gt;  Normal 0   false false false        MicrosoftInternetExplorer4  &lt;![endif]--><!--[if gte mso 9]&gt;   &lt;![endif]--> <!--[endif]--></p>
<p style="margin-bottom: 0.0001pt;"><a href="http://en.wikipedia.org/wiki/SQL_injection">http://en.wikipedia.org/wiki/SQL_injection</a></p>
<p style="margin-bottom: 0.0001pt;"><!--[if gte mso 9]&gt;  Normal 0   false false false        MicrosoftInternetExplorer4  &lt;![endif]--><!--[if gte mso 9]&gt;   &lt;![endif]--> <!--[endif]--></p>
<p style="margin-bottom: 0.0001pt;"><a href="http://www.secureworks.com/research/articles/sql-injection-attacks">http://www.secureworks.com/research/articles/sql-injection-attacks</a></p>
<p style="margin: 5pt 0in 13.7pt 0.5in; text-indent: -0.25in; text-align: left;"> </p>
]]></content:encoded>
			<wfw:commentRss>http://dev.digi-corp.com/2009/05/sql-injection-prevention-of-sql-injection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Full-text searching with MySQL</title>
		<link>http://dev.digi-corp.com/2009/02/full-text-searching-with-mysql/</link>
		<comments>http://dev.digi-corp.com/2009/02/full-text-searching-with-mysql/#comments</comments>
		<pubDate>Mon, 16 Feb 2009 07:28:49 +0000</pubDate>
		<dc:creator>Nilesh</dc:creator>
				<category><![CDATA[Software Development Lifecycle]]></category>
		<category><![CDATA[easy to use]]></category>
		<category><![CDATA[full-text]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[search optimization]]></category>

		<guid isPermaLink="false">http://dev.digi-corp.com/?p=36</guid>
		<description><![CDATA[MySQL full text seach , how to and basic understanding]]></description>
			<content:encoded><![CDATA[<p>MySQL’s full-text search functions provide a simple framework for an easily implemented, approximate site search. web-applications or desktop applications, written in an interpreted language and powered by MySQL, can use MySQL’s full-text search to avoid third party dependencies.</p>
<h4>The basics</h4>
<p>The basics of the MySQL full-text search functions are <a href="http://dev.mysql.com/doc/refman/5.0/en/fulltext-search.html">well-documented</a> in the MySQL online documentation.  For those lacking patience, here is a quick rundown.</p>
<p>Full-text searching is somewhat akin to a <code>LIKE</code> condition, but is much faster, requiring a <code>FULLTEXT</code> index to be created for the table columns targeted in the search.  To search the <code>title</code> and <code>description</code> columns of a table, <code>entries</code>, the following statement would create the proper index:</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;"><span style="color: #993333; font-weight: bold;">ALTER</span> <span style="color: #993333; font-weight: bold;">TABLE</span> entries <span style="color: #993333; font-weight: bold;">ADD</span> FULLTEXT<span style="color: #66cc66;">(</span>title<span style="color: #66cc66;">,</span> description<span style="color: #66cc66;">)</span></pre>
</div>
</div>
<p>To search these columns for the text, “python threading,” the <code>MATCH...AGAINST</code> functions are used:</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;"><span style="color: #993333; font-weight: bold;">SELECT</span> id<span style="color: #66cc66;">,</span> MATCH<span style="color: #66cc66;">(</span>title<span style="color: #66cc66;">,</span> description<span style="color: #66cc66;">)</span> AGAINST <span style="color: #66cc66;">(</span><span style="color: #ff0000;">'python threading'</span><span style="color: #66cc66;">)</span> <span style="color: #993333; font-weight: bold;">AS</span> score
<span style="color: #993333; font-weight: bold;">FROM</span> entries
<span style="color: #993333; font-weight: bold;">ORDER</span> <span style="color: #993333; font-weight: bold;">BY</span> score <span style="color: #993333; font-weight: bold;">DESC</span></pre>
</div>
</div>
<p>Notice that we keep the result of the match. The value returned is a float representing the relevance of the match. The higher the number, the more relevant the match.</p>
<p>There are several caveats to the full-text search. In particular, any words that are common between many entries are treated as noise and their relevance in any search is diminished. This means that were every article in <code>entries</code> to be about threading in Python, searching for “python threading” may not return extremely relevant results.  Refer to the <a href="http://dev.mysql.com/doc/refman/5.0/en/fulltext-search.html">MySQL</a> docs for more information.</p>
<h4>The hard part</h4>
<p>If the content to be searched is not conveniently located in one table, things get more complex. In this case, a method must be devised to create an intermediary table to contain the search target.</p>
<p>This might be accomplished with a cron script that aggregates the information nightly or using stored procedures to keep the target table updated.</p>
<h4>Refining results</h4>
<p>A common case is to weight the search to favor more recent results.  Assuming that each entry has a <code>DATETIME</code> field named <code>timestamp</code>, this is easily accomplished by using the entry’s age to modify the score.</p>
<p>For an even reduction to the score based on the article’s age, divide the score by the age, which is determined with <code>DATEDIFF(NOW(), timestamp)</code>.</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;"><span style="color: #66cc66;">(</span>MATCH<span style="color: #66cc66;">(</span>title<span style="color: #66cc66;">,</span> description<span style="color: #66cc66;">)</span> AGAINST <span style="color: #66cc66;">(</span><span style="color: #ff0000;">'python threading'</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">/</span>GREATEST<span style="color: #66cc66;">(</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">,</span> DATEDIFF<span style="color: #66cc66;">(</span>NOW<span style="color: #66cc66;">(</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">,</span> timestamp<span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span></pre>
</div>
</div>
<p>Since <code>DATEDIFF</code> returns the difference in days, an entry written today could cause division by zero.<br />
<code>GREATEST</code> means that entries written today and yesterday have equal weight, but prevents results from omitting today’s articles.</p>
<p>A quick test of this will show that results become wildly incorrect after a few days as the text match score begins to diminish further with age. This effect can be reduced by taking the <code>LOG</code> of the age, making the divisor increase less and less the greater the age.</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;">LOG<span style="color: #66cc66;">(</span>GREATEST<span style="color: #66cc66;">(</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">,</span> DATEDIFF<span style="color: #66cc66;">(</span>NOW<span style="color: #66cc66;">(</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">,</span> timestamp<span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span></pre>
</div>
</div>
<p>The use of <code>LOG</code> causes a steep drop initially, smothing over time. For a less dramatic effect, substituting the square root causes a similar drop in the weight of the entry’s age over time, but diminishing less starkly over time and without the initial steep drop.</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;">SQRT<span style="color: #66cc66;">(</span>GREATEST<span style="color: #66cc66;">(</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">,</span> DATEDIFF<span style="color: #66cc66;">(</span>NOW<span style="color: #66cc66;">(</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">,</span> timestamp<span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span></pre>
</div>
</div>
<p>The complete SQL statement is now:</p>
<div class="wp_syntax">
<div class="code">
<pre style="font-family: monospace;"><span style="color: #993333; font-weight: bold;">SELECT</span> id<span style="color: #66cc66;">,</span>
  <span style="color: #66cc66;">(</span>MATCH<span style="color: #66cc66;">(</span>title<span style="color: #66cc66;">,</span> description<span style="color: #66cc66;">)</span> AGAINST <span style="color: #66cc66;">(</span><span style="color: #ff0000;">'python threading'</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">/</span>SQRT<span style="color: #66cc66;">(</span>GREATEST<span style="color: #66cc66;">(</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">,</span> DATEDIFF<span style="color: #66cc66;">(</span>NOW<span style="color: #66cc66;">(</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">,</span> timestamp<span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span><span style="color: #66cc66;">)</span>
  <span style="color: #993333; font-weight: bold;">AS</span> score
<span style="color: #993333; font-weight: bold;">FROM</span> entries
<span style="color: #993333; font-weight: bold;">ORDER</span> <span style="color: #993333; font-weight: bold;">BY</span> score <span style="color: #993333; font-weight: bold;">DESC</span></pre>
</div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://dev.digi-corp.com/2009/02/full-text-searching-with-mysql/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
		<item>
		<title>Code Inspection</title>
		<link>http://dev.digi-corp.com/2009/02/code-inspection/</link>
		<comments>http://dev.digi-corp.com/2009/02/code-inspection/#comments</comments>
		<pubDate>Sat, 14 Feb 2009 06:20:27 +0000</pubDate>
		<dc:creator>abhishek</dc:creator>
				<category><![CDATA[Software Development Lifecycle]]></category>
		<category><![CDATA[code review]]></category>
		<category><![CDATA[fagan inspection]]></category>

		<guid isPermaLink="false">http://dev.digi-corp.com/?p=31</guid>
		<description><![CDATA[At Digicorp, we have recently started code inspection process. It is too early to say that it is producing wonders but it does look promising in the long run.

We are inspired from the Fagan Inspection invented by Michael Fagan at IBM in 1970. We do not follow the process completely but we have done changes according our environment.]]></description>
			<content:encoded><![CDATA[<p>At Digicorp, we have recently started code inspection process. It is too early to say that it is producing wonders but it does look promising in the long run.</p>
<p>We are inspired from the <a href="http://en.wikipedia.org/wiki/Fagan_inspection" target="_blank">Fagan Inspection</a> invented by Michael Fagan at IBM in mid 1970s. We do not follow the process completely but we have done changes according our environment.</p>
<p>Following presentation will give you more idea about the process:</p>
<div id="__ss_997057" style="width: 425px; text-align: left;"><a style="font:14px Helvetica,Arial,Sans-serif;display:block;margin:12px 0 3px 0;text-decoration:underline;" title="Digicorp Code Inspection Process" href="http://www.slideshare.net/abhishek_desai/digicorp-code-inspection-process?type=presentation">Digicorp Code Inspection Process</a><object width="425" height="355" data="http://static.slideshare.net/swf/ssplayer2.swf?doc=digicorp-code-inspection-process-1233922523845425-2&amp;stripped_title=digicorp-code-inspection-process" type="application/x-shockwave-flash"><param name="allowFullScreen" value="true" /><param name="allowScriptAccess" value="always" /><param name="src" value="http://static.slideshare.net/swf/ssplayer2.swf?doc=digicorp-code-inspection-process-1233922523845425-2&amp;stripped_title=digicorp-code-inspection-process" /><param name="allowfullscreen" value="true" /></object></p>
<div style="font-size: 11px; font-family: tahoma,arial; height: 26px; padding-top: 2px;">View more <a style="text-decoration:underline;" href="http://www.slideshare.net/">presentations</a> from <a style="text-decoration:underline;" href="http://www.slideshare.net/abhishek_desai">Abhishek Desai</a>. (tags: <a style="text-decoration:underline;" href="http://slideshare.net/tag/code">code</a> <a style="text-decoration:underline;" href="http://slideshare.net/tag/review">review</a>)</div>
</div>
<p>We make it a point to involve newly recruited developers in the inspection process so they get an idea where experienced developers are also going wrong.</p>
<p>This way it becomes part of training for newly recruited developers.</p>
<p>So far we have had half a dozen code reviews and some of them were good, some of them were bad. But all the developers at the end looks satisfied with the result. Developers are not making it an ego issue so far. <img src='http://dev.digi-corp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>What do you do at your company to do make your code better? Any suggestions to make this process better?</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.digi-corp.com/2009/02/code-inspection/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Documentation of an already developed project</title>
		<link>http://dev.digi-corp.com/2009/02/documentation-of-an-already-developed-project/</link>
		<comments>http://dev.digi-corp.com/2009/02/documentation-of-an-already-developed-project/#comments</comments>
		<pubDate>Wed, 11 Feb 2009 08:39:34 +0000</pubDate>
		<dc:creator>kuntal</dc:creator>
				<category><![CDATA[Software Development Lifecycle]]></category>
		<category><![CDATA[Class Diagram]]></category>
		<category><![CDATA[Code Commenting]]></category>
		<category><![CDATA[Commenting]]></category>
		<category><![CDATA[Database]]></category>
		<category><![CDATA[DB Scribe]]></category>
		<category><![CDATA[Documentation]]></category>
		<category><![CDATA[Documentation Tools]]></category>
		<category><![CDATA[SDLC]]></category>
		<category><![CDATA[SQL Server 2000]]></category>
		<category><![CDATA[VB Commenter]]></category>

		<guid isPermaLink="false">http://dev.digi-corp.com/?p=14</guid>
		<description><![CDATA[This is first of my experience regarding documenting an already developed project. Let me first describe the situation which we are going through. We have developed a system and before a couple of years and currently it is in a maintenance stage. It is in use in the production for last 1 year. The project [...]]]></description>
			<content:encoded><![CDATA[<p>This is first of my experience regarding documenting an already developed project.</p>
<p>Let me first describe the situation which we are going through.</p>
<p>We have developed a system and before a couple of years and currently it is in a maintenance stage.</p>
<p>It is in use in the production for last 1 year. The project is developed in Visual Studio 2003. It is a purely Windows Based Application and developed in VB.Net. The database behind it is SQL Server 2000 and we are using ASP.Net Web Services as middle layer.</p>
<p>Now as the client is going through the inspection of the project, we are now to generate the documentation of the whole project.</p>
<p>Normally, this happens in many of the projects which I see around, typically in our part of world the developers are more inclined to do coding rather then do designing, documentation and planning and then actually doing coding.</p>
<p>Now in this situation, I would like to share with you what we have decided to develop as part of our documentation of the system which might help you at certain point of time in your project. The main part is we are not having enough time right now and we are in a real hurry.</p>
<p>We have decided to prepare the following documents.</p>
<p><strong>1.    Database Dictionary</strong><br />
We have found out a very useful tool for generating database documentation. The tool is <a title="DB Scribe" href="http://www.leadum.com/product.php?prod_id=4" target="_blank">DBScribe</a>. It is an excellent tool, it automatically generates all the documentation related to all the database objects from the database itself. Right now we are using the trial version in order to check the capabilities. Other nice thing about tool is it is automatically defining the dependencies between the database objects. It generates a chm and html document as output. We are trying to figure out how to insert some of the information in the tool. For example, how to add description of the table and how to add description of stored procedure parameters.</p>
<p><strong>2.    Code Commenting</strong><br />
We are using the <a title="VB Commenter" href="http://code.msdn.microsoft.com/VBCommenter/Release/ProjectReleases.aspx?ReleaseId=1004" target="_blank">VB Commenter</a> for generating comments in the code. We are to do two level of commenting in the code. Class level commenting and Procedure level commenting. Following are snippets of what we are going to put as comment in the code.<br />
<strong></strong></p>
<p><strong>Class Level Commenting</strong><br />
&#8221;&#8217;&lt;summary&gt;<br />
&#8221;&#8217;    [Name] FrontController<br />
&#8221;&#8217;    [Description] Acts as the initial point of entry/exit into the system<br />
&#8221;&#8217;                  and manages the handling of the request, including invoking security services such as authentication and authorization.<br />
&#8221;&#8217;    [Reference]<br />
&#8221;&#8217; &lt;/summary&gt;<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
&#8221;&#8217; &lt;remarks&gt;<br />
&#8221;&#8217; &lt;/remarks&gt;<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
&#8221;&#8217; &lt;history&gt;<br />
&#8221;&#8217;    &lt;creation&gt;<br />
&#8221;&#8217;     [amita] [anokhi] 12 June 2007<br />
&#8221;&#8217;    &lt;/creation&gt;<br />
&#8221;&#8217;    &lt;modification&gt;<br />
&#8221;&#8217;    &lt;/modification&gt;<br />
&#8221;&#8217; &lt;/history&gt;<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p><strong>Procedure Level Commenting<br />
</strong> &#8221;&#8217;&lt;summary&gt;<br />
&#8221;&#8217;    [Name] AuthenticateRequest<br />
&#8221;&#8217;    [Description] Validates UserID and Password and updates Database by Authenticating Login Request<br />
&#8221;&#8217;    [Reference]<br />
&#8221;&#8217; &lt;/summary&gt;<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
&#8221;&#8217; &lt;history&gt;<br />
&#8221;&#8217;    &lt;creation&gt;<br />
&#8221;&#8217;     [amita] [anokhi] 12 June 2007<br />
&#8221;&#8217;    &lt;/creation&gt;<br />
&#8221;&#8217;    &lt;modification&gt;<br />
&#8221;&#8217;    &lt;/modification&gt;<br />
&#8221;&#8217; &lt;/history&gt;<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;<br />
&#8221;&#8217;  Algorithm<br />
&#8221;&#8217;  Steps<br />
&#8221;&#8217;  [1]   Get Current Context<br />
&#8221;&#8217;  [2]   If Request is of Login from Home page then<br />
&#8221;&#8217;  [3]   Retrieve User Id and Password<br />
&#8221;&#8217;  [4]   If user ID exist in hastable then get its Users Object else goto [7]<br />
&#8221;&#8217;  [5]   If Password is not Correct  then goto [7]<br />
&#8221;&#8217;  [6]   Generate Ticket, identity and Principal<br />
&#8221;&#8217;        Assign it in Context, User object (also in HashTable), Session, Database<br />
&#8221;&#8217;  [7]   If Password or UserId is incorrect then set Users object as nothing and call Invalid Login<br />
&#8221;&#8217;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</p>
<p><strong>3.    Class Diagram<br />
</strong>We are planning to convert our project which is in .Net 2003 to .Net 2005 and generate a class diagram from the IDE itself. Now here I am searching for some more sophisticated automatic class diagram generator tools as generating class diagram from this code manually will be a very time consuming and tedious work. Right now VS-2005 editor is giving some errors while I try to generate the class diagram and also I do not find those class diagrams very attractive.</p>
<p><strong>4.    Database Relationship Diagram</strong><br />
This will be similar as what SQL Server generates. We will link up all the tables and then submit the diagram.</p>
<p>Can you suggest me some better and efficient ways of doing this?</p>
]]></content:encoded>
			<wfw:commentRss>http://dev.digi-corp.com/2009/02/documentation-of-an-already-developed-project/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

