mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-13 08:26:15 +00:00
Added XML file save to HasDb.openDatabase()
This commit is contained in:
parent
934463bd7d
commit
58ce29be25
@ -85,12 +85,14 @@ public class HashDb implements Comparable<HashDb> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static private void addToXMLFile(HashDb database) {
|
static private void addToXMLFile(HashDb database) {
|
||||||
|
HashDbXML xmlFileManager = HashDbXML.getCurrent();
|
||||||
if (database.getDbType() == HashDb.DBType.NSRL) {
|
if (database.getDbType() == HashDb.DBType.NSRL) {
|
||||||
HashDbXML.getCurrent().setNSRLSet(database);
|
xmlFileManager.setNSRLSet(database);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
HashDbXML.getCurrent().addKnownBadSet(database);
|
xmlFileManager.addKnownBadSet(database);
|
||||||
}
|
}
|
||||||
|
xmlFileManager.save();
|
||||||
}
|
}
|
||||||
|
|
||||||
static public List<HashDb> getUpdateableHashDatabases() {
|
static public List<HashDb> getUpdateableHashDatabases() {
|
||||||
|
@ -306,7 +306,7 @@ final class HashDbImportDatabaseDialog extends javax.swing.JDialog {
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
HashDb db = HashDb.openHashDatabase(databaseNameTextField.getText(), databasePathTextField.getText(), useForIngestCheckbox.isSelected(), sendInboxMessagesCheckbox.isSelected(), type);
|
HashDb.openHashDatabase(databaseNameTextField.getText(), databasePathTextField.getText(), useForIngestCheckbox.isSelected(), sendInboxMessagesCheckbox.isSelected(), type);
|
||||||
} catch (TskException ex) {
|
} catch (TskException ex) {
|
||||||
logger.log(Level.WARNING, "Invalid database: ", ex);
|
logger.log(Level.WARNING, "Invalid database: ", ex);
|
||||||
JOptionPane.showMessageDialog(this, "Database file you chose cannot be opened.\n" + "If it was just an index, please try to recreate it from the database");
|
JOptionPane.showMessageDialog(this, "Database file you chose cannot be opened.\n" + "If it was just an index, please try to recreate it from the database");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user