Forensic Focus - Computer Forensics, Computer Forensic Training, Digital Forensics
LoginRegisterForumsPapersEducationGraduate RecruitmentReviewsInterviewsNewsletterJobsEventsBlog
Search Forensic Focus
Custom Search
Graduate Recruitment

computer forensics graduate jobs

Follow Forensic Focus

Join newsletter

Join LinkedIn group

Follow on Twitter

Subscribe to news

Subscribe to forums

Subscribe to blog

Subscribe to tweets

Members' blogs

External feeds

Bookmark & share: Bookmark and Share

Main Menu
MY ACCOUNT
COMMUNITY
EMPLOYMENT
EDUCATION
RESOURCES
MISC
Computer Forensics Newsletter
Newsletter

You must be a
registered user
to receive our newsletter

Register Now!
Forensic Focus

Forensic Focus

Copy and paste the text below to insert the button displayed above on your site. Thanks for your support!


Linux for computer forensic investigators: «pitfalls» of mounting file systems

by Suhanov Maxim
ITDefence.Ru

Introduction

Forensic Linux distribution is a customized Linux distribution that is commonly used to complete different tasks during computer forensics investigations. These distributions are often used to complete the following tasks:

– Quick preview of various data storage devices (for example, to determine installed operating system);
– Creating «bit-to-bit» copies of data storage devices;
– Conducting full analysis of data storage devices.

Some forensic Linux distributions may include network forensics tools and tools for acquiring volatile data from a running system.


Requirements for forensic Linux distributions

Every forensic Linux distribution should satisfy the following requirements:

– Do not allow any writes to evidentiary media without user's permission;
– Boot on most common hardware configurations;
– Use only up to date software and fix all security problems as soon as possible.

Blocking any writes to evidentiary media can be achieved by following these steps:

1. Boot scripts and programs do not mount any file systems, do not activate the swap space and do not activate software RAID arrays on evidentiary media without user's permission;
2. Automouting for all file system types on connected removable devices is disabled.

It is also possible to set all block devices to read-only mode during the boot process to protect evidence from incorrect user actions.


«Pitfalls» of mounting file systems in read-only mode

All Linux distributions allow users to mount a file systems in read-only mode (for example, using the following command: «mount -o ro /dev/sda1 /mnt/sda1»). However, mounting file systems in such a way does not guarantee that file system's data will never be altered by the operating system. For example, mounting a damaged Ext3 file system with only «-o ro» option will result in data modification during the recovery process:

EXT3-fs: INFO: recovery required on readonly filesystem.
EXT3-fs: write access will be enabled during recovery.
kjournald starting. Commit interval 5 seconds
EXT3-fs: recovery complete.
EXT3-fs: mounted filesystem with ordered data mode.

Some forensic Linux distributions may show user a message saying that some data on evidentiary media has been overwritten

In this case some file system metadata gets updated after recovery:

FILE SYSTEM INFORMATION
--------------------------------------------
File System Type: Ext3
Volume Name:
Volume ID: 5962a06aa4c895b5104749a687ccb9e0
Last Written at: Mon Sep 7 17:41:01 2009
Last Checked at: Fri Sep 4 18:39:00 2009
Last Mounted at: Mon Sep 7 17:41:01 2009
Unmounted properly
Last mounted on:
Source OS: Linux
Dynamic Structure
Compat Features: Journal, Ext Attributes, Resize
Inode, Dir Index
InCompat Features: Filetype, Needs Recovery,
Read Only Compat Features: Sparse Super, Has
Large Files,
FILE SYSTEM INFORMATION
--------------------------------------------
File System Type: Ext3
Volume Name:
Volume ID: 5962a06aa4c895b5104749a687ccb9e0
Last Written at: Mon Sep 7 18:02:57 2009
Last Checked at: Fri Sep 4 18:39:00 2009
Last Mounted at: Mon Sep 7 17:41:01 2009
Unmounted properly
Last mounted on:
Source OS: Linux
Dynamic Structure
Compat Features: Journal, Ext Attributes, Resize
Inode, Dir Index
InCompat Features: Filetype,
Read Only Compat Features: Sparse Super, Has
Large Files,

Metadata changes after damaged Ext3 file system recovery

Mounting other file systems (for example, Ext4, ReiserFS and XFS) with only «-o ro» option may result in data modification too.


Mounting file systems in a forensically sound manner

To mount various file system types in a forensically sound manner the following methods can be used:

1. Loopback devices in read-only mode: can be switched on using «ro,loop» mount options (for example: «mount -o ro,loop /dev/sda1 /mnt/sda1»);
2. Block devices for disks and partitions in read-only mode: you can switch any block device to read-only mode by using blockdev tool (for example: «blockdev --setro /dev/sda1»);
3. You can disable all journal recovery actions for Ext3 and Ext4 file systems by using «ext2» file system type during the mount. Unfortunately, not all file systems support such kind of write protection — for example, there are no working write protection mount options for XFS (however, this was fixed in very recent kernel versions).

It should be noted that mounting damaged Ext3 and Ext4 file systems using these ways is only possible by utilizing alternate superblocks. You can get alternate superblocks locations by using «mke2fs -n» command (for example: «mke2fs -n /dev/sda1»).


