Autopsy  4.19.0
Graphical digital forensics platform for The Sleuth Kit and other tools.
Static Public Member Functions | Private Member Functions | Static Private Member Functions | Static Private Attributes | List of all members
org.sleuthkit.autopsy.discovery.search.FileSearch Class Reference

Static Public Member Functions

static List< ResultgetFilesInGroup (String userName, List< AbstractFilter > filters, AttributeType groupAttributeType, Group.GroupSortingAlgorithm groupSortingType, ResultsSorter.SortingMethod fileSortingMethod, GroupKey groupKey, int startingEntry, int numberOfEntries, SleuthkitCase caseDb, CentralRepository centralRepoDb) throws DiscoveryException
 
static Map< GroupKey, Integer > getGroupSizes (String userName, List< AbstractFilter > filters, AttributeType groupAttributeType, Group.GroupSortingAlgorithm groupSortingType, ResultsSorter.SortingMethod fileSortingMethod, SleuthkitCase caseDb, CentralRepository centralRepoDb) throws DiscoveryException
 
static TextSummary summarize (AbstractFile file)
 

Private Member Functions

 FileSearch ()
 

Static Private Member Functions

static void addAttributes (List< AttributeType > attrs, List< Result > results, SleuthkitCase caseDb, CentralRepository centralRepoDb) throws DiscoveryException
 
static Map< GroupKey, List< Result > > runFileSearch (String userName, List< AbstractFilter > filters, AttributeType groupAttributeType, Group.GroupSortingAlgorithm groupSortingType, ResultsSorter.SortingMethod fileSortingMethod, SleuthkitCase caseDb, CentralRepository centralRepoDb) throws DiscoveryException
 

Static Private Attributes

static final Logger logger = Logger.getLogger(FileSearch.class.getName())
 
static final int MAXIMUM_CACHE_SIZE = 10
 
static final Cache< SearchKey, Map< GroupKey, List< Result > > > searchCache
 

Detailed Description

Main class to perform the file search.

Definition at line 44 of file FileSearch.java.

Constructor & Destructor Documentation

org.sleuthkit.autopsy.discovery.search.FileSearch.FileSearch ( )
private

Definition at line 308 of file FileSearch.java.

Member Function Documentation

static void org.sleuthkit.autopsy.discovery.search.FileSearch.addAttributes ( List< AttributeType attrs,
List< Result results,
SleuthkitCase  caseDb,
CentralRepository  centralRepoDb 
) throws DiscoveryException
staticprivate

Add any attributes corresponding to the attribute list to the given result files. For example, specifying the KeywordListAttribute will populate the list of keyword set names in the ResultFile objects.

Parameters
attrsThe attributes to add to the list of result files
resultsThe result files
caseDbThe case database
centralRepoDbThe central repository database. Can be null if not needed.
Exceptions
DiscoveryException

Definition at line 301 of file FileSearch.java.

Referenced by org.sleuthkit.autopsy.discovery.search.FileSearch.runFileSearch().

static List<Result> org.sleuthkit.autopsy.discovery.search.FileSearch.getFilesInGroup ( String  userName,
List< AbstractFilter filters,
AttributeType  groupAttributeType,
Group.GroupSortingAlgorithm  groupSortingType,
ResultsSorter.SortingMethod  fileSortingMethod,
GroupKey  groupKey,
int  startingEntry,
int  numberOfEntries,
SleuthkitCase  caseDb,
CentralRepository  centralRepoDb 
) throws DiscoveryException
static

Get the files from the specified group from the cache, if the the group was not cached perform a search caching the groups.

Parameters
userNameThe name of the user performing the search.
filtersThe filters to apply
groupAttributeTypeThe attribute to use for grouping
groupSortingTypeThe method to use to sort the groups
fileSortingMethodThe method to use to sort the files within the groups
groupKeyThe key which uniquely identifies the group to get entries from
startingEntryThe first entry to return
numberOfEntriesThe number of entries to return
caseDbThe case database
centralRepoDbThe central repository database. Can be null if not needed.
Returns
A LinkedHashMap grouped and sorted according to the parameters
Exceptions
DiscoveryException

