United States  

 

  Solutions Products Download Store Contact Us Support

 

FREE FORENSICS TOOLS: SEARCHER
 

 

Searcher is a free application that identifies files that may contain certain types of data such as social security number, credit card number or any data pattern users wish to search for. The main purpose of this application is to find files that contain confidential information. In fact, it contains a basic module that searches for pattern of numbers that resemble Social Security number (ssn). Searcher is a java application which runs on any computer platforms (Windows, Mac, Linux etc.) that support java 1.5 or higher. In addition, because of its pluggable design for search engines construction, Searcher's functionality can be easily extended to handle files that are encoded or compressed. Seacher also creates a log file that lists all the files identified as containing data (confidential) you wish to search for. The person who uses this application can examine this log file and take actions, accordingly or send this log file to a designated http server to be examined by IT security officer, later.

 

The following documents show the installation process and use of application's features:

  • How to install Searcher (download link)

  • How to use Searcher

Searcher's basic ssn engine (included in this distribution package) may incorrectly identify certain types of files as containing confidential data. This problem can be resolved in the future as more accurate engines are developed and added to this application. However, every effort should be made to verify this application's scan result.

Note: the basic ssn engine (included in this distribution package) only identifies strings similar to ssn from a byte stream of file without understanding the file structure. For example, 800-88-8888 (not valid ssn) is saved in Microsoft Excel file as a number, 800888888, but formatted as 800-88-8888 in a cell for display purpose only. Since this is not a string, it cannot be detected using this basic ssn search module (which uses regular expression). You can create custom plug-in classes that understand certain file structures by simply implementing IPluggable interface. The process will be explained later in "How to use Seacher" section.

 

How to install Searcher

Requirements: any operating system (O.S.) platform with Java Runtime Environment (JRE) 1.5 or higher installed. To ensure you have the correct version of java, check the box below:

If the currently installed version of java does not meet the minimum requirement, go to http://java.sun.com/ and select the latest of version of JRE available.
 

1.  Download Searcher installation package. Click here.

 

2.  Decompress the installation package. You will see a folder called Searcher. The main program and related search plug-ins are located inside Searcher folder.

 

3.  If you are installing this application in unix-like operating system (Linux, Mac etc.), make sure you grant execution permission to Searcher.sh file.

[root@test-nb1 Searcher]$ chmod 755 Searcher.sh
 

4.  Make sure you grant appropriate read/write permissions to Searcher.ini file and logs folder (including its contents, if any). The following are examples of security setting for Unix-like and Windows XP operating system.

Read/Write Permissions to Regular Users

Unix-like Operating System:
[root@test-nb1 Searcher]$ chmod -R 666 Searcher.ini 

Windows XP Operating System:

Read/Write Permissions to Only Owner and Assigned Group

Unix-like Operating System:
[root@test-nb1 Searcher]$ chmod -R 660 logs 

Windows XP Operating System:


 

How to use Searcher

A. Scan selected drive or directory
 

1. Run Searcher.sh (unix-like O.S.) or Searcher.bat (Windows) file to launch Searcher application.
 

2. Click the Scan button. You will be prompted to select drive and directory you wish to search for. If your selection (directory) contains a very deep hierarchical folder structure (like root of your main drive), Searcher may take a long time to run.

 

3.  Click the Select button and then, Searcher will begin to search files. If you want to cancel the search operation, click the Stop button.
 

Note: if you want to enable or disable certain plug-ins, select File->Plug-ins and click any plug-in (check box) you wish to enable or disable. If enabled, you can see a check mark next to a plug-in item as shown below.
 


 

B. Save (or send via http) the report of scanned files
 

Upon completion of the scan operation, select File->Save. Searcher will create the scanned report in logs folder. Make sure that  write/read permissions are granted to logs folder. (see How to Install Searcher section).

 

In addition, you can send the scanned report to a designated http server via HTTP POST method.
Click File->Send results to ...  You will be prompted to enter User Name and HTTP Address as shown below.

 

After entering User Name and Address (required), click the Send button.

 

Note: you can use any server-side scripting methods (asp, aspx, php, jsp etc.) as long as it can process the multipart post method with two fields, one for string and another for file. The string field must be of type "text" and be called "name". Here is an example of equivalent client-side form with multi-part post method. You should make a server-side script that can process this form:

 

In this example, fileUploader.aspx was used for server-side processing. Below is a sample ASP.NET code.

 

C. Change the application behavior by modifying Searcher.ini
 

By adding some settings in Searcher.ini, you can make Searcher to automatically save or send scanned report when you exit the application.

To send scanned report to a designed http server upon exit, add the following keys in Searcher.ini:

REPORT_URL=http://yourdomain.com/fileUploader.aspx
SENDUPONEXIT=true
 

To save scanned report in logs folder upon exit, add the key below in Searcher.ini:

SAVEUPONEXIT=true

 

D. How to create a custom search engine

Any custom plug-in class you wish to create must implement all methods in IPluggable interface. The following example is given to you as a starting point for your custom search engine construction. I will suggest creating search engines that understand archived or compressed file structure (e.g., zip. cab, tar, etc.), or a combination of both (tar.bz).


IPluggable.java


 

This interface is very simple, but must be in interfaces package as indicated in this example. The most important method is int scan(String str). The parameter of this function is a string (absolute file path) that indicates a file to be inspected, but its returned value is an integer which can be interpreted as 1 for "pattern not found", -1 "I/O error" and 0 for "pattern found".

The example below shows how to create a search engine that scans for Credit Card Number using java regex engine.


BasicCreditCardFilter.java


 

To compile this example, follow the steps below:

Note: IPluggable.java and BasicCreditCardFilter.java are located under ~/src folder in this example.
 

[root@test-nb1 src]$ mkdir interfaces
[root@test-nb1 src]$ mkdir plugins
[root@test-nb1 src]$ mv IPluggable.java interfaces/.
[root@test-nb1 src]$ mv BasicCreditCardFilter.java plugins/.
[root@test-nb1 src]$ javac interfaces/IPluggable.java
[root@test-nb1 src]$ javac plugins/BasicCreditCardFilter.java
 

Under ~src/plugins folder, you can locate BasicCreditCardFilter.class. Place this file under Searcher/plugins folder. All the search engines (plug-ins) located in this folder will be loaded when Searcher is launched.

 

 

  Google PefectSW
   

Copyright 2008 © Julia D. Lee & Jae H. Park. All rights reserved.