mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-13 00:16:16 +00:00
Merge pull request #7008 from markmckinnon/7649-ArrayIndexOutOfBoundsException-in-Recent-Activity
7649-ArrayIndexOutOfBoundsException-in-Recent-Activity
This commit is contained in:
commit
814f8b09d4
@ -1434,21 +1434,23 @@ class ExtractRegistry extends Extract {
|
|||||||
&& !line.contains(("Recent File List"))) {
|
&& !line.contains(("Recent File List"))) {
|
||||||
// Split line on "> " which is the record delimiter between position and file
|
// Split line on "> " which is the record delimiter between position and file
|
||||||
String tokens[] = line.split("> ");
|
String tokens[] = line.split("> ");
|
||||||
String fileName = tokens[1];
|
if (tokens.length > 1) {
|
||||||
Collection<BlackboardAttribute> attributes = new ArrayList<>();
|
String fileName = tokens[1];
|
||||||
attributes.add(new BlackboardAttribute(TSK_PATH, getName(), fileName));
|
Collection<BlackboardAttribute> attributes = new ArrayList<>();
|
||||||
attributes.add(new BlackboardAttribute(TSK_COMMENT, getName(), comment));
|
attributes.add(new BlackboardAttribute(TSK_PATH, getName(), fileName));
|
||||||
try{
|
attributes.add(new BlackboardAttribute(TSK_COMMENT, getName(), comment));
|
||||||
BlackboardArtifact bba = createArtifactWithAttributes(ARTIFACT_TYPE.TSK_RECENT_OBJECT, regFile, attributes);
|
try{
|
||||||
if (bba != null) {
|
BlackboardArtifact bba = createArtifactWithAttributes(ARTIFACT_TYPE.TSK_RECENT_OBJECT, regFile, attributes);
|
||||||
bbartifacts.add(bba);
|
|
||||||
bba = createAssociatedArtifact(FilenameUtils.normalize(fileName, true), bba);
|
|
||||||
if (bba != null) {
|
if (bba != null) {
|
||||||
bbartifacts.add(bba);
|
bbartifacts.add(bba);
|
||||||
|
bba = createAssociatedArtifact(FilenameUtils.normalize(fileName, true), bba);
|
||||||
|
if (bba != null) {
|
||||||
|
bbartifacts.add(bba);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
} catch(TskCoreException ex) {
|
||||||
|
logger.log(Level.SEVERE, String.format("Failed to create TSK_RECENT_OBJECT artifact for file %d", regFile.getId()), ex);
|
||||||
}
|
}
|
||||||
} catch(TskCoreException ex) {
|
|
||||||
logger.log(Level.SEVERE, String.format("Failed to create TSK_RECENT_OBJECT artifact for file %d", regFile.getId()), ex);
|
|
||||||
}
|
}
|
||||||
line = reader.readLine();
|
line = reader.readLine();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user