Definition at line 159 of file FileSearch.java.

References org.sleuthkit.autopsy.discovery.search.FileSearch.runFileSearch(), and org.sleuthkit.autopsy.discovery.search.FileSearch.searchCache.

static Map<GroupKey, Integer> org.sleuthkit.autopsy.discovery.search.FileSearch.getGroupSizes ( String  userName,
List< AbstractFilter filters,
AttributeType  groupAttributeType,
Group.GroupSortingAlgorithm  groupSortingType,
ResultsSorter.SortingMethod  fileSortingMethod,
SleuthkitCase  caseDb,
CentralRepository  centralRepoDb 
) throws DiscoveryException
static

Run the file search to get the group keys and sizes. Clears cache of search results, caching new results for access at later time.

Parameters
userNameThe name of the user performing the search.
filtersThe filters to apply
groupAttributeTypeThe attribute to use for grouping
groupSortingTypeThe method to use to sort the groups
fileSortingMethodThe method to use to sort the files within the groups
caseDbThe case database
centralRepoDbThe central repository database. Can be null if not needed.
Returns
A LinkedHashMap grouped and sorted according to the parameters
Exceptions
DiscoveryException

Definition at line 122 of file FileSearch.java.

References org.sleuthkit.autopsy.discovery.search.FileSearch.runFileSearch().

static Map<GroupKey, List<Result> > org.sleuthkit.autopsy.discovery.search.FileSearch.runFileSearch ( String  userName,
List< AbstractFilter filters,
AttributeType  groupAttributeType,
Group.GroupSortingAlgorithm  groupSortingType,
ResultsSorter.SortingMethod  fileSortingMethod,
SleuthkitCase  caseDb,
CentralRepository  centralRepoDb 
) throws DiscoveryException
staticprivate

Run the file search. Caching new results for access at later time.

Parameters
userNameThe name of the user performing the search.
filtersThe filters to apply
groupAttributeTypeThe attribute to use for grouping
groupSortingTypeThe method to use to sort the groups
fileSortingMethodThe method to use to sort the files within the groups
caseDbThe case database
centralRepoDbThe central repository database. Can be null if not needed.
Returns
A LinkedHashMap grouped and sorted according to the parameters
Exceptions
DiscoveryException

Definition at line 255 of file FileSearch.java.

References org.sleuthkit.autopsy.discovery.search.FileSearch.addAttributes(), and org.sleuthkit.autopsy.discovery.search.FileSearch.searchCache.

Referenced by org.sleuthkit.autopsy.discovery.search.FileSearch.getFilesInGroup(), and org.sleuthkit.autopsy.discovery.search.FileSearch.getGroupSizes().

static TextSummary org.sleuthkit.autopsy.discovery.search.FileSearch.summarize ( AbstractFile  file)
static

Get a summary for the specified AbstractFile. If no TextSummarizers exist get the beginning of the file.

Parameters
fileThe AbstractFile to summarize.
Returns
The summary or beginning of the specified file as a String.

Definition at line 216 of file FileSearch.java.

References org.sleuthkit.autopsy.textsummarizer.TextSummary.getSummaryText(), org.sleuthkit.autopsy.discovery.search.FileSearch.searchCache, and org.sleuthkit.autopsy.textsummarizer.TextSummarizer.summarize().

Referenced by org.sleuthkit.autopsy.discovery.ui.ResultsPanel.DocumentPreviewWorker.doInBackground().

Member Data Documentation

final Logger org.sleuthkit.autopsy.discovery.search.FileSearch.logger = Logger.getLogger(FileSearch.class.getName())
staticprivate

Definition at line 46 of file FileSearch.java.

final int org.sleuthkit.autopsy.discovery.search.FileSearch.MAXIMUM_CACHE_SIZE = 10
staticprivate

Definition at line 47 of file FileSearch.java.

final Cache<SearchKey, Map<GroupKey, List<Result> > > org.sleuthkit.autopsy.discovery.search.FileSearch.searchCache
staticprivate

The documentation for this class was generated from the following file:

Copyright © 2012-2021 Basis Technology. Generated on: Fri Aug 6 2021
This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.