«Pitfalls» of automounting file systems

Automounting of file systems in Linux may occur in following situations: during the boot process and after connecting removable device (for example, USB Flash drive) to a running system.

Removing all entries for file systems on evidentiary media from «/etc/fstab» does not guarantee that they will never be mounted during the boot — file systems can be mounted (and modified) during execution of initrd scripts or during execution of hardware detection scripts.

Automounting of file systems on removable data storage devices is controlled by special software programs that are properly configured (or disabled) on most forensic Linux distributions.


Testing popular forensic Linux Live CD distributions

I have tested several major forensic Linux Live CD distributions for various mounting issues.

Information about tested forensic Linux Live CD distributions

Test results:

– All tested distributions do not mount file systems on connected USB Flash devices;
– Some distributions automatically mount (and sometimes modify) file systems on evidentiary media during the boot process: SPADA mounts file systems during execution of hardware detection scripts, other automounting distributions alter the data on evidentiary media during execution of initrd scripts.

Test results


Testing automatic swap space activation

The following distributions were tested for automatic swap space activation during the boot: Helix3 (old version), SMART Linux (Slackware), grml, LinEn Boot CD and RIPLinux.

None of these distributions activate the swap space on evidentiary media during the boot process.


Conclusions

I have found that some forensic Linux Live CD distributions do mount and recover several file system types during the boot process. However, I didn't test Linux RAID and LVM activation issues, so it is recommended to use distributions that do not activate software RAID arrays and LVM without users' permission (e.g. grml).



Forensic Education

computer forensics education choices COURSE DIRECTORY

User Info

Welcome Anonymous

Nickname

Membership:
Latest: gamfim
New Today: 4
New Yesterday: 13
Overall: 13602

People Online:
Members: 1
Visitors: 13
Bots: 9
Staff: 0
Staff Online:

No staff members are online!
Latest Jobs

Computer Forensics Examiners- Virginia
Last post by keydet89 in Computer Forensics Job Vacancies on Mar 13, 2010 at 19:56:37

Investigations Manager-China- Salary Neg
Last post by Teval in Computer Forensics Job Vacancies on Mar 12, 2010 at 16:51:00

EDISCOVERY SENIOR ANALYST & MANAGER LONDON
Last post by ScottBurkeman in Computer Forensics Job Vacancies on Mar 11, 2010 at 17:02:47

DATA ANALYTICS & COMPUTER FORENSICS - LONDON, T0 £60000
Last post by ScottBurkeman in Computer Forensics Job Vacancies on Mar 11, 2010 at 16:12:33

Forensic Data Analytics senior associate- London upto 40k +
Last post by ChrisHolt in Computer Forensics Job Vacancies on Mar 09, 2010 at 19:36:48

Digital Forensic Analyst (Fort Worth, Texas)
Last post by pispy4u in Computer Forensics Job Vacancies on Mar 01, 2010 at 00:23:53

Senior Researcher & Research Officer - Staffordshire Uni, UK
Last post by Fab4 in Computer Forensics Job Vacancies on Feb 27, 2010 at 21:19:57

PhD Studentship, Cranfield University, Shrivenham
Last post by charg in Computer Forensics Job Vacancies on Feb 22, 2010 at 14:52:15

Forensic eDiscovery Mgr Global consultancy (London)
Last post by ChrisHolt in Computer Forensics Job Vacancies on Feb 19, 2010 at 16:57:38

Director, Center for Crimminal Justice Training Glenville WV
Last post by JasonMcDougal in Computer Forensics Job Vacancies on Feb 18, 2010 at 14:31:34

Computer Forensics Blog
· Guest blog post: TACTICAL trial by fire
· Computer forensics education directory updated
· Computer forensics education directory now online
· US academic institutions - final call for contact details!
· Hidden Hymn
· Adroit Photo Forensics review
· Interview with Russell May, 4N6 Investigation
· Forensic Computing PhD, UK
· The Value of Push Button Computer Forensics
· Academic institutions - updated

read more...
Members' Blogs

Start Blogging

What is Computer Forensics?
Computer forensics (or forensic computing) is the use of specialized techniques for recovery, authentication, and analysis of electronic data with a view to presenting evidence in a court of law.
Computer Forensics Downloads
  1: Forensic Examination of Digital Evidence: A Guide for Law Enforcement (pdf)
  2: ACPO Good Practice Guide for Computer based Electronic Evidence
  3: Electronic Crime Scene Investigation: A Guide for First Responders (pdf)
  4: Ancysoft Data Recovery Software
  5: HELIX incident response CD
  6: PDA Forensic Tools:An Overview and Analysis
  7: Forensics Plan Guide & Forensic Cookbook
  8: Recover My Files
  9: Autopsy Forensic Browser Version 2.03 (source code)
  10: Handy Recovery

Use of this website signifies your agreement to the Terms of Use/Privacy Policy available here.

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © 2010 Forensic Focus


Interactive software released under GNU GPL, Code Credits, Privacy Policy
.: fisubsilver shadow phpbb2 style by Daz :: CPG-Nuke port by norseman :: ported to CPG-Dragonfly by jamin :.