1
0
mirror of https://github.com/elisspace/autopsy.git synced 2026-09-06 02:24:30 +00:00
This commit is contained in:
adam-m
2012-03-30 13:57:43 -04:00
18 changed files with 141 additions and 311 deletions

View File

@@ -67,7 +67,7 @@ abstract class AbstractContentChildren extends Keys<Object> {
/**
* Creates appropriate Node for each sub-class of Content
*/
static class CreateSleuthkitNodeVisitor extends SleuthkitItemVisitor.Default<AbstractContentNode> {
public static class CreateSleuthkitNodeVisitor extends SleuthkitItemVisitor.Default<AbstractContentNode> {
@Override
public AbstractContentNode visit(Directory drctr) {

View File

@@ -161,16 +161,23 @@ public abstract class AbstractFsContentNode<T extends FsContent> extends Abstrac
},
}
private boolean hideParentPath;
private boolean directoryBrowseMode;
public static final String HIDE_PARENT = "hide_parent";
AbstractFsContentNode(T fsContent) {
this(fsContent, true);
}
AbstractFsContentNode(T fsContent, boolean hideParentPath) {
// The param 'directoryBrowseMode' refers to how the user caused this node
// to be created: if by browsing the image contents, it is true. If by
// selecting a file filter (e.g. 'type' or 'recent'), it is false
AbstractFsContentNode(T fsContent, boolean directoryBrowseMode) {
super(fsContent);
this.hideParentPath = hideParentPath;
this.directoryBrowseMode = directoryBrowseMode;
}
public boolean getDirectoryBrowseMode() {
return directoryBrowseMode;
}
@Override
@@ -193,7 +200,7 @@ public abstract class AbstractFsContentNode<T extends FsContent> extends Abstrac
final String propString = propType.toString();
ss.put(new NodeProperty(propString, propString, NO_DESCR, map.get(propString)));
}
if(hideParentPath) {
if(directoryBrowseMode) {
ss.put(new NodeProperty(HIDE_PARENT, HIDE_PARENT, HIDE_PARENT, HIDE_PARENT));
}

View File

@@ -177,10 +177,6 @@ public class BlackboardArtifactNode extends AbstractNode implements DisplayableI
}
return null;
}
public Node getContentNode() {
return associated.accept(new AbstractContentChildren.CreateSleuthkitNodeVisitor());
}
private class NameVisitor extends SleuthkitItemVisitor.Default<String> {

View File

@@ -37,13 +37,17 @@ public class DirectoryNode extends AbstractFsContentNode<Directory> {
static String nameForDirectory(Directory d) {
return d.getName();
}
public DirectoryNode(Directory dir) {
this(dir, true);
}
/**
*
* @param dir Underlying Content instance
*/
public DirectoryNode(Directory dir) {
super(dir);
public DirectoryNode(Directory dir, boolean directoryBrowseMode) {
super(dir, directoryBrowseMode);
// set name, display name, and icon
String dirName = nameForDirectory(dir);

View File

@@ -48,8 +48,8 @@ public class FileNode extends AbstractFsContentNode<File> {
this(file, true);
}
public FileNode(File file, boolean hideParentPath) {
super(file, hideParentPath);
public FileNode(File file, boolean directoryBrowseMode) {
super(file, directoryBrowseMode);
// set name, display name, and icon
String fileName = nameForFile(file);

View File

@@ -21,6 +21,8 @@ package org.sleuthkit.autopsy.datamodel;
import java.util.Collection;
import java.util.Collections;
import java.util.logging.Logger;
import org.sleuthkit.datamodel.BlackboardArtifact;
/**
* Children implementation for the root node of a ContentNode tree. Accepts a
@@ -47,9 +49,22 @@ public class RootContentChildren extends AbstractContentChildren {
setKeys(Collections.<Object>emptySet());
}
public void refreshKeys() {
public void refreshKeys(BlackboardArtifact.ARTIFACT_TYPE type) {
for(Object o : contentKeys){
this.refreshKey(o);
switch(type) {
case TSK_HASHSET_HIT:
if(o instanceof HashsetHits)
this.refreshKey(o);
break;
case TSK_KEYWORD_HIT:
if(o instanceof KeywordHits)
this.refreshKey(o);
break;
default:
if(o instanceof ExtractedContent)
this.refreshKey(o);
break;
}
}
}
}

View File

@@ -137,7 +137,7 @@ public class DataResultFilterNode extends FilterNode{
@Override
public List<Action> visit(ImageNode img) {
List<Action> actions = new ArrayList<Action>();
actions.add(new NewWindowViewAction("View in New Window", getOriginal()));
actions.add(new NewWindowViewAction("View in New Window", img));
actions.addAll(ShowDetailActionVisitor.getActions(img.getLookup().lookup(Content.class)));
return actions;
}
@@ -145,9 +145,9 @@ public class DataResultFilterNode extends FilterNode{
@Override
public List<Action> visit(VolumeNode vol) {
List<Action> actions = new ArrayList<Action>();
actions.add(new NewWindowViewAction("View in New Window", getOriginal()));
actions.add(new NewWindowViewAction("View in New Window", vol));
actions.addAll(ShowDetailActionVisitor.getActions(vol.getLookup().lookup(Content.class)));
actions.add(new ChangeViewAction("View", 0, getOriginal()));
actions.add(new ChangeViewAction("View", 0, vol));
return actions;
}
@@ -155,26 +155,30 @@ public class DataResultFilterNode extends FilterNode{
@Override
public List<Action> visit(DirectoryNode dir) {
List<Action> actions = new ArrayList<Action>();
actions.add(new NewWindowViewAction("View in New Window", getOriginal()));
actions.add(new ChangeViewAction("View", 0, getOriginal()));
actions.add(new ExtractAction("Extract Directory", getOriginal()));
actions.add(new NewWindowViewAction("View in New Window", dir));
actions.add(new ChangeViewAction("View", 0, dir));
actions.add(new ExtractAction("Extract Directory", dir));
if(!dir.getDirectoryBrowseMode())
actions.add(new ViewContextAction("View in Parent Directory", dir));
return actions;
}
@Override
public List<Action> visit(FileNode f) {
List<Action> actions = new ArrayList<Action>();
actions.add(new NewWindowViewAction("View in New Window", getOriginal()));
actions.add(new ExternalViewerAction("Open in External Viewer", getOriginal()));
actions.add(new ExtractAction("Extract File", getOriginal()));
actions.add(new NewWindowViewAction("View in New Window", f));
actions.add(new ExternalViewerAction("Open in External Viewer", f));
actions.add(new ExtractAction("Extract File", f));
if(!f.getDirectoryBrowseMode())
actions.add(new ViewContextAction("View in Parent Directory", f));
return actions;
}
@Override
public List<Action> visit(BlackboardArtifactNode ba) {
List<Action> actions = new ArrayList<Action>();
actions.add(new ViewAssociatedContentAction("View Associated Content", getOriginal()));
actions.add(new ViewContextAction("View in Directory", getOriginal()));
//actions.add(new ViewAssociatedContentAction("View Associated Content", ba));
actions.add(new ViewContextAction("View in Directory", ba));
return actions;
}
@@ -219,7 +223,7 @@ public class DataResultFilterNode extends FilterNode{
@Override
public AbstractAction visit(BlackboardArtifactNode ban){
return new ViewContextAction("View in Directory", getOriginal());
return new ViewContextAction("View in Directory", ban);
}
@Override

View File

@@ -62,6 +62,7 @@ import org.sleuthkit.autopsy.datamodel.RootContentChildren;
import org.sleuthkit.autopsy.datamodel.Views;
import org.sleuthkit.autopsy.datamodel.ViewsNode;
import org.sleuthkit.autopsy.ingest.IngestManager;
import org.sleuthkit.autopsy.ingest.ServiceDataEvent;
import org.sleuthkit.datamodel.BlackboardArtifact;
import org.sleuthkit.datamodel.BlackboardAttribute;
import org.sleuthkit.datamodel.Content;
@@ -673,7 +674,14 @@ public final class DirectoryTreeTopComponent extends TopComponent implements Dat
}
if (changed.equals(IngestManager.SERVICE_HAS_DATA_EVT)) {
refreshTree();
final ServiceDataEvent event = (ServiceDataEvent) oldValue;
SwingUtilities.invokeLater(new Runnable() {
@Override
public void run() {
refreshTree(event.getArtifactType());
}
}
);
}
}
@@ -710,47 +718,49 @@ public final class DirectoryTreeTopComponent extends TopComponent implements Dat
/**
* Refreshes the nodes in the tree to reflect updates in the database
*
* should be called in the gui thread
*/
public void refreshTree() {
private void refreshTree(final BlackboardArtifact.ARTIFACT_TYPE type) {
Node selected = getSelectedNode();
final String[] path = NodeOp.createPath(selected, em.getRootContext());
//TODO: instead, we should choose a specific key to refresh? Maybe?
//contentChildren.refreshKeys();
Children dirChilds = em.getRootContext().getChildren();
Node results = dirChilds.findChild(ResultsNode.NAME);
OriginalNode original = results.getLookup().lookup(OriginalNode.class);
ResultsNode resultsNode = (ResultsNode) original.getNode();
RootContentChildren resultsNodeChilds = (RootContentChildren) resultsNode.getChildren();
resultsNodeChilds.refreshKeys(type);
final TreeView tree = getTree();
tree.expandNode(results);
Children resultsChilds = results.getChildren();
tree.expandNode(resultsChilds.findChild(KeywordHits.NAME));
tree.expandNode(resultsChilds.findChild(ExtractedContentNode.NAME));
SwingUtilities.invokeLater(new Runnable() {
@Override
public void run() {
Node selected = getSelectedNode();
String[] path = NodeOp.createPath(selected, em.getRootContext());
//TODO: instead, we should choose a specific key to refresh? Maybe?
contentChildren.refreshKeys();
Children dirChilds = em.getRootContext().getChildren();
TreeView tree = getTree();
Node results = dirChilds.findChild(ResultsNode.NAME);
tree.expandNode(results);
Children resultsChilds = results.getChildren();
tree.expandNode(resultsChilds.findChild(KeywordHits.NAME));
tree.expandNode(resultsChilds.findChild(ExtractedContentNode.NAME));
Node views = dirChilds.findChild(ViewsNode.NAME);
Children viewsChilds = views.getChildren();
for(Node n : viewsChilds.getNodes()) {
tree.expandNode(n);
}
tree.collapseNode(views);
try {
Node newSelection = NodeOp.findPath(em.getRootContext(), path);
resetHistoryListAndButtons();
tree.expandNode(newSelection);
em.setExploredContextAndSelection(newSelection, new Node[]{newSelection});
// We need to set the selection, which will refresh dataresult and get rid of the oob exception
} catch (NodeNotFoundException ex) {
logger.log(Level.WARNING, "Node not found", ex);
} catch (PropertyVetoException ex) {
logger.log(Level.WARNING, "Property Veto", ex);
if (path.length > 0 && path[0].equals(ResultsNode.NAME)) {
try {
Node newSelection = NodeOp.findPath(em.getRootContext(), path);
resetHistoryListAndButtons();
tree.expandNode(newSelection);
em.setExploredContextAndSelection(newSelection, new Node[]{newSelection});
// We need to set the selection, which will refresh dataresult and get rid of the oob exception
} catch (NodeNotFoundException ex) {
logger.log(Level.WARNING, "Node not found", ex);
} catch (PropertyVetoException ex) {
logger.log(Level.WARNING, "Property Veto", ex);
}
}
}
});

View File

@@ -20,24 +20,25 @@ package org.sleuthkit.autopsy.directorytree;
import java.awt.event.ActionEvent;
import javax.swing.AbstractAction;
import org.openide.nodes.Node;
import org.sleuthkit.autopsy.corecomponents.DataContentTopComponent;
import org.sleuthkit.autopsy.datamodel.BlackboardArtifactNode;
import org.sleuthkit.autopsy.datamodel.RootContentChildren;
import org.sleuthkit.datamodel.Content;
/**
* View the content associated with the given BlackboardArtifactNode
*/
class ViewAssociatedContentAction extends AbstractAction {
private BlackboardArtifactNode node;
private Content content;
public ViewAssociatedContentAction(String title, Node node) {
public ViewAssociatedContentAction(String title, BlackboardArtifactNode node) {
super(title);
this.node = (BlackboardArtifactNode) node;
this.content = node.getLookup().lookup(Content.class);
}
@Override
public void actionPerformed(ActionEvent e) {
DataContentTopComponent.getDefault().setNode(node.getContentNode());
DataContentTopComponent.getDefault().setNode(content.accept(new RootContentChildren.CreateSleuthkitNodeVisitor()));
}
}

View File

@@ -33,6 +33,7 @@ import org.openide.nodes.AbstractNode;
import org.openide.nodes.Children;
import org.openide.nodes.Node;
import org.sleuthkit.autopsy.corecomponents.DataResultTopComponent;
import org.sleuthkit.autopsy.datamodel.AbstractFsContentNode;
import org.sleuthkit.autopsy.datamodel.BlackboardArtifactNode;
import org.sleuthkit.autopsy.datamodel.ImagesNode;
import org.sleuthkit.autopsy.datamodel.RootContentChildren;
@@ -53,12 +54,17 @@ import org.sleuthkit.datamodel.VolumeSystem;
*/
class ViewContextAction extends AbstractAction {
private BlackboardArtifactNode node;
private Content content;
private static final Logger logger = Logger.getLogger(ViewContextAction.class.getName());
public ViewContextAction(String title, Node node) {
public ViewContextAction(String title, BlackboardArtifactNode node) {
super(title);
this.node = (BlackboardArtifactNode) node;
this.content = node.getLookup().lookup(Content.class);
}
public ViewContextAction(String title, AbstractFsContentNode node) {
super(title);
this.content = node.getLookup().lookup(Content.class);
}
@Override
@@ -68,8 +74,7 @@ class ViewContextAction extends AbstractAction {
@Override
public void run() {
ReverseHierarchyVisitor vtor = new ReverseHierarchyVisitor();
Content c = node.getLookup().lookup(Content.class);
List<Content> hierarchy = c.accept(vtor);
List<Content> hierarchy = content.accept(vtor);
Collections.reverse(hierarchy);
Node generated = new DirectoryTreeFilterNode(new AbstractNode(new RootContentChildren(hierarchy)), true);
Children genChilds = generated.getChildren();
@@ -115,7 +120,7 @@ class ViewContextAction extends AbstractAction {
DataResultTopComponent dataResult = directoryTree.getDirectoryListing();
Node resultRoot = dataResult.getRootNode();
Children resultChilds = resultRoot.getChildren();
Node generated = node.getContentNode();
Node generated = content.accept(new RootContentChildren.CreateSleuthkitNodeVisitor());
for (int i = 0; i < resultChilds.getNodesCount(); i++) {
Node current = resultChilds.getNodeAt(i);
if (generated.getName().equals(current.getName())) {

View File

@@ -1,46 +0,0 @@
/*
* Autopsy Forensic Browser
*
* Copyright 2011 Basis Technology Corp.
* Contact: carrier <at> sleuthkit <dot> org
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.sleuthkit.autopsy.filesearch;
import org.openide.nodes.FilterNode;
import org.openide.nodes.Node;
/**
* This class is used for the creation of all the children for the
* DataResultFilterNode that created in the DataResultFilterNode.java.
*
* @author jantonius
*/
public class DataResultFilterChildren extends FilterNode.Children {
/** the constructor */
public DataResultFilterChildren(Node arg) {
super(arg);
}
@Override
protected Node copyNode(Node arg0) {
return new DataResultFilterNode(arg0);
}
@Override
protected Node[] createNodes(Node arg0) {
return new Node[]{this.copyNode(arg0)};
}
}

View File

@@ -1,96 +0,0 @@
/*
* Autopsy Forensic Browser
*
* Copyright 2011 Basis Technology Corp.
* Contact: carrier <at> sleuthkit <dot> org
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.sleuthkit.autopsy.filesearch;
import javax.swing.Action;
import org.openide.nodes.FilterNode;
import org.openide.nodes.Node;
import org.sleuthkit.autopsy.datamodel.ContentUtils;
import org.sleuthkit.autopsy.directorytree.ChangeViewAction;
import org.sleuthkit.autopsy.directorytree.ExternalViewerAction;
import org.sleuthkit.autopsy.directorytree.ExtractAction;
import org.sleuthkit.datamodel.Content;
import org.sleuthkit.datamodel.ContentVisitor;
import org.sleuthkit.datamodel.Directory;
import org.sleuthkit.datamodel.File;
/**
* This class wraps nodes as they are passed to the DataResult viewers. It
* defines the actions that the node should have.
*/
public class DataResultFilterNode extends FilterNode {
/** the constructor */
public DataResultFilterNode(Node arg) {
super(arg, new DataResultFilterChildren(arg));
}
/**
* Right click action for the nodes that we want to pass to the directory
* table and the output view.
*
* @param popup
* @return actions
*/
@Override
public Action[] getActions(boolean popup) {
Content content = getOriginal().getLookup().lookup(Content.class);
return content.accept(new GetActionContentVisitor());
}
private class GetActionContentVisitor extends ContentVisitor.Default<Action[]> {
@Override
public Action[] visit(Directory dir) {
return new Action[]{
new ExtractAction("Extract Directory", getOriginal()),
new ChangeViewAction("View", 0, getOriginal()),
new OpenParentFolderAction("Open Parent Directory", ContentUtils.getSystemPath(dir))
};
}
@Override
public Action[] visit(File f) {
return new Action[]{
new ExternalViewerAction("Open in External Viewer", getOriginal()),
new ExtractAction("Extract File", getOriginal()),
new ChangeViewAction("View", 0, getOriginal()),
new OpenParentFolderAction("Open Parent Directory", ContentUtils.getSystemPath(f))
};
}
@Override
protected Action[] defaultVisit(Content cntnt) {
return new Action[]{};
}
}
/**
* Double click action for the nodes that we want to pass to the directory
* table and the output view.
*
* @return action
*/
@Override
public Action getPreferredAction() {
return null;
}
}

View File

@@ -1,88 +0,0 @@
/*
* Autopsy Forensic Browser
*
* Copyright 2011 Basis Technology Corp.
* Contact: carrier <at> sleuthkit <dot> org
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.sleuthkit.autopsy.filesearch;
import java.awt.event.ActionEvent;
import java.util.Arrays;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.swing.AbstractAction;
import org.openide.explorer.ExplorerManager;
import org.openide.nodes.Node;
import org.openide.nodes.NodeOp;
import org.openide.windows.TopComponent;
import org.sleuthkit.autopsy.directorytree.DirectoryTreeTopComponent;
import org.sleuthkit.autopsy.coreutils.Log;
/**
* The action to open the parent folder of the given Node
*/
public class OpenParentFolderAction extends AbstractAction{
private String[] paths;
// for error handling
private String className = this.getClass().toString();
public OpenParentFolderAction(String title, String[] paths){
super(title);
this.paths = paths;
}
@Override
public void actionPerformed(ActionEvent e) {
Log.noteAction(this.getClass());
try {
ExplorerManager em = DirectoryTreeTopComponent.findInstance().getExplorerManager();
Node root = em.getRootContext();
if(paths.length > 1 && root != null) {
String[] parentPath = Arrays.copyOf(paths, paths.length - 1);
Node parentNode = NodeOp.findPath(root, parentPath);
em.setExploredContextAndSelection(parentNode, new Node[]{parentNode});
TopComponent dirTree = DirectoryTreeTopComponent.findInstance();
if(!dirTree.isOpened()){ dirTree.open(); }
dirTree.requestActive(); // make the directory tree the active top component
// TopComponent resultTable = new DataResultTopComponent();
// if(!resultTable.isOpened()){ resultTable.open(); }
// resultTable.requestActive(); // make the directory tree the active top component
((DirectoryTreeTopComponent)dirTree).setDirectoryListingActive();
// make the node table the active top component
// @@@ Make the node table the active top component
}
} catch (Exception ex) {
// throw an error here
Logger.getLogger(this.className).log(Level.WARNING, "Error: error while trying to open the parent directory.", ex);
}
}
}

View File

@@ -27,6 +27,8 @@ import org.sleuthkit.datamodel.Directory;
import org.sleuthkit.autopsy.datamodel.DirectoryNode;
import org.sleuthkit.datamodel.File;
import org.sleuthkit.autopsy.datamodel.FileNode;
import org.sleuthkit.autopsy.directorytree.DataResultFilterNode;
import org.sleuthkit.autopsy.directorytree.DirectoryTreeTopComponent;
import org.sleuthkit.datamodel.FsContent;
@@ -45,13 +47,13 @@ class SearchChildren extends Children.Keys<FsContent> {
protected Node[] createNodes(FsContent t) {
Node[] node = new Node[1];
if(t.isDir()){
node[0] = new DataResultFilterNode(new DirectoryNode((Directory) t));
node[0] = new DataResultFilterNode(new DirectoryNode((Directory) t, false), DirectoryTreeTopComponent.findInstance().getExplorerManager());
//node[0] = new DirectoryNode((Directory)t);
return node;
}
else{
node[0] = new DataResultFilterNode(new FileNode((File)t));
node[0] = new DataResultFilterNode(new FileNode((File)t, false), DirectoryTreeTopComponent.findInstance().getExplorerManager());
//node[0] = new FileNode((File)t);
return node;
}

View File

@@ -18,8 +18,9 @@ import java.util.*;
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
import java.util.Map.Entry;
import org.sleuthkit.autopsy.ingest.IngestImageWorkerController;
import org.sleuthkit.autopsy.ingest.IngestManager;
import org.sleuthkit.autopsy.ingest.ServiceDataEvent;
import org.sleuthkit.datamodel.BlackboardArtifact;
import org.sleuthkit.datamodel.BlackboardArtifact.ARTIFACT_TYPE;
import org.sleuthkit.datamodel.BlackboardAttribute;
@@ -107,6 +108,7 @@ public class Chrome {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_HISTORY));
}
catch (SQLException ex)
{
@@ -172,6 +174,7 @@ public class Chrome {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_COOKIE));
}
catch (SQLException ex)
{
@@ -236,7 +239,7 @@ public class Chrome {
bbattributes.add(new BlackboardAttribute(ATTRIBUTE_TYPE.TSK_NAME.getTypeID(), "RecentActivity","",name));
bbattributes.add(new BlackboardAttribute(ATTRIBUTE_TYPE.TSK_PROG_NAME.getTypeID(),"RecentActivity","","Chrome"));
bbart.addAttributes(bbattributes);
}
}
}
@@ -247,6 +250,7 @@ public class Chrome {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_BOOKMARK));
}
catch (SQLException ex)
{
@@ -305,6 +309,7 @@ public class Chrome {
}
tempdbconnect.closeConnection();
temprs.close();
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_DOWNLOAD));
}
catch (Exception ex)
@@ -381,6 +386,7 @@ public class Chrome {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_HISTORY));
}
catch (SQLException ex)
{

View File

@@ -46,6 +46,8 @@ import org.sleuthkit.autopsy.casemodule.Case;
import org.sleuthkit.autopsy.datamodel.ContentUtils;
import org.sleuthkit.autopsy.datamodel.KeyValue;
import org.sleuthkit.autopsy.ingest.IngestImageWorkerController;
import org.sleuthkit.autopsy.ingest.IngestManager;
import org.sleuthkit.autopsy.ingest.ServiceDataEvent;
import org.sleuthkit.datamodel.BlackboardArtifact;
import org.sleuthkit.datamodel.BlackboardArtifact.ARTIFACT_TYPE;
import org.sleuthkit.datamodel.BlackboardAttribute;
@@ -127,6 +129,7 @@ public class ExtractIE { // implements BrowserActivity {
bbattributes.add(new BlackboardAttribute(ATTRIBUTE_TYPE.TSK_NAME.getTypeID(), "RecentActivity","",name));
bbattributes.add(new BlackboardAttribute(ATTRIBUTE_TYPE.TSK_PROG_NAME.getTypeID(),"RecentActivity","","Internet Explorer"));
bbart.addAttributes(bbattributes);
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_BOOKMARK));
}
}
@@ -182,6 +185,8 @@ public class ExtractIE { // implements BrowserActivity {
bbart.addAttributes(bbattributes);
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_COOKIE));
}
catch(TskException ex)
{
@@ -423,5 +428,7 @@ public class ExtractIE { // implements BrowserActivity {
}
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_HISTORY));
}
}

View File

@@ -17,6 +17,8 @@ import java.util.*;
import java.io.File;
import java.io.IOException;
import org.sleuthkit.autopsy.ingest.IngestImageWorkerController;
import org.sleuthkit.autopsy.ingest.IngestManager;
import org.sleuthkit.autopsy.ingest.ServiceDataEvent;
import org.sleuthkit.datamodel.BlackboardArtifact;
import org.sleuthkit.datamodel.BlackboardArtifact.*;
import org.sleuthkit.datamodel.BlackboardArtifact.ARTIFACT_TYPE;
@@ -131,6 +133,8 @@ public class Firefox {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_HISTORY));
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_BOOKMARK));
}
catch (SQLException ex)
{
@@ -198,6 +202,7 @@ public class Firefox {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_COOKIE));
}
catch (SQLException ex)
{
@@ -266,6 +271,7 @@ public class Firefox {
j++;
dbFile.delete();
}
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_DOWNLOAD));
}
catch (SQLException ex)
{

View File

@@ -117,9 +117,6 @@ public final class RAImageIngestService implements IngestServiceImage {
@Override
public void complete() {
logger.log(Level.INFO, "complete() " + this.toString());
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_BOOKMARK));
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_COOKIE));
IngestManager.fireServiceDataEvent(new ServiceDataEvent("Recent Activity", BlackboardArtifact.ARTIFACT_TYPE.TSK_WEB_HISTORY));
final IngestMessage msg = IngestMessage.createMessage(++messageId, MessageType.INFO, this, "Completed");
managerProxy.postMessage(msg);