Merge branch 'release-4.4.0' of https://github.com/sleuthkit/autopsy into 2572-AgencyLogo

This commit is contained in:
William Schaefer 2017-04-21 18:54:43 -04:00
commit 2ef4920903
11 changed files with 59 additions and 57 deletions

View File

@ -5,9 +5,8 @@
<project name="org.sleuthkit.autopsy.testing" default="netbeans" basedir=".">
<description>Builds, tests, and runs the project org.sleuthkit.autopsy.testing.</description>
<import file="nbproject/build-impl.xml"/>
<property name="regression" value="qa-functional"/>
<target name="check-args">
<fail message="Missing required argument: img_path" unless="img_path"/>
<fail message="Missing required argument: gold_path" unless="gold_path"/>
@ -16,14 +15,32 @@
<fail message="Missing required argument: nsrl_path" unless="nsrl_path"/>
<fail message="Missing required argument: keyword_path" unless="keyword_path"/>
</target>
<target name="regression-test" depends="check-args,init,test-init,test-build" if="exists.test.qa-functional.src.dir">
<test test.type="qa-functional"/>
<!-- use manifestclasspath (http://ant.apache.org/manual/Tasks/manifestclasspath.html) to put all the jar files that we need for junit/regression test
to a single jar file: allJarsInUse.jar. Then we put this new jar to classpath for testing program to avoid command line Java classpath too long problem. -->
<target name="manifest-classpath">
<manifestclasspath property="tem.classpath" jarfile="allJarsInUse.jar">
<classpath refid="test.${regression}.run.cp"/>
</manifestclasspath>
<jar destfile="allJarsInUse.jar" basedir="build/classes">
<manifest>
<attribute name="Class-Path" value="${tem.classpath}"/>
</manifest>
</jar>
<path id="test.classpath">
<pathelement path="allJarsInUse.jar"/>
</path>
</target>
<target name="regression-test" depends="check-args,init,test-init,test-build, manifest-classpath" if="exists.test.qa-functional.src.dir">
<test test.type="${regression}"/>
<delete file="allJarsInUse.jar"/>
</target>
<macrodef name="test">
<attribute name="test.type"/>
<attribute name="disable.apple.ui" default="false"/>
<sequential>
<property name="test.config" value="default"/>
<property name="test.config.default.includes" value="**/*Test.class"/>
@ -36,7 +53,7 @@
<batchtest todir="${build.test.@{test.type}.results.dir}">
<fileset dir="${build.test.@{test.type}.classes.dir}" includes="${test.includes}" excludes="${test.excludes}"/>
</batchtest>
<classpath refid="test.@{test.type}.run.cp"/>
<classpath refid="test.classpath"/>
<syspropertyset refid="test.@{test.type}.properties"/>
<jvmarg line="${test.bootclasspath.prepend.args}"/>
<jvmarg line="${test.run.args}"/>

View File

@ -275,12 +275,12 @@ public class AutopsyTestCases {
Date date = new Date();
String datenotime = dateFormat.format(date);
listOperator.clickOnItem(0, 1);
new Timeout("pausing", 1000).sleep();
new Timeout("pausing", 2000).sleep();
jbo0.pushNoBlock();
new Timeout("pausing", 1000).sleep();
new Timeout("pausing", 2000).sleep();
JButtonOperator jbo1 = new JButtonOperator(reportDialogOperator, "Finish");
jbo1.pushNoBlock();
new Timeout("pausing", 500).sleep();
new Timeout("pausing", 1000).sleep();
JDialog previewDialog = JDialogOperator.waitJDialog("Progress", false, false);
screenshot("Progress");
JDialogOperator previewDialogOperator = new JDialogOperator(previewDialog);

View File

@ -221,7 +221,7 @@
<delete includeemptydirs="true">
<fileset dir="${basedir}/docs/doxygen/doxygen_docs" includes="**/*"/>
</delete>
<delete includeemptydirs="true">
<delete includeemptydirs="true" failonerror="false">
<fileset dir="${basedir}/docs/doxygen-user/user-docs" includes="**/*"/>
</delete>

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

View File

@ -7,7 +7,7 @@ A central Solr server is needed to store keyword indexes. Zookeeper is used to m
You will need:
- 64-bit version of the Java Runtime Environment (JRE) from http://www.oracle.com/technetwork/java/javase/downloads/jre8-downloads-2133155.html.
- Download the latest Solr 6 installation package from https://bitnami.com/stack/solr/installer#windows. For the purposes of this guide that was the Bitnami Solr 6.2.1-2.
- Download the Apache Solr 4.10.3-0 installation package from https://sourceforge.net/projects/autopsy/files/CollaborativeServices/Solr or Direct Download Link
- Access to an installed version of Autopsy so that you can copy files from it.
- A network-accessible machine to install Solr upon. Note that the Solr process will need to write data out to the main shared storage drive, and needs adequate permissions to write to this location, which may be across a network.
@ -39,7 +39,7 @@ If you need the JRE, install it with the default settings.
The following steps will configure Solr to run using an account that will have access to the network storage.
1. Run the Bitnami installer, <i>"bitnami-solr-6.2.1-2-windows-installer.exe"</i>
1. Run the Bitnami installer, <i>"bitnami-solr-4.10.3-0-windows-installer.exe"</i>
2. If Windows prompts with User Account Control, click _Yes_
3. Follow the prompts through to completion. You do not need to <i>"Learn more about Bitnami cloud hosting"</i> so you can clear the check box.
4. If you see an error dialog like the following, you may safely ignore it.
@ -50,29 +50,28 @@ The following steps will configure Solr to run using an account that will have a
\subsection install_solr_config Solr Configuration
1. Stop the _solrJetty_ service by pressing _Start_, typing _services.msc_, pressing _Enter_, and locating the _solrJetty_ Windows service. Select the service and press _Stop the service_. If the service is already stopped and there is no _Stop the service_ available, this is okay.
2. Edit the <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\scripts\serviceinstall.bat"</i> script. You need administrator permission to change this file. The easiest way around this is to save a copy on the Desktop, edit the Desktop version, and copy the new one back over the top of the old. Windows will ask for permission to overwrite the old file; allow it. You should make the following changes to this file:
2. Edit the <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\scripts\serviceinstall.bat"</i> script. You need administrator permission to change this file. The easiest way around this is to save a copy on the Desktop, edit the Desktop version, and copy the new one back over the top of the old. Windows will ask for permission to overwrite the old file; allow it. You should make the following changes to this file:
<br>
<br>
- Add the following options in the line that begins with <i>"-StartParams"</i> :
+ <i>-StartParams="start;-c;-Dbootstrap_confdir=C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\configsets\AutopsyConfig\conf;-Dcollection.configName=AutopsyConfig" ^</i>
- Add the following options in the line that begins with <i>"C:\Bitnami\solr-4.10.3-0/apache-solr\scripts\prunsrv.exe"</i> :
+ <i>++JvmOptions=-Dcollection.configName=AutopsyConfig</i>
+ <i>++JvmOptions=-Dbootstrap_confdir="C:\Bitnami\solr-4.10.3-0\apache-solr\solr\configsets\AutopsyConfig\conf"</i>
+ <i>++JvmOptions=-DzkRun </i>
<br>
- Replace the path to JavaHome with the path to your 64-bit version of the JRE. If you do not know the path, the correct JavaHome path can be obtained by running the command "where java" from the Windows command line. An example is shown below. The text in yellow is what we are interested in. Do not include the "bin" folder in the path you place into the JavaHome variable. A correct example of the final result will look something like this: <i>-JavaHome="C:\Program Files\Java\jre1.8.0_111"</i>
<br><br>
A portion of an updated _serviceinstall.bat_ is shown below, with the changes marked in yellow.
<br><br>
\image html updatedServiceInstall.PNG
<br><br>
3. Edit <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\bin\solr.cmd"</i> and point _JAVA_HOME_ to _JavaHome_ path on your machine.
Changes in _solr.cmd_ are highlighted in yellow
<br><br>
\image html updatedSolr_cmd.PNG
<br><br>
4. Edit <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\solr.xml"</i> to set the _transientCacheSize_ to the maximum number of cases expected to be open concurrently. If you expect ten concurrent cases, the text to add is
\image html serviceinstall.PNG
<br><br>
3. Edit <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\solr\solr.xml"</i> to set the _transientCacheSize_ to the maximum number of cases expected to be open concurrently. If you expect ten concurrent cases, the text to add is
<i>\<int name="transientCacheSize">10\</int></i>
<br><br>
The added part is highlighted in yellow below. Ensure that it is inside the <i>\<solr></i> tag as follows:
<br>
\image html transientcache.PNG
<br><br>
5. Edit <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\server\resources\log4j.properties"</i> to configure Solr log settings:
4. Edit <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\resources/log4j.properties"</i> to configure Solr log settings:
- Increase the log rotation size threshold (_log4j\.appender\.file\.MaxFileSize_) from 4MB to 100MB.
- Remove the _CONSOLE_ appender from the _log4j\.rootLogger_ line.
<br><br>
@ -80,40 +79,26 @@ The following steps will configure Solr to run using an account that will have a
<br><br>
\image html log4j.PNG
<br><br>
6. From an Autopsy installation, copy the folder <i>"C:\Program Files\Autopsy-XXX(current version)\autopsy\solr\solr\configsets"</i> to <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\configsets"</i>.
7. From an Autopsy installation, copy the folder <i>"C:\Program Files\Autopsy-XXX(current version)\autopsy\solr\solr\lib"</i> to <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\lib"</i>.
5. From an Autopsy installation, copy the folder <i>"C:\Program Files\Autopsy-XXX(current version)\autopsy\solr\solr\configsets"</i> to <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\solr"</i>.
6. From an Autopsy installation, copy the folder <i>"C:\Program Files\Autopsy-XXX(current version)\autopsy\solr\solr\lib"</i> to <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\solr"</i>.
\subsection configure_Zookeeper Zookeeper Configuration
The following steps will configure Zookeeper.
1. Stop the <i>solrJetty</i> service by pressing <i>Start</i>, typing <i>services.msc</i>, pressing Enter, and locating the <i>solrJetty</i> Windows service. Select the service and press <i>Stop the service</i>. If the service is already stopped and there is no <i>Stop the service</i> available, this is okay.
2. Start a Windows command prompt as administrator by pressing Start, typing <i>command</i>, right clicking on <i>Command Prompt</i>, and clicking on <i>Run as administrator</i>. Then run the following command to uninstall the solrJetty service:
cmd /c C:\Bitnami\solr-6.2.1-2\apache-solr\scripts\serviceinstall.bat UNINSTALL
cmd /c C:\Bitnami\solr-4.10.3-0\apache-solr\scripts\serviceinstall.bat UNINSTALL
You will very likely see a result that says "The solrJetty service is not started." This is okay.
3. Create a folder <i>"C:\Bitnami\zookeeper"</i> if it does not exist.
4. Edit <i>"C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\zoo.cfg"</i> to include the text <i>dataDir=C:/Bitnami/zookeeper</i> as shown in the screenshot below
4. Edit <i>"C:\Bitnami\solr-4.10.3-0\apache-solr\server\solr\zoo.cfg"</i> to include the text <i>dataDir=C:/Bitnami/zookeeper</i> as shown in the screenshot below
<br><br>
\image html zooDir.PNG
<br>
5. Edit <i> "C:\Bitnami\solr-6.2.1-2\apache-solr\server\solr\zoo.cfg"</i> to include the text
<br>
<br>
- <i>autopurge.snapRetainCount=3</i>
<br> # ZooKeeper auto purge feature retains the autopurge.snapRetainCount most recent snapshots and the corresponding transaction logs in the dataDir and dataLogDir respectively and deletes the rest. Defaults to 3. Minimum value is 3.
<br>
- <i>autopurge.purgeInterval=24</i>
<br> # The time interval in hours for which the purge task has to be triggered. Set to a positive integer (1 and above) to enable the auto purging. Defaults to 0.
<br>
<br>
as shown in yellow in the screenshot below
<br><br>
\image html zooPurge.PNG
<br>
6. Start a Windows command prompt as administrator by pressing Start, typing <i>command</i>, right clicking on <i>Command Prompt</i>, and clicking on <i>Run as administrator</i>. Then run the following command to install the solrJetty service:
5. Start a Windows command prompt as administrator by pressing Start, typing <i>command</i>, right clicking on <i>Command Prompt</i>, and clicking on <i>Run as administrator</i>. Then run the following command to install the solrJetty service:
cmd /c C:\Bitnami\solr-6.2.1-2\apache-solr\scripts\serviceinstall.bat INSTALL
cmd /c C:\Bitnami\solr-4.10.3-0\apache-solr\scripts\serviceinstall.bat INSTALL
<br> Note the argument "INSTALL" is case sensitive. Your command prompt should look like the screenshot below. Very likely your command prompt will say "The solrJetty service could not be started." This is okay.
<br><br>
\image html solrinstall1.PNG

View File

@ -127,7 +127,7 @@ class SampleJythonDataSourceIngestModule(DataSourceIngestModule):
numFiles = len(files)
self.log(Level.INFO, "found " + str(numFiles) + " files")
progressBar.switchToDeterminate(numFiles)
fileCount = 0;
fileCount = 0
for file in files:
# Check if the user pressed cancel while we were busy
@ -169,4 +169,4 @@ class SampleJythonDataSourceIngestModule(DataSourceIngestModule):
"Sample Jython Data Source Ingest Module", "Found %d files" % fileCount)
IngestServices.getInstance().postMessage(message)
return IngestModule.ProcessResult.OK;
return IngestModule.ProcessResult.OK

View File

@ -110,8 +110,8 @@ class SampleJythonFileIngestModule(FileIngestModule):
# TODO: Add your analysis code in here.
def process(self, file):
# Skip non-files
if ((file.getType() == TskData.TSK_DB_FILES_TYPE_ENUM.UNALLOC_BLOCKS) or
(file.getType() == TskData.TSK_DB_FILES_TYPE_ENUM.UNUSED_BLOCKS) or
if ((file.getType() == TskData.TSK_DB_FILES_TYPE_ENUM.UNALLOC_BLOCKS) or
(file.getType() == TskData.TSK_DB_FILES_TYPE_ENUM.UNUSED_BLOCKS) or
(file.isFile() == False)):
return IngestModule.ProcessResult.OK
@ -128,7 +128,7 @@ class SampleJythonFileIngestModule(FileIngestModule):
# Make an artifact on the blackboard. TSK_INTERESTING_FILE_HIT is a generic type of
# artifact. Refer to the developer docs for other examples.
art = file.newArtifact(BlackboardArtifact.ARTIFACT_TYPE.TSK_INTERESTING_FILE_HIT)
att = BlackboardAttribute(BlackboardAttribute.ATTRIBUTE_TYPE.TSK_SET_NAME,
att = BlackboardAttribute(BlackboardAttribute.ATTRIBUTE_TYPE.TSK_SET_NAME,
SampleJythonFileIngestModuleFactory.moduleName, "Text Files")
art.addAttribute(att)
@ -141,15 +141,15 @@ class SampleJythonFileIngestModule(FileIngestModule):
# Fire an event to notify the UI and others that there is a new artifact
IngestServices.getInstance().fireModuleDataEvent(
ModuleDataEvent(SampleJythonFileIngestModuleFactory.moduleName,
BlackboardArtifact.ARTIFACT_TYPE.TSK_INTERESTING_FILE_HIT, None));
ModuleDataEvent(SampleJythonFileIngestModuleFactory.moduleName,
BlackboardArtifact.ARTIFACT_TYPE.TSK_INTERESTING_FILE_HIT, None))
# For the example (this wouldn't be needed normally), we'll query the blackboard for data that was added
# by other modules. We then iterate over its attributes. We'll just print them, but you would probably
# want to do something with them.
# want to do something with them.
artifactList = file.getArtifacts(BlackboardArtifact.ARTIFACT_TYPE.TSK_INTERESTING_FILE_HIT)
for artifact in artifactList:
attributeList = artifact.getAttributes();
attributeList = artifact.getAttributes()
for attrib in attributeList:
self.log(Level.INFO, attrib.toString())
@ -169,6 +169,6 @@ class SampleJythonFileIngestModule(FileIngestModule):
def shutDown(self):
# As a final part of this example, we'll send a message to the ingest inbox with the number of files found (in this thread)
message = IngestMessage.createMessage(
IngestMessage.MessageType.DATA, SampleJythonFileIngestModuleFactory.moduleName,
IngestMessage.MessageType.DATA, SampleJythonFileIngestModuleFactory.moduleName,
str(self.filesFound) + " files found")
ingestServices = IngestServices.getInstance().postMessage(message)

View File

@ -71,7 +71,7 @@ class SampleGeneralReportModule(GeneralReportModuleAdapter):
# The 'progressBar' object is of type ReportProgressPanel.
# See: http://sleuthkit.org/autopsy/docs/api-docs/3.1/classorg_1_1sleuthkit_1_1autopsy_1_1report_1_1_report_progress_panel.html
def generateReport(self, baseReportDir, progressBar):
# For an example, we write a file with the number of files created in the past 2 weeks
# Configure progress bar for 2 tasks
progressBar.setIndeterminate(False)
@ -101,7 +101,7 @@ class SampleGeneralReportModule(GeneralReportModuleAdapter):
report.close()
# Add the report to the Case, so it is shown in the tree
Case.getCurrentCase().addReport(fileName, self.moduleName, "File Count Report");
Case.getCurrentCase().addReport(fileName, self.moduleName, "File Count Report")
progressBar.increment()