mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-13 16:36:15 +00:00
Merge pull request #3002 from wschaeferB/2934-ModifyCentralRepoConfigGUI
2934 modify central repo config gui
This commit is contained in:
commit
f88929e061
@ -36,8 +36,11 @@ public interface EamDb {
|
|||||||
* @throws EamDbException
|
* @throws EamDbException
|
||||||
*/
|
*/
|
||||||
static EamDb getInstance() throws EamDbException {
|
static EamDb getInstance() throws EamDbException {
|
||||||
EamDbPlatformEnum selectedPlatform = EamDbPlatformEnum.getSelectedPlatform();
|
|
||||||
|
|
||||||
|
EamDbPlatformEnum selectedPlatform = EamDbPlatformEnum.DISABLED;
|
||||||
|
if (EamDbUtil.useCentralRepo()) {
|
||||||
|
selectedPlatform = EamDbPlatformEnum.getSelectedPlatform();
|
||||||
|
}
|
||||||
switch (selectedPlatform) {
|
switch (selectedPlatform) {
|
||||||
case POSTGRESQL:
|
case POSTGRESQL:
|
||||||
return PostgresEamDb.getInstance();
|
return PostgresEamDb.getInstance();
|
||||||
@ -86,7 +89,8 @@ public interface EamDb {
|
|||||||
* @return Is the database enabled
|
* @return Is the database enabled
|
||||||
*/
|
*/
|
||||||
static boolean isEnabled() {
|
static boolean isEnabled() {
|
||||||
return EamDbPlatformEnum.getSelectedPlatform() != EamDbPlatformEnum.DISABLED;
|
return EamDbUtil.useCentralRepo()
|
||||||
|
&& EamDbPlatformEnum.getSelectedPlatform() != EamDbPlatformEnum.DISABLED;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -3,7 +3,6 @@
|
|||||||
* To change this template file, choose Tools | Templates
|
* To change this template file, choose Tools | Templates
|
||||||
* and open the template in the editor.
|
* and open the template in the editor.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package org.sleuthkit.autopsy.centralrepository.datamodel;
|
package org.sleuthkit.autopsy.centralrepository.datamodel;
|
||||||
|
|
||||||
import java.sql.Connection;
|
import java.sql.Connection;
|
||||||
@ -15,12 +14,16 @@ import java.util.List;
|
|||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
import static org.sleuthkit.autopsy.centralrepository.datamodel.EamDb.SCHEMA_VERSION;
|
import static org.sleuthkit.autopsy.centralrepository.datamodel.EamDb.SCHEMA_VERSION;
|
||||||
import org.sleuthkit.autopsy.coreutils.Logger;
|
import org.sleuthkit.autopsy.coreutils.Logger;
|
||||||
|
import org.sleuthkit.autopsy.coreutils.ModuleSettings;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public class EamDbUtil {
|
public class EamDbUtil {
|
||||||
|
|
||||||
private final static Logger LOGGER = Logger.getLogger(EamDbUtil.class.getName());
|
private final static Logger LOGGER = Logger.getLogger(EamDbUtil.class.getName());
|
||||||
|
private static final String CENTRAL_REPO_NAME = "CentralRepository";
|
||||||
|
private static final String CENTRAL_REPO_USE_KEY = "db.useCentralRepo";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Close the prepared statement.
|
* Close the prepared statement.
|
||||||
@ -77,6 +80,7 @@ public class EamDbUtil {
|
|||||||
* Insert the default correlation types into the database.
|
* Insert the default correlation types into the database.
|
||||||
*
|
*
|
||||||
* @param conn Open connection to use.
|
* @param conn Open connection to use.
|
||||||
|
*
|
||||||
* @return true on success, else false
|
* @return true on success, else false
|
||||||
*/
|
*/
|
||||||
public static boolean insertDefaultCorrelationTypes(Connection conn) {
|
public static boolean insertDefaultCorrelationTypes(Connection conn) {
|
||||||
@ -112,6 +116,7 @@ public class EamDbUtil {
|
|||||||
* loaded.
|
* loaded.
|
||||||
*
|
*
|
||||||
* @param conn Open connection to use.
|
* @param conn Open connection to use.
|
||||||
|
*
|
||||||
* @return true on success, else false
|
* @return true on success, else false
|
||||||
*/
|
*/
|
||||||
public static boolean insertSchemaVersion(Connection conn) {
|
public static boolean insertSchemaVersion(Connection conn) {
|
||||||
@ -158,8 +163,29 @@ public class EamDbUtil {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use the current settings and the validation query
|
* If the Central Repos use has been enabled.
|
||||||
* to test the connection to the database.
|
*
|
||||||
|
* @return true if the Central Repo may be configured, false if it should
|
||||||
|
* not be able to be
|
||||||
|
*/
|
||||||
|
public static boolean useCentralRepo() {
|
||||||
|
return Boolean.parseBoolean(ModuleSettings.getConfigSetting(CENTRAL_REPO_NAME, CENTRAL_REPO_USE_KEY));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Saves the setting for whether the Central Repo should be able to be
|
||||||
|
* configured.
|
||||||
|
*
|
||||||
|
* @param centralRepoCheckBoxIsSelected - true if the central repo can be
|
||||||
|
* used
|
||||||
|
*/
|
||||||
|
public static void setUseCentralRepo(boolean centralRepoCheckBoxIsSelected) {
|
||||||
|
ModuleSettings.setConfigSetting(CENTRAL_REPO_NAME, CENTRAL_REPO_USE_KEY, Boolean.toString(centralRepoCheckBoxIsSelected));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Use the current settings and the validation query to test the connection
|
||||||
|
* to the database.
|
||||||
*
|
*
|
||||||
* @return true if successfull query execution, else false.
|
* @return true if successfull query execution, else false.
|
||||||
*/
|
*/
|
||||||
@ -184,11 +210,11 @@ public class EamDbUtil {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Conver thte Type's DbTableName string to the *_instances table name.
|
* Conver thte Type's DbTableName string to the *_instances table name.
|
||||||
*
|
*
|
||||||
* @param type Correlation Type
|
* @param type Correlation Type
|
||||||
|
*
|
||||||
* @return Instance table name for this Type.
|
* @return Instance table name for this Type.
|
||||||
*/
|
*/
|
||||||
public static String correlationTypeToInstanceTableName(EamArtifact.Type type) {
|
public static String correlationTypeToInstanceTableName(EamArtifact.Type type) {
|
||||||
@ -199,6 +225,7 @@ public class EamDbUtil {
|
|||||||
* Convert the Type's DbTableName string to the reference_* table name.
|
* Convert the Type's DbTableName string to the reference_* table name.
|
||||||
*
|
*
|
||||||
* @param type Correlation Type
|
* @param type Correlation Type
|
||||||
|
*
|
||||||
* @return Reference table name for this Type.
|
* @return Reference table name for this Type.
|
||||||
*/
|
*/
|
||||||
public static String correlationTypeToReferenceTableName(EamArtifact.Type type) {
|
public static String correlationTypeToReferenceTableName(EamArtifact.Type type) {
|
||||||
|
@ -21,6 +21,7 @@ package org.sleuthkit.autopsy.centralrepository.datamodel;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
|
import java.nio.file.InvalidPathException;
|
||||||
import java.sql.Connection;
|
import java.sql.Connection;
|
||||||
import java.sql.DriverManager;
|
import java.sql.DriverManager;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
@ -139,7 +140,7 @@ public final class SqliteEamDbSettings {
|
|||||||
File dbDir = new File(getDbDirectory());
|
File dbDir = new File(getDbDirectory());
|
||||||
Files.createDirectories(dbDir.toPath());
|
Files.createDirectories(dbDir.toPath());
|
||||||
LOGGER.log(Level.INFO, "sqlite directory did not exist, created it at {0}.", getDbDirectory()); // NON-NLS
|
LOGGER.log(Level.INFO, "sqlite directory did not exist, created it at {0}.", getDbDirectory()); // NON-NLS
|
||||||
} catch (IOException ex) {
|
} catch (IOException | InvalidPathException | SecurityException ex) {
|
||||||
LOGGER.log(Level.SEVERE, "Failed to create sqlite database directory.", ex); // NON-NLS
|
LOGGER.log(Level.SEVERE, "Failed to create sqlite database directory.", ex); // NON-NLS
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -162,7 +163,8 @@ public final class SqliteEamDbSettings {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use the current settings to get an ephemeral client connection for testing.
|
* Use the current settings to get an ephemeral client connection for
|
||||||
|
* testing.
|
||||||
*
|
*
|
||||||
* If the directory path does not exist, it will return null.
|
* If the directory path does not exist, it will return null.
|
||||||
*
|
*
|
||||||
@ -186,8 +188,8 @@ public final class SqliteEamDbSettings {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use the current settings and the validation query
|
* Use the current settings and the validation query to test the connection
|
||||||
* to test the connection to the database.
|
* to the database.
|
||||||
*
|
*
|
||||||
* @return true if successfull connection, else false.
|
* @return true if successfull connection, else false.
|
||||||
*/
|
*/
|
||||||
@ -203,8 +205,8 @@ public final class SqliteEamDbSettings {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Use the current settings and the schema version query
|
* Use the current settings and the schema version query to test the
|
||||||
* to test the database schema.
|
* database schema.
|
||||||
*
|
*
|
||||||
* @return true if successfull connection, else false.
|
* @return true if successfull connection, else false.
|
||||||
*/
|
*/
|
||||||
@ -247,7 +249,6 @@ public final class SqliteEamDbSettings {
|
|||||||
|
|
||||||
// NOTE: The organizations will only have a small number of rows, so
|
// NOTE: The organizations will only have a small number of rows, so
|
||||||
// an index is probably not worthwhile.
|
// an index is probably not worthwhile.
|
||||||
|
|
||||||
StringBuilder createCasesTable = new StringBuilder();
|
StringBuilder createCasesTable = new StringBuilder();
|
||||||
createCasesTable.append("CREATE TABLE IF NOT EXISTS cases (");
|
createCasesTable.append("CREATE TABLE IF NOT EXISTS cases (");
|
||||||
createCasesTable.append("id integer primary key autoincrement NOT NULL,");
|
createCasesTable.append("id integer primary key autoincrement NOT NULL,");
|
||||||
@ -346,7 +347,6 @@ public final class SqliteEamDbSettings {
|
|||||||
|
|
||||||
// NOTE: the db_info table currenly only has 1 row, so having an index
|
// NOTE: the db_info table currenly only has 1 row, so having an index
|
||||||
// provides no benefit.
|
// provides no benefit.
|
||||||
|
|
||||||
Connection conn = null;
|
Connection conn = null;
|
||||||
try {
|
try {
|
||||||
conn = getEphemeralConnection();
|
conn = getEphemeralConnection();
|
||||||
|
@ -13,7 +13,7 @@ EamSqliteSettingsDialog.bnCancel.text=Cancel
|
|||||||
EamSqliteSettingsDialog.lbTestDatabase.text=
|
EamSqliteSettingsDialog.lbTestDatabase.text=
|
||||||
EamSqliteSettingsDialog.bnTestDatabase.text=Test Connection
|
EamSqliteSettingsDialog.bnTestDatabase.text=Test Connection
|
||||||
EamSqliteSettingsDialog.lbTestDatabaseWarning.text=
|
EamSqliteSettingsDialog.lbTestDatabaseWarning.text=
|
||||||
EamSqliteSettingsDialog.bnDatabasePathFileOpen.text=Open...
|
EamSqliteSettingsDialog.bnDatabasePathFileOpen.text=Browse...
|
||||||
EamSqliteSettingsDialog.tfDatabasePath.toolTipText=Filename and path to store SQLite db file
|
EamSqliteSettingsDialog.tfDatabasePath.toolTipText=Filename and path to store SQLite db file
|
||||||
EamSqliteSettingsDialog.tfDatabasePath.text=
|
EamSqliteSettingsDialog.tfDatabasePath.text=
|
||||||
EamSqliteSettingsDialog.lbDatabasePath.text=Database Path :
|
EamSqliteSettingsDialog.lbDatabasePath.text=Database Path :
|
||||||
@ -52,24 +52,16 @@ ManageTagsDialog.cancelButton.text=Cancel
|
|||||||
ManageArtifactTypesDialog.taInstructionsMsg.text=Enable one or more correlation properties to use for correlation during ingest. Note, these properties are global and impact all users of the central repository.
|
ManageArtifactTypesDialog.taInstructionsMsg.text=Enable one or more correlation properties to use for correlation during ingest. Note, these properties are global and impact all users of the central repository.
|
||||||
EamSqliteSettingsDialog.bnOk.text=OK
|
EamSqliteSettingsDialog.bnOk.text=OK
|
||||||
EamPostgresSettingsDialog.bnSave.text=Save
|
EamPostgresSettingsDialog.bnSave.text=Save
|
||||||
EamDbSettingsDialog.pnDatabaseConnectionSettings.border.title=Database Settings
|
EamDbSettingsDialog.bnDatabasePathFileOpen.text=Browse...
|
||||||
EamDbSettingsDialog.rdioBnPostgreSQL.text=PostgreSQL
|
|
||||||
EamDbSettingsDialog.rdioBnSQLite.text=SQLite
|
|
||||||
EamDbSettingsDialog.bnDatabasePathFileOpen.text=Open...
|
|
||||||
EamDbSettingsDialog.tfDatabasePath.toolTipText=Filename and path to store SQLite db file
|
EamDbSettingsDialog.tfDatabasePath.toolTipText=Filename and path to store SQLite db file
|
||||||
EamDbSettingsDialog.tfDatabasePath.text=
|
EamDbSettingsDialog.tfDatabasePath.text=
|
||||||
EamDbSettingsDialog.lbDatabasePath.text=Database Path :
|
EamDbSettingsDialog.lbDatabasePath.text=Database Path :
|
||||||
EamDbSettingsDialog.rdioBnDisabled.text=Disabled
|
|
||||||
EamDbSettingsDialog.bnCancel.text=Cancel
|
EamDbSettingsDialog.bnCancel.text=Cancel
|
||||||
EamDbSettingsDialog.bnOk.text=OK
|
EamDbSettingsDialog.bnOk.text=OK
|
||||||
EamDbSettingsDialog.bnTest.text=Test
|
|
||||||
EamDbSettingsDialog.lbHostName.text=Host Name / IP :
|
EamDbSettingsDialog.lbHostName.text=Host Name / IP :
|
||||||
EamDbSettingsDialog.lbDatabaseName.text=Database name :
|
|
||||||
EamDbSettingsDialog.lbUserPassword.text=User Password :
|
EamDbSettingsDialog.lbUserPassword.text=User Password :
|
||||||
EamDbSettingsDialog.lbUserName.text=User Name :
|
EamDbSettingsDialog.lbUserName.text=User Name :
|
||||||
EamDbSettingsDialog.lbPort.text=Port :
|
EamDbSettingsDialog.lbPort.text=Port :
|
||||||
EamDbSettingsDialog.bnCreateDb.text=Create
|
|
||||||
EamDbSettingsDialog.pnSetupGuidance.border.title=Setup Guidance
|
|
||||||
GlobalSettingsPanel.pnDatabaseConfiguration.title=Database Configuration
|
GlobalSettingsPanel.pnDatabaseConfiguration.title=Database Configuration
|
||||||
GlobalSettingsPanel.lbDbPlatformTypeLabel.text=Type:
|
GlobalSettingsPanel.lbDbPlatformTypeLabel.text=Type:
|
||||||
GlobalSettingsPanel.lbDbNameLabel.text=Name:
|
GlobalSettingsPanel.lbDbNameLabel.text=Name:
|
||||||
|
@ -29,317 +29,35 @@
|
|||||||
<Layout>
|
<Layout>
|
||||||
<DimensionLayout dim="0">
|
<DimensionLayout dim="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="1" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="1" attributes="0">
|
|
||||||
<Component id="pnSetupGuidance" max="32767" attributes="0"/>
|
|
||||||
<Component id="pnDatabaseConnectionSettings" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="pnButtons" alignment="1" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
<DimensionLayout dim="1">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="pnSetupGuidance" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
|
||||||
<Component id="pnDatabaseConnectionSettings" min="-2" pref="348" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="pnButtons" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace min="0" pref="0" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
</Layout>
|
|
||||||
<SubComponents>
|
|
||||||
<Container class="javax.swing.JPanel" name="pnDatabaseConnectionSettings">
|
|
||||||
<Properties>
|
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
|
||||||
<Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
|
|
||||||
<TitledBorder title="Database Settings">
|
|
||||||
<ResourceString PropertyName="titleX" bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.pnDatabaseConnectionSettings.border.title" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
<Font PropertyName="font" name="Tahoma" size="12" style="0"/>
|
|
||||||
</TitledBorder>
|
|
||||||
</Border>
|
|
||||||
</Property>
|
|
||||||
<Property name="name" type="java.lang.String" value="" noResource="true"/>
|
|
||||||
</Properties>
|
|
||||||
|
|
||||||
<Layout>
|
|
||||||
<DimensionLayout dim="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<Component id="rdioBnPostgreSQL" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
|
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Component id="rdioBnSQLite" alignment="0" min="-2" max="-2" attributes="0"/>
|
<Component id="pnButtons" max="32767" attributes="0"/>
|
||||||
<Component id="rdioBnDisabled" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="pnSQLiteSettings" alignment="0" max="32767" attributes="0"/>
|
<Component id="pnSQLiteSettings" alignment="0" max="32767" attributes="0"/>
|
||||||
<Component id="pnPostgreSQLSettings" alignment="1" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
</Group>
|
||||||
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
<DimensionLayout dim="1">
|
<DimensionLayout dim="1">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="1" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<EmptySpace min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
<Component id="rdioBnDisabled" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace min="-2" pref="13" max="-2" attributes="0"/>
|
|
||||||
<Component id="rdioBnSQLite" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="pnSQLiteSettings" min="-2" max="-2" attributes="0"/>
|
<Component id="pnSQLiteSettings" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace min="-2" pref="12" max="-2" attributes="0"/>
|
<EmptySpace max="32767" attributes="0"/>
|
||||||
<Component id="rdioBnPostgreSQL" min="-2" max="-2" attributes="0"/>
|
<Component id="pnButtons" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
<Component id="pnPostgreSQLSettings" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace min="-2" pref="329" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
</Layout>
|
</Layout>
|
||||||
<SubComponents>
|
<SubComponents>
|
||||||
<Container class="javax.swing.JPanel" name="pnSQLiteSettings">
|
|
||||||
<Properties>
|
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
|
||||||
<Border info="org.netbeans.modules.form.compat2.border.EtchedBorderInfo">
|
|
||||||
<EtchetBorder/>
|
|
||||||
</Border>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
|
|
||||||
<Layout>
|
|
||||||
<DimensionLayout dim="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="lbDatabasePath" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
|
||||||
<Component id="tfDatabasePath" min="-2" pref="343" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
|
||||||
<Component id="bnDatabasePathFileOpen" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
<DimensionLayout dim="1">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
|
||||||
<Component id="lbDatabasePath" alignment="3" min="-2" pref="23" max="-2" attributes="0"/>
|
|
||||||
<Component id="tfDatabasePath" alignment="3" min="-2" pref="23" max="-2" attributes="0"/>
|
|
||||||
<Component id="bnDatabasePathFileOpen" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
</Layout>
|
|
||||||
<SubComponents>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbDatabasePath">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbDatabasePath.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JTextField" name="tfDatabasePath">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.tfDatabasePath.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
<Property name="toolTipText" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.tfDatabasePath.toolTipText" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="focusLost" listener="java.awt.event.FocusListener" parameters="java.awt.event.FocusEvent" handler="tfDatabasePathFocusLost"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JButton" name="bnDatabasePathFileOpen">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.bnDatabasePathFileOpen.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnDatabasePathFileOpenActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
</SubComponents>
|
|
||||||
</Container>
|
|
||||||
<Container class="javax.swing.JPanel" name="pnPostgreSQLSettings">
|
|
||||||
<Properties>
|
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
|
||||||
<Border info="org.netbeans.modules.form.compat2.border.EtchedBorderInfo">
|
|
||||||
<EtchetBorder/>
|
|
||||||
</Border>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
|
|
||||||
<Layout>
|
|
||||||
<DimensionLayout dim="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lbHostName" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lbPort" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lbDatabaseName" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lbUserName" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lbUserPassword" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Component id="tbDbUsername" alignment="0" pref="439" max="32767" attributes="0"/>
|
|
||||||
<Component id="tbDbName" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="tbDbPort" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="tbDbHostname" max="32767" attributes="0"/>
|
|
||||||
<Component id="jpDbPassword" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
<DimensionLayout dim="1">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="1" attributes="0">
|
|
||||||
<Component id="tbDbHostname" alignment="1" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lbHostName" alignment="1" min="-2" pref="22" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Component id="tbDbPort" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="lbPort" alignment="0" min="-2" pref="20" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Component id="tbDbName" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="lbDatabaseName" alignment="0" min="-2" pref="20" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Component id="tbDbUsername" alignment="0" max="32767" attributes="0"/>
|
|
||||||
<Component id="lbUserName" alignment="0" min="-2" pref="20" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
|
||||||
<Component id="lbUserPassword" alignment="3" min="-2" pref="20" max="-2" attributes="0"/>
|
|
||||||
<Component id="jpDbPassword" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace pref="19" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</DimensionLayout>
|
|
||||||
</Layout>
|
|
||||||
<SubComponents>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbHostName">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbHostName.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbPort">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbPort.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbUserName">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbUserName.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbUserPassword">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbUserPassword.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbDatabaseName">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbDatabaseName.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JTextField" name="tbDbHostname">
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JTextField" name="tbDbPort">
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JTextField" name="tbDbName">
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JTextField" name="tbDbUsername">
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JPasswordField" name="jpDbPassword">
|
|
||||||
</Component>
|
|
||||||
</SubComponents>
|
|
||||||
</Container>
|
|
||||||
<Component class="javax.swing.JRadioButton" name="rdioBnSQLite">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.rdioBnSQLite.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="rdioBnSQLiteActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JRadioButton" name="rdioBnPostgreSQL">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.rdioBnPostgreSQL.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="rdioBnPostgreSQLActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JRadioButton" name="rdioBnDisabled">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.rdioBnDisabled.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="rdioBnDisabledActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
</SubComponents>
|
|
||||||
</Container>
|
|
||||||
<Container class="javax.swing.JPanel" name="pnButtons">
|
<Container class="javax.swing.JPanel" name="pnButtons">
|
||||||
|
|
||||||
<Layout>
|
<Layout>
|
||||||
<DimensionLayout dim="0">
|
<DimensionLayout dim="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="bnTest" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="lbTestIcon" min="-2" pref="20" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
|
||||||
<Component id="bnCreateDb" min="-2" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
<Component id="lbCreateIcon" min="-2" pref="21" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<EmptySpace max="32767" attributes="0"/>
|
||||||
<Component id="bnOk" min="-2" max="-2" attributes="0"/>
|
<Component id="bnOk" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace min="-2" pref="11" max="-2" attributes="0"/>
|
<EmptySpace min="-2" pref="11" max="-2" attributes="0"/>
|
||||||
@ -352,20 +70,11 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace min="0" pref="0" max="-2" attributes="0"/>
|
<EmptySpace min="0" pref="0" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lbCreateIcon" max="32767" attributes="0"/>
|
|
||||||
<Component id="lbTestIcon" alignment="1" max="32767" attributes="0"/>
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="bnOk" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="bnOk" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="bnCancel" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="bnCancel" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="bnTest" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="bnCreateDb" alignment="3" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
|
<EmptySpace min="0" pref="0" max="-2" attributes="0"/>
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@ -391,40 +100,13 @@
|
|||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnOkActionPerformed"/>
|
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnOkActionPerformed"/>
|
||||||
</Events>
|
</Events>
|
||||||
</Component>
|
</Component>
|
||||||
<Component class="javax.swing.JButton" name="bnTest">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.bnTest.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnTestActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JButton" name="bnCreateDb">
|
|
||||||
<Properties>
|
|
||||||
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
|
||||||
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.bnCreateDb.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
</Property>
|
|
||||||
</Properties>
|
|
||||||
<Events>
|
|
||||||
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnCreateDbActionPerformed"/>
|
|
||||||
</Events>
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbTestIcon">
|
|
||||||
</Component>
|
|
||||||
<Component class="javax.swing.JLabel" name="lbCreateIcon">
|
|
||||||
</Component>
|
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Container>
|
</Container>
|
||||||
<Container class="javax.swing.JPanel" name="pnSetupGuidance">
|
<Container class="javax.swing.JPanel" name="pnSQLiteSettings">
|
||||||
<Properties>
|
<Properties>
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
||||||
<Border info="org.netbeans.modules.form.compat2.border.TitledBorderInfo">
|
<Border info="org.netbeans.modules.form.compat2.border.EtchedBorderInfo">
|
||||||
<TitledBorder title="Setup Guidance">
|
<EtchetBorder/>
|
||||||
<ResourceString PropertyName="titleX" bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.pnSetupGuidance.border.title" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
|
||||||
<Font PropertyName="font" name="Tahoma" size="12" style="0"/>
|
|
||||||
</TitledBorder>
|
|
||||||
</Border>
|
</Border>
|
||||||
</Property>
|
</Property>
|
||||||
</Properties>
|
</Properties>
|
||||||
@ -434,56 +116,177 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="jScrollPane1" max="32767" attributes="0"/>
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lbHostName" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbPort" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbUserName" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbDatabaseType" alignment="0" min="-2" pref="82" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lbDatabasePath" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbUserPassword" alignment="1" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="cbDatabaseType" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
|
<Component id="lbSingleUserSqLite" pref="467" max="32767" attributes="0"/>
|
||||||
|
<EmptySpace min="-2" pref="9" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" alignment="0" attributes="0">
|
||||||
|
<Component id="tfDatabasePath" max="32767" attributes="0"/>
|
||||||
|
<EmptySpace min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="bnDatabasePathFileOpen" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace min="-2" pref="11" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="tbDbHostname" max="32767" attributes="0"/>
|
||||||
|
<Component id="jpDbPassword" alignment="0" max="32767" attributes="0"/>
|
||||||
|
<Component id="tbDbUsername" alignment="1" max="32767" attributes="0"/>
|
||||||
|
<Component id="tbDbPort" alignment="0" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
<DimensionLayout dim="1">
|
<DimensionLayout dim="1">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
|
<EmptySpace min="-2" pref="6" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="cbDatabaseType" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbSingleUserSqLite" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<Component id="lbDatabaseType" alignment="1" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="jScrollPane1" min="-2" max="-2" attributes="0"/>
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<Component id="lbDatabasePath" alignment="3" min="-2" pref="23" max="-2" attributes="0"/>
|
||||||
|
<Component id="tfDatabasePath" alignment="3" min="-2" pref="23" max="-2" attributes="0"/>
|
||||||
|
<Component id="bnDatabasePathFileOpen" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="0" pref="0" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="tbDbHostname" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbHostName" alignment="3" min="-2" pref="22" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="tbDbPort" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbPort" alignment="3" min="-2" pref="20" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="tbDbUsername" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lbUserName" alignment="3" min="-2" pref="20" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
|
<Component id="lbUserPassword" alignment="3" min="-2" pref="20" max="-2" attributes="0"/>
|
||||||
|
<Component id="jpDbPassword" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="10" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
</Layout>
|
</Layout>
|
||||||
<SubComponents>
|
<SubComponents>
|
||||||
<Container class="javax.swing.JScrollPane" name="jScrollPane1">
|
<Component class="javax.swing.JLabel" name="lbDatabasePath">
|
||||||
<Properties>
|
<Properties>
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
<Border info="null"/>
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbDatabasePath.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
</Property>
|
</Property>
|
||||||
</Properties>
|
</Properties>
|
||||||
|
</Component>
|
||||||
<Layout class="org.netbeans.modules.form.compat2.layouts.support.JScrollPaneSupportLayout"/>
|
<Component class="javax.swing.JTextField" name="tfDatabasePath">
|
||||||
<SubComponents>
|
|
||||||
<Component class="javax.swing.JTextArea" name="taSetupGuidance">
|
|
||||||
<Properties>
|
<Properties>
|
||||||
<Property name="editable" type="boolean" value="false"/>
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
<Property name="background" type="java.awt.Color" editor="org.netbeans.beaninfo.editors.ColorEditor">
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.tfDatabasePath.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
<Color blue="f0" green="f0" red="f0" type="rgb"/>
|
|
||||||
</Property>
|
</Property>
|
||||||
<Property name="columns" type="int" value="20"/>
|
<Property name="toolTipText" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
<Property name="font" type="java.awt.Font" editor="org.netbeans.beaninfo.editors.FontEditor">
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.tfDatabasePath.toolTipText" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
<Font name="Monospaced" size="12" style="0"/>
|
|
||||||
</Property>
|
</Property>
|
||||||
<Property name="lineWrap" type="boolean" value="true"/>
|
</Properties>
|
||||||
<Property name="rows" type="int" value="3"/>
|
</Component>
|
||||||
<Property name="tabSize" type="int" value="4"/>
|
<Component class="javax.swing.JButton" name="bnDatabasePathFileOpen">
|
||||||
<Property name="wrapStyleWord" type="boolean" value="true"/>
|
<Properties>
|
||||||
<Property name="autoscrolls" type="boolean" value="false"/>
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
<Property name="border" type="javax.swing.border.Border" editor="org.netbeans.modules.form.editors2.BorderEditor">
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.bnDatabasePathFileOpen.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
<Border info="null"/>
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
<Events>
|
||||||
|
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="bnDatabasePathFileOpenActionPerformed"/>
|
||||||
|
</Events>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbHostName">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbHostName.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JTextField" name="tbDbHostname">
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbPort">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbPort.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JTextField" name="tbDbPort">
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbUserName">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbUserName.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JTextField" name="tbDbUsername">
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbUserPassword">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbUserPassword.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JPasswordField" name="jpDbPassword">
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JComboBox" name="cbDatabaseType">
|
||||||
|
<Properties>
|
||||||
|
<Property name="model" type="javax.swing.ComboBoxModel" editor="org.netbeans.modules.form.RADConnectionPropertyEditor">
|
||||||
|
<Connection code="new javax.swing.DefaultComboBoxModel<>(new EamDbPlatformEnum[]{EamDbPlatformEnum.POSTGRESQL, EamDbPlatformEnum.SQLITE})" type="code"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
<Events>
|
||||||
|
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="cbDatabaseTypeActionPerformed"/>
|
||||||
|
</Events>
|
||||||
|
<AuxValues>
|
||||||
|
<AuxValue name="JavaCodeGenerator_TypeParameters" type="java.lang.String" value="<EamDbPlatformEnum>"/>
|
||||||
|
</AuxValues>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbSingleUserSqLite">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbSingleUserSqLite.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JLabel" name="lbDatabaseType">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="EamDbSettingsDialog.lbDatabaseType.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
</Property>
|
</Property>
|
||||||
<Property name="requestFocusEnabled" type="boolean" value="false"/>
|
|
||||||
<Property name="verifyInputWhenFocusTarget" type="boolean" value="false"/>
|
|
||||||
</Properties>
|
</Properties>
|
||||||
</Component>
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Container>
|
</Container>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Container>
|
|
||||||
</SubComponents>
|
|
||||||
</Form>
|
</Form>
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -25,6 +25,10 @@
|
|||||||
<Component id="pnDatabaseContentButtons" max="32767" attributes="0"/>
|
<Component id="pnDatabaseContentButtons" max="32767" attributes="0"/>
|
||||||
<Component id="tbOops" alignment="1" max="32767" attributes="0"/>
|
<Component id="tbOops" alignment="1" max="32767" attributes="0"/>
|
||||||
<Component id="pnDatabaseConfiguration" max="32767" attributes="0"/>
|
<Component id="pnDatabaseConfiguration" max="32767" attributes="0"/>
|
||||||
|
<Group type="102" alignment="0" attributes="0">
|
||||||
|
<Component id="cbUseCentralRepo" min="-2" pref="186" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace min="0" pref="0" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
@ -33,13 +37,14 @@
|
|||||||
<DimensionLayout dim="1">
|
<DimensionLayout dim="1">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="1" attributes="0">
|
<Group type="102" alignment="1" attributes="0">
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<Component id="cbUseCentralRepo" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
<Component id="pnDatabaseConfiguration" min="-2" max="-2" attributes="0"/>
|
<Component id="pnDatabaseConfiguration" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="tbOops" min="-2" max="-2" attributes="0"/>
|
<Component id="tbOops" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="pnDatabaseContentButtons" min="-2" pref="50" max="-2" attributes="0"/>
|
<Component id="pnDatabaseContentButtons" min="-2" pref="50" max="-2" attributes="0"/>
|
||||||
<EmptySpace min="0" pref="18" max="32767" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@ -240,5 +245,15 @@
|
|||||||
</Property>
|
</Property>
|
||||||
</Properties>
|
</Properties>
|
||||||
</Component>
|
</Component>
|
||||||
|
<Component class="javax.swing.JCheckBox" name="cbUseCentralRepo">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" editor="org.netbeans.modules.i18n.form.FormI18nStringEditor">
|
||||||
|
<ResourceString bundle="org/sleuthkit/autopsy/centralrepository/optionspanel/Bundle.properties" key="GlobalSettingsPanel.cbUseCentralRepo.text" replaceFormat="org.openide.util.NbBundle.getMessage({sourceFileName}.class, "{key}")"/>
|
||||||
|
</Property>
|
||||||
|
</Properties>
|
||||||
|
<Events>
|
||||||
|
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="cbUseCentralRepoActionPerformed"/>
|
||||||
|
</Events>
|
||||||
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Form>
|
</Form>
|
||||||
|
@ -29,6 +29,8 @@ import org.sleuthkit.autopsy.events.AutopsyEvent;
|
|||||||
import org.sleuthkit.autopsy.ingest.IngestManager;
|
import org.sleuthkit.autopsy.ingest.IngestManager;
|
||||||
import org.sleuthkit.autopsy.ingest.IngestModuleGlobalSettingsPanel;
|
import org.sleuthkit.autopsy.ingest.IngestModuleGlobalSettingsPanel;
|
||||||
import org.sleuthkit.autopsy.centralrepository.datamodel.EamDbPlatformEnum;
|
import org.sleuthkit.autopsy.centralrepository.datamodel.EamDbPlatformEnum;
|
||||||
|
import static org.sleuthkit.autopsy.centralrepository.datamodel.EamDbPlatformEnum.DISABLED;
|
||||||
|
import org.sleuthkit.autopsy.centralrepository.datamodel.EamDbUtil;
|
||||||
import org.sleuthkit.autopsy.centralrepository.datamodel.PostgresEamDbSettings;
|
import org.sleuthkit.autopsy.centralrepository.datamodel.PostgresEamDbSettings;
|
||||||
import org.sleuthkit.autopsy.centralrepository.datamodel.SqliteEamDbSettings;
|
import org.sleuthkit.autopsy.centralrepository.datamodel.SqliteEamDbSettings;
|
||||||
|
|
||||||
@ -53,7 +55,8 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
addIngestJobEventsListener();
|
addIngestJobEventsListener();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Messages({"GlobalSettingsPanel.title=Central Repository Settings"})
|
@Messages({"GlobalSettingsPanel.title=Central Repository Settings",
|
||||||
|
"GlobalSettingsPanel.cbUseCentralRepo.text=Use a Central Repository"})
|
||||||
private void customizeComponents() {
|
private void customizeComponents() {
|
||||||
setName(Bundle.GlobalSettingsPanel_title());
|
setName(Bundle.GlobalSettingsPanel_title());
|
||||||
}
|
}
|
||||||
@ -85,6 +88,7 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
bnManageTags = new javax.swing.JButton();
|
bnManageTags = new javax.swing.JButton();
|
||||||
bnManageTypes = new javax.swing.JButton();
|
bnManageTypes = new javax.swing.JButton();
|
||||||
tbOops = new javax.swing.JTextField();
|
tbOops = new javax.swing.JTextField();
|
||||||
|
cbUseCentralRepo = new javax.swing.JCheckBox();
|
||||||
|
|
||||||
setName(""); // NOI18N
|
setName(""); // NOI18N
|
||||||
|
|
||||||
@ -198,6 +202,13 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
tbOops.setText(org.openide.util.NbBundle.getMessage(GlobalSettingsPanel.class, "GlobalSettingsPanel.tbOops.text")); // NOI18N
|
tbOops.setText(org.openide.util.NbBundle.getMessage(GlobalSettingsPanel.class, "GlobalSettingsPanel.tbOops.text")); // NOI18N
|
||||||
tbOops.setBorder(null);
|
tbOops.setBorder(null);
|
||||||
|
|
||||||
|
org.openide.awt.Mnemonics.setLocalizedText(cbUseCentralRepo, org.openide.util.NbBundle.getMessage(GlobalSettingsPanel.class, "GlobalSettingsPanel.cbUseCentralRepo.text")); // NOI18N
|
||||||
|
cbUseCentralRepo.addActionListener(new java.awt.event.ActionListener() {
|
||||||
|
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||||
|
cbUseCentralRepoActionPerformed(evt);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
|
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
|
||||||
this.setLayout(layout);
|
this.setLayout(layout);
|
||||||
layout.setHorizontalGroup(
|
layout.setHorizontalGroup(
|
||||||
@ -207,50 +218,65 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addComponent(pnDatabaseContentButtons, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
.addComponent(pnDatabaseContentButtons, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||||
.addComponent(tbOops, javax.swing.GroupLayout.Alignment.TRAILING)
|
.addComponent(tbOops, javax.swing.GroupLayout.Alignment.TRAILING)
|
||||||
.addComponent(pnDatabaseConfiguration, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
|
.addComponent(pnDatabaseConfiguration, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addComponent(cbUseCentralRepo, javax.swing.GroupLayout.PREFERRED_SIZE, 186, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addGap(0, 0, Short.MAX_VALUE)))
|
||||||
.addContainerGap())
|
.addContainerGap())
|
||||||
);
|
);
|
||||||
layout.setVerticalGroup(
|
layout.setVerticalGroup(
|
||||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
|
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
|
||||||
.addContainerGap()
|
.addComponent(cbUseCentralRepo)
|
||||||
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||||
.addComponent(pnDatabaseConfiguration, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(pnDatabaseConfiguration, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addComponent(tbOops, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(tbOops, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addComponent(pnDatabaseContentButtons, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(pnDatabaseContentButtons, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addGap(0, 18, Short.MAX_VALUE))
|
.addContainerGap())
|
||||||
);
|
);
|
||||||
}// </editor-fold>//GEN-END:initComponents
|
}// </editor-fold>//GEN-END:initComponents
|
||||||
|
|
||||||
private void bnImportDatabaseActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnImportDatabaseActionPerformed
|
private void bnImportDatabaseActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnImportDatabaseActionPerformed
|
||||||
|
store();
|
||||||
ImportHashDatabaseDialog dialog = new ImportHashDatabaseDialog();
|
ImportHashDatabaseDialog dialog = new ImportHashDatabaseDialog();
|
||||||
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
||||||
}//GEN-LAST:event_bnImportDatabaseActionPerformed
|
}//GEN-LAST:event_bnImportDatabaseActionPerformed
|
||||||
|
|
||||||
private void bnManageTagsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnManageTagsActionPerformed
|
private void bnManageTagsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnManageTagsActionPerformed
|
||||||
|
store();
|
||||||
ManageTagsDialog dialog = new ManageTagsDialog();
|
ManageTagsDialog dialog = new ManageTagsDialog();
|
||||||
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
||||||
}//GEN-LAST:event_bnManageTagsActionPerformed
|
}//GEN-LAST:event_bnManageTagsActionPerformed
|
||||||
|
|
||||||
private void bnManageTypesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnManageTypesActionPerformed
|
private void bnManageTypesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnManageTypesActionPerformed
|
||||||
|
store();
|
||||||
ManageCorrelationPropertiesDialog dialog = new ManageCorrelationPropertiesDialog();
|
ManageCorrelationPropertiesDialog dialog = new ManageCorrelationPropertiesDialog();
|
||||||
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
firePropertyChange(OptionsPanelController.PROP_VALID, null, null);
|
||||||
}//GEN-LAST:event_bnManageTypesActionPerformed
|
}//GEN-LAST:event_bnManageTypesActionPerformed
|
||||||
|
|
||||||
private void bnDbConfigureActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnDbConfigureActionPerformed
|
private void bnDbConfigureActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_bnDbConfigureActionPerformed
|
||||||
|
store();
|
||||||
EamDbSettingsDialog dialog = new EamDbSettingsDialog();
|
EamDbSettingsDialog dialog = new EamDbSettingsDialog();
|
||||||
load(); // reload db settings content and update buttons
|
load(); // reload db settings content and update buttons
|
||||||
}//GEN-LAST:event_bnDbConfigureActionPerformed
|
}//GEN-LAST:event_bnDbConfigureActionPerformed
|
||||||
|
|
||||||
|
private void cbUseCentralRepoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cbUseCentralRepoActionPerformed
|
||||||
|
//if saved setting is disabled checkbox should be disabled already
|
||||||
|
enableDatabaseConfigureButton(cbUseCentralRepo.isSelected());
|
||||||
|
enableButtonSubComponents(cbUseCentralRepo.isSelected() && !EamDbPlatformEnum.getSelectedPlatform().equals(DISABLED));
|
||||||
|
this.ingestStateUpdated();
|
||||||
|
firePropertyChange(OptionsPanelController.PROP_CHANGED, null, null);
|
||||||
|
}//GEN-LAST:event_cbUseCentralRepoActionPerformed
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@Messages({"GlobalSettingsPanel.validationerrMsg.mustConfigure=Configure the database to enable this module."})
|
@Messages({"GlobalSettingsPanel.validationerrMsg.mustConfigure=Configure the database to enable this module."})
|
||||||
public void load() {
|
public void load() {
|
||||||
tbOops.setText("");
|
tbOops.setText("");
|
||||||
|
|
||||||
enableAllSubComponents(false);
|
enableAllSubComponents(false);
|
||||||
EamDbPlatformEnum selectedPlatform = EamDbPlatformEnum.getSelectedPlatform();
|
EamDbPlatformEnum selectedPlatform = EamDbPlatformEnum.getSelectedPlatform();
|
||||||
|
cbUseCentralRepo.setSelected(EamDbUtil.useCentralRepo()); // NON-NLS
|
||||||
switch (selectedPlatform) {
|
switch (selectedPlatform) {
|
||||||
case POSTGRESQL:
|
case POSTGRESQL:
|
||||||
PostgresEamDbSettings dbSettingsPg = new PostgresEamDbSettings();
|
PostgresEamDbSettings dbSettingsPg = new PostgresEamDbSettings();
|
||||||
@ -270,16 +296,16 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
lbDbPlatformValue.setText(EamDbPlatformEnum.DISABLED.toString());
|
lbDbPlatformValue.setText(EamDbPlatformEnum.DISABLED.toString());
|
||||||
lbDbNameValue.setText("");
|
lbDbNameValue.setText("");
|
||||||
lbDbLocationValue.setText("");
|
lbDbLocationValue.setText("");
|
||||||
enableDatabaseConfigureButton(true);
|
enableDatabaseConfigureButton(cbUseCentralRepo.isSelected());
|
||||||
tbOops.setText(Bundle.GlobalSettingsPanel_validationerrMsg_mustConfigure());
|
tbOops.setText(Bundle.GlobalSettingsPanel_validationerrMsg_mustConfigure());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
this.ingestStateUpdated();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void store() { // Click OK or Apply on Options Panel
|
public void store() { // Click OK or Apply on Options Panel
|
||||||
|
EamDbUtil.setUseCentralRepo(cbUseCentralRepo.isSelected());
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -293,6 +319,7 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void saveSettings() { // Click OK on Global Settings Panel
|
public void saveSettings() { // Click OK on Global Settings Panel
|
||||||
|
store();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -334,7 +361,10 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
|
|
||||||
if (IngestManager.getInstance().isIngestRunning()) {
|
if (IngestManager.getInstance().isIngestRunning()) {
|
||||||
tbOops.setText(Bundle.GlobalSettingsPanel_validationErrMsg_ingestRunning());
|
tbOops.setText(Bundle.GlobalSettingsPanel_validationErrMsg_ingestRunning());
|
||||||
enableAllSubComponents(false);
|
cbUseCentralRepo.setEnabled(false);
|
||||||
|
} else if (!cbUseCentralRepo.isEnabled()) {
|
||||||
|
cbUseCentralRepo.setEnabled(true);
|
||||||
|
load();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -347,8 +377,8 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
* @return True
|
* @return True
|
||||||
*/
|
*/
|
||||||
private boolean enableAllSubComponents(Boolean enable) {
|
private boolean enableAllSubComponents(Boolean enable) {
|
||||||
enableDatabaseConfigureButton(enable);
|
enableDatabaseConfigureButton(cbUseCentralRepo.isSelected() && enable);
|
||||||
enableButtonSubComponents(enable);
|
enableButtonSubComponents(cbUseCentralRepo.isSelected() && enable);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -359,9 +389,18 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
*
|
*
|
||||||
* @return True
|
* @return True
|
||||||
*/
|
*/
|
||||||
private boolean enableDatabaseConfigureButton(Boolean enable) {
|
private void enableDatabaseConfigureButton(Boolean enable) {
|
||||||
bnDbConfigure.setEnabled(enable);
|
boolean ingestRunning = IngestManager.getInstance().isIngestRunning();
|
||||||
return true;
|
pnDatabaseConfiguration.setEnabled(enable && !ingestRunning);
|
||||||
|
pnDatabaseContentButtons.setEnabled(enable && !ingestRunning);
|
||||||
|
bnDbConfigure.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbLocationLabel.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbLocationValue.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbNameLabel.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbNameValue.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbPlatformTypeLabel.setEnabled(enable && !ingestRunning);
|
||||||
|
lbDbPlatformValue.setEnabled(enable && !ingestRunning);
|
||||||
|
tbOops.setEnabled(enable && !ingestRunning);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -373,9 +412,10 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
* @return True
|
* @return True
|
||||||
*/
|
*/
|
||||||
private boolean enableButtonSubComponents(Boolean enable) {
|
private boolean enableButtonSubComponents(Boolean enable) {
|
||||||
bnManageTypes.setEnabled(enable);
|
boolean ingestRunning = IngestManager.getInstance().isIngestRunning();
|
||||||
bnImportDatabase.setEnabled(enable);
|
bnManageTypes.setEnabled(enable && !ingestRunning);
|
||||||
bnManageTags.setEnabled(enable);
|
bnImportDatabase.setEnabled(enable && !ingestRunning);
|
||||||
|
bnManageTags.setEnabled(enable && !ingestRunning);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -384,6 +424,7 @@ public final class GlobalSettingsPanel extends IngestModuleGlobalSettingsPanel i
|
|||||||
private javax.swing.JButton bnImportDatabase;
|
private javax.swing.JButton bnImportDatabase;
|
||||||
private javax.swing.JButton bnManageTags;
|
private javax.swing.JButton bnManageTags;
|
||||||
private javax.swing.JButton bnManageTypes;
|
private javax.swing.JButton bnManageTypes;
|
||||||
|
private javax.swing.JCheckBox cbUseCentralRepo;
|
||||||
private javax.swing.JLabel lbDbLocationLabel;
|
private javax.swing.JLabel lbDbLocationLabel;
|
||||||
private javax.swing.JLabel lbDbLocationValue;
|
private javax.swing.JLabel lbDbLocationValue;
|
||||||
private javax.swing.JLabel lbDbNameLabel;
|
private javax.swing.JLabel lbDbNameLabel;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user