<?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>cmdLabs &#187; tools</title>
	<atom:link href="http://blog.cmdlabs.com/tag/tools/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.cmdlabs.com</link>
	<description></description>
	<lastBuildDate>Mon, 26 Sep 2011 15:29:17 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Advances in Windows Mobile Forensics</title>
		<link>http://blog.cmdlabs.com/2010/08/29/advances-in-windows-mobile-forensics/</link>
		<comments>http://blog.cmdlabs.com/2010/08/29/advances-in-windows-mobile-forensics/#comments</comments>
		<pubDate>Sun, 29 Aug 2010 17:25:09 +0000</pubDate>
		<dc:creator>Eoghan Casey</dc:creator>
				<category><![CDATA[Mobile Device Forensics]]></category>
		<category><![CDATA[Cell Phone Forensics]]></category>
		<category><![CDATA[Embedded Databases]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[Windows Mobile Forensics]]></category>

		<guid isPermaLink="false">http://blog.cmdlabs.com/?p=207</guid>
		<description><![CDATA[Recent research into important file formats on Windows Mobile devices has led to a breakthrough in mobile device forensics. Our improved understanding of the proprietary Microsoft embedded database format enables us to recover all available data from files such as cemail.vol, including deleted items. The papers and associated tools detailing these advances in Windows Mobile [...]]]></description>
			<content:encoded><![CDATA[<p>Recent research into important file formats on Windows Mobile devices has led to a breakthrough in mobile device forensics. Our improved understanding of the proprietary Microsoft embedded database format enables us to recover all available data from files such as cemail.vol, including deleted items.<br />
<br />
The papers and associated tools detailing these advances in Windows Mobile forensic analysis are published in the <a href="http://www.digitalinvestigation.net">Journal of Digital Investigation</a>. The most recent special issue on forensic analysis of embedded systems contains two papers: <em>Introduction to Windows Mobile Forensics</em> and <em>Windows Mobile Advanced Forensics</em>.<br />
<br />
<em>Introduction to Windows Mobile Forensics</em> by Eoghan Casey, Michael Bann and John Doyle covers the fundamentals of Windows Mobile systems, embedded database formats and tools for acquiring and examining these systems in a forensic context. A table from this paper is provided here, listing potentially useful sources of evidence on Windows Mobile devices.</p>
<p style="text-align: center;"><a href="http://blog.cmdlabs.com/wp-content/uploads/2010/08/Table.jpg"><img class="aligncenter size-full wp-image-208" title="Table 1" src="http://blog.cmdlabs.com/wp-content/uploads/2010/08/Table.jpg" alt="" width="822" height="377" /></a></p>
<p style="text-align: center;">
<p><br clear=all><em>Windows Mobile Advanced Forensics</em> by Coert Klaver from the Netherlands Forensic Institute provides in-depth technical details about embedded database formats and tools for acquiring and examining this information. The author developed tools for interpreting data in embedded databases acquired from Windows Mobile devices, including deleted items.</p>
<p><br clear=all>An upcoming issues of the Journal of Digital Investigation contains the paper <em>Windows Mobile Advanced Forensics: An Alternative to Existing Tools</em> by Cpt. Frédérick Rehault from the French National Gendarmerie. The author developed custom boot loaders and file parsing tools to extract the maximum amount of information available from Windows Mobile devices. A small sample of the very detailed output from one customized tool is provided below, showing interpreted fields extracted from a text message in cemail.vol along with the location of associated content in the file system.</p>
<ul>
<code>[ MESSAGE ] &lt;&lt;&lt;&lt; VISIBLE &gt;&gt;&gt;&gt;<br />
Message Class : :  IPM.SMStext<br />
Message Flag (1:Read; 0:Unread) : 0x00000028<br />
Subject :  Love you too. Cant wait to see you tomorrow!<br />
Msg Status : 0x00040000 : SMS<br />
Delivery Time 2009-05-15 04:53:54<br />
Sender Email Address :  14435551212<br />
Sender Name :  14435551212<br />
Last Modification Date 2009-05-15 04:53:55<br />
Recipient Info: address &amp; name :   t£ lT SMS14105551212Steven…</p>
<p>-- Message Content Location --<br />
NORMALLY Stored in "\Windows\Messaging\ 453a000a xxxxxxxx.mpb "<br />
</code>
</ul>
<p>The tool also extracts the raw database record as shown here with all of the internal database fields:</p>
<ul>
<code>*************************************************************<br />
[ DEBUG ]: Found RECORD HEADER at Offset 0x000b7e9c</code></p>
<p><code>[ DEBUG ]: hRecord 		= 0x00000a47<br />
[ DEBUG ]: hDBHandle 		= 0x00000060<br />
[ DEBUG ]: DataRecordSize		= 0x00b8<br />
[ DEBUG ]: CompDataRecordSize	= 0x009e<br />
[ DEBUG ]: Nb Props found = 12<br />
[ DEBUG ]: Flag 		= 0x4000 : Data might be compressed</p>
<p>00000000 45 0a 00 3a a0 00 00 00   0f 00 00 31 28 00 00 00   |E..:.......1(...|<br />
00000010 00 00 b0 25 58 00 4c 00   6f 00 76 00 65 00 20 00   |...%X.L.o.v.e. .|<br />
00000020 79 00 6f 00 75 00 20 00   74 00 6f 00 6f 00 2e 00   |y.o.u. .t.o.o...|<br />
00000030 20 00 43 00 61 00 6e 00   74 00 20 00 77 00 61 00   | .C.a.n.t. .w.a.|<br />
00000040 69 00 74 00 20 00 74 00   6f 00 20 00 73 00 65 00   |i.t. .t.o. .s.e.|<br />
00000050 65 00 20 00 79 00 6f 00   75 00 20 00 74 00 6f 00   |e. .y.o.u. .t.o.|<br />
00000060 6d 00 6f 00 72 00 72 00   6f 00 77 00 21 00 34 00   |m.o.r.r.o.w.!.4.|<br />
00000070 00 00 04 00 00 9d b0 25   19 d5 c9 01 16 00 31 00   |.......%......1.|<br />
00000080 34 00 34 00 33 00 35 00   35 00 35 00 31 00 32 00   |4.4.3.5.5.5.1.2.|<br />
00000090 31 00 32 00 16 00 31 00   34 00 34 00 33 00 35 00   |1.2…1.4.4.3.5.|<br />
000000a0 35 00 35 00 31 00 32 00   31 00 32 00 80 33 49 26   |5.5.1.2.1.2..3I&amp;|<br />
000000b0 19 d5 c9 01 47 0a 00 3b                             |....G..;|</p>
<p>+ List of properties in record:<br />
-- PropID[ 0 ] = 0x80050013 UI4 : 0x3a000a45<br />
-- PropID[ 1 ] = 0x80110013 UI4 : 0x000000a0<br />
-- PropID[ 2 ] = 0x001a0013 UI4 : 0x3100000f<br />
-- PropID[ 3 ] = 0x0e070013 UI4 : 0x00000028<br />
-- PropID[ 4 ] = 0x003d001f LPWSTR :<br />
-- PropID[ 5 ] = 0x0037001f LPWSTR : Love you too. Cant wait to see you tomorrow!<br />
-- PropID[ 6 ] = 0x0e170013 UI4 : 0x00040000<br />
-- PropID[ 7 ] = 0x0e060040 FILETIME 0x1c9d51925b09d00<br />
-- PropID[ 8 ] = 0x0c1f001f LPWSTR : 14435551212<br />
-- PropID[ 9 ] = 0x0c1a001f LPWSTR : 14435551212<br />
-- PropID[ 10 ] = 0x30080040 FILETIME 0x1c9d51926493380<br />
-- PropID[ 11 ] = 0x80010013 UI4 : 0x3b000a47</p>
<p></code></p>
</ul>
<p><br clear=all>cmdLabs covers forensic analysis of Windows Mobile and other mobile devices in the course we develop and teach for SANS (<a href="http://www.sans.org/security-training/mobile-device-forensics-4367-tid">FOR563 &#8211; Mobile Device Forensics</a>).</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.cmdlabs.com/2010/08/29/advances-in-windows-mobile-forensics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Misinterpretation of File System Timestamps</title>
		<link>http://blog.cmdlabs.com/2009/05/08/misinterpretation-of-file-system-timestamps/</link>
		<comments>http://blog.cmdlabs.com/2009/05/08/misinterpretation-of-file-system-timestamps/#comments</comments>
		<pubDate>Fri, 08 May 2009 19:43:44 +0000</pubDate>
		<dc:creator>cmdLabs Staff</dc:creator>
				<category><![CDATA[Tool Validation]]></category>
		<category><![CDATA[FAT]]></category>
		<category><![CDATA[file system]]></category>
		<category><![CDATA[metadata]]></category>
		<category><![CDATA[timestamps]]></category>
		<category><![CDATA[tools]]></category>
		<category><![CDATA[validation]]></category>

		<guid isPermaLink="false">http://blog.cmdlabs.host.tivilon.com/?p=38</guid>
		<description><![CDATA[Despite the fact that FAT is one of the earliest file systems that forensic practitioners had to deal with, there are still gaps in knowledge that result in misinterpretation and misrepresentation. A prime example of this is the create time in FAT, which is not calculated correctly by some forensic tools. This issue came up [...]]]></description>
			<content:encoded><![CDATA[<p>Despite the fact that FAT is one of the earliest file systems that forensic practitioners had to deal with, there are still gaps in knowledge that result in misinterpretation and misrepresentation. A prime example of this is the create time in FAT, which is not calculated correctly by some forensic tools. This issue came up in a recently discussion I had with Geoff Fellows (http://www.f3.org.uk/modules/smartclient/client.php?id=3). Although FAT last write timestamps only have a resolution of 2 seconds, whereas the create time has a resolution of 10 milliseconds that some forensic tools fail to take into account. A difference of milliseconds can be important in some cases, and any calculations based on an incorrect representation of creation timestamps will be incorrect.</p>
<p><br clear=all>The confusion arises from the fact that FAT file systems represent create and last write timestamps slightly differently. Last write timestamps are 32 bit little-endian values, interpreted as follows:</p>
<p><br clear=all><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 24                                16                8                0<br />
+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+<br />
|Y|Y|Y|Y|Y|Y|Y|M| |M|M|M|D|D|D|D|D| |h|h|h|h|h|m|m|m| |m|m|m|s|s|s|s|s|<br />
+-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+ +-+-+-+-+-+-+-+-+</span></p>
<p>\____________/\________/\_________/ \________/\____________/\_________/<br />
year        month      day        hour       minute       second</p>
<p><br clear=all>Take as an example the following FAT folder entry with the last write date highlighted in bold:</p>
<p><br clear=all><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">$ icat /dev/sdb1 353884 | xxd<br />
0000000: 2e20 2020 2020 2020 2020 2030 004f b079  .          0.O.y<br />
0000010: 763a 763a 0000 b579 763a a502 0000 0000  v:v:</span>&#8230;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">yv:</span>&#8230;&#8230;<br />
<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 0000020: 2e2e 2020 2020 2020 2020 2010 004f b079  ..         ..O.y<br />
0000030: 763a 763a 0000 b079 763a 6605 0000 0000  v:v:</span>&#8230;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">yv:f</span>&#8230;..<br />
<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 0000040: 4173 0061 006c 0076 0065 000f 009e 6e00  As.a.l.v.e</span>&#8230;.<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">n.<br />
0000050: 6500 7700 3400 2e00 6700 0000 6900 6600  e.w.4</span>&#8230;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">g</span>&#8230;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">i.f.<br />
0000060: 5341 4c56 454e 7e31 4749 4620 0075 78b9  SALVEN~1GIF .ux.<br />
0000070: 753a 763a 0000 </span><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; font-weight: bold;">78b9</span><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> </span><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal; font-weight: bold;">753a</span><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 9212 c1d4 0000  u:v:..x.u:</span>&#8230;&#8230;<br />
<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 0000080: 4269 0066 0000 00ff ffff ff0f 0014 ffff  Bi.f</span>&#8230;&#8230;&#8230;&#8230;<br />
<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> 0000090: ffff ffff ffff ffff ffff 0000 ffff ffff </span>&#8230;&#8230;&#8230;&#8230;&#8230;.</p>
<p><br clear=all>Converting to big-endian gives 3a 75 b9 78, which has the following binary representation:</p>
<p><br clear=all>00111010 01110101 10111001 01111000</p>
<p><br clear=all>This translates to a timestamp of 2009.03.21 23:11:48 as follows:</p>
<ul>
<li>7 bits = 0011101 = 29 years since 1980</li>
<li>4 bits = 0011 = 3 months</li>
<li>5 bits = 10101 = 21 days</li>
<li>5 bits = 10111 = 23 hours</li>
<li>6 bits = 001011 = 11 minutes</li>
<li>5 bits = 11000 = 24 = 48 seconds</li>
</ul>
<p><br clear=all>Note that 5 bits cannot store all 60 seconds, so last write timestamps must be incremented in 2 second intervals, and is always an even number of seconds.</p>
<p><br clear=all>Although the create time follows this same general calculation, it uses an additional 8 bits to represent one hundredths of a second. In the same directory listing above, the create timestamp is identical to the last modified timestamp except for an additional byte (75 78 b9 75 3a). The additional byte equates to 117 hundredths of a second, which brings the create time to 2009.03.21 23:11:49.17. Thus, the create time can have odd number of seconds, and has a resolution of 10 milliseconds.</p>
<p><br clear=all>Older versions of XWays Forensics had the option to display timestamps to tenths of a second, and newer versions can be configured with greater precision as shown here:</p>
<p style="text-align: center;"><img class="alignnone size-full wp-image-39" title="directory_browser_options-x-ways" src="http://blog.cmdlabs.host.tivilon.com/wp-content/uploads/2009/05/directory_browser_options-x-ways.jpg" alt="directory_browser_options-x-ways" width="429" height="532" class="aligncenter size-full wp-image-243" /></p>
<p><br clear=all>Note: Updated configuration screenshot showing increased precision in XWays 15.1 SR3 provided by Geoff Fellows.</p>
<p><br clear=all>The create timestamps for files copied onto a thumb drive are shown here in XWays Forensics with tenths of seconds displayed:</p>
<p style="text-align: center;"><img class="alignnone size-full wp-image-40" title="blog1-winhex-createtimes" src="http://blog.cmdlabs.host.tivilon.com/wp-content/uploads/2009/05/winhex-createtimes.jpg" alt="blog1-winhex-createtimes" width="430" height="292" class="aligncenter size-full wp-image-244" /></p>
<p><br clear=all>However, some other forensic tools like TSK only interpret the first four bytes of the create date-time stamp, limiting the resolution to 2 seconds. This is demonstrated in the following listing of the same files as those listed above using XWays (we have reported this bug and it will be fixed in the next release of TSK).</p>
<p><br clear=all><span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">$ fls -l /dev/sdb1 353884 | awk {&#8216;print $3 </span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">\t</span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> $10 </span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">\t</span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> $11 </span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> </span>&#8220;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;"> $12&#8242;} | sort </span>&#8211;<span style="font-family: Courier,mono; font-style: normal; font-variant: normal; font-weight: normal; font-size: 12px; line-height: normal; font-size-adjust: none; font-stretch: normal;">key 2<br />
snake_oil.jpg					2009.03.21	 23:03:32 (EDT)<br />
orange-Clark_Stanley_Snake_Oil.png	2009.03.21	 23:04:32 (EDT)<br />
orange-OilKingLrg.jpg			2009.03.21	 23:04:48 (EDT)<br />
orange-Drs_Mixer.jpg				2009.03.21	 23:05:24 (EDT)<br />
orange-Hostetters_Bitters.jpg		2009.03.21	 23:05:42 (EDT)<br />
orange-wine_of_tar.jpg			2009.03.21	 23:05:54 (EDT)<br />
orange-medsh17.jpg				2009.03.21	 23:06:04 (EDT)<br />
orange-miraclecure.jpg			2009.03.21	 23:06:14 (EDT)<br />
snakeoil.jpg					2009.03.21	 23:07:22 (EDT)<br />
snake-oil2.jpg					2009.03.21	 23:08:16 (EDT)<br />
banjsalv.jpg					2009.03.21	 23:11:30 (EDT)<br />
salvenew4.gif					2009.03.21	 23:11:48 (EDT)<br />
yankdcornsalvelg.jpg				2009.03.21	 23:12:36 (EDT)<br />
liniment-for-man-and-beast.jpg		2009.03.21	 23:12:50 (EDT)<br />
Thumbs.db						2009.03.22	 14:25:12 (EDT)</span></p>
<p><br clear=all>This issue was recently fixed in EnCase version 6.12, and is documented in the release note as &#8220;339: EnCase does not read FAT Create Date correctly (BUGID67).&#8221; EnCase version 6.12 now displays the create time to the correct second but not the hundredth of a second.</p>
<p><br clear=all>If a forensic examiner is not aware of this error, it can not only introduce inaccuracies into his/her findings, it can also reflect poorly on his/her expertise in this area.</p>
<p><br clear=all>The fact that this bug has existed in EnCase and other widely used forensic tools clearly demonstrates the need to validate important findings using more than one tool. Furthermore, this issue demonstrates that forensic practitioners cannot simply push buttons and unquestioningly rely on the results, but rather must understand the underlying technology sufficiently to double check what their tools are reporting.</p>
<p><br clear=all>Another area relating to FAT file systems where current literature is incorrect is in file allocation strategies but that discussion is for another time&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.cmdlabs.com/2009/05/08/misinterpretation-of-file-system-timestamps/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

