diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties-MERGED b/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties-MERGED index c6f78680ca..6a7e8b004f 100755 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties-MERGED +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/Bundle.properties-MERGED @@ -52,6 +52,7 @@ DataResultViewerThumbnail.sortLabel.textTemplate=Sorted by: {0} DataResultViewerThumbnail.thumbnailSizeComboBox.large=Large Thumbnails DataResultViewerThumbnail.thumbnailSizeComboBox.medium=Medium Thumbnails DataResultViewerThumbnail.thumbnailSizeComboBox.small=Small Thumbnails +MultiUserSettingsPanel_Close_Case_To_Modify=Close case to modfy settings OptionsCategory_Name_General=Application OptionsCategory_Keywords_General=Autopsy Options HINT_DataContentTopComponent=This is a DataContent window diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanel.java b/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanel.java index 65c447c7af..2556674e01 100644 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanel.java +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanel.java @@ -32,13 +32,17 @@ import org.sleuthkit.autopsy.core.UserPreferences; import org.sleuthkit.autopsy.events.MessageServiceConnectionInfo; import org.sleuthkit.autopsy.coreutils.Logger; import java.awt.Cursor; +import java.beans.PropertyChangeEvent; import java.io.IOException; +import java.util.EnumSet; import java.util.logging.Level; import javax.swing.ImageIcon; import javax.swing.JOptionPane; import javax.swing.SwingUtilities; import org.openide.util.ImageUtilities; import org.openide.util.Lookup; +import org.openide.util.NbBundle.Messages; +import org.sleuthkit.autopsy.casemodule.Case; import org.sleuthkit.autopsy.coordinationservice.utils.CoordinationServiceUtils; import org.sleuthkit.autopsy.core.UserPreferencesException; import org.sleuthkit.autopsy.coreutils.PlatformUtil; @@ -159,6 +163,11 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { goodIcon = new ImageIcon(ImageUtilities.loadImage("org/sleuthkit/autopsy/images/good.png", false)); badIcon = new ImageIcon(ImageUtilities.loadImage("org/sleuthkit/autopsy/images/bad.png", false)); enableMultiUserComponents(textBoxes, cbEnableMultiUser.isSelected()); + + Case.addEventTypeSubscriber(EnumSet.of(Case.Events.CURRENT_CASE), (PropertyChangeEvent evt) -> { + //disable when case is open, enable when case is closed + load(evt.getNewValue() != null); + }); } /** @@ -806,7 +815,11 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { } }//GEN-LAST:event_bnTestZKActionPerformed - void load() { + @Messages({ + "MultiUserSettingsPanel_Close_Case_To_Modify=Close case to modfy settings" + }) + + void load(boolean caseOpen) { lbTestDatabase.setIcon(null); lbTestSolr8.setIcon(null); lbTestSolr4.setIcon(null); @@ -845,7 +858,13 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { bnTestMessageService.setEnabled(false); cbEnableMultiUser.setSelected(UserPreferences.getIsMultiUserModeEnabled()); - this.valid(); // trigger validation to enable buttons based on current settings + + // When a case is open, prevent the user from changing + // multi-user settings. + cbEnableMultiUser.setEnabled(!caseOpen); + enableMultiUserComponents(textBoxes, cbEnableMultiUser.isSelected() && !caseOpen); + + this.valid(caseOpen); // trigger validation to enable buttons based on current settings } private void populateSolrAndZkSettings() { @@ -1096,11 +1115,15 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { * * @return true if it's okay, false otherwise. */ - boolean valid() { - tbOops.setText(""); - + boolean valid(boolean caseOpen) { + if(caseOpen) { + tbOops.setText(Bundle.MultiUserSettingsPanel_Close_Case_To_Modify()); + } else { + tbOops.setText(""); + } + if (cbEnableMultiUser.isSelected()) { - return checkFieldsAndEnableButtons() + return checkFieldsAndEnableButtons(caseOpen) && databaseSettingsAreValid() && indexingServerSettingsAreValid() && messageServiceSettingsAreValid(); @@ -1115,7 +1138,7 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { * * @return True or false. */ - boolean checkFieldsAndEnableButtons() { + boolean checkFieldsAndEnableButtons(boolean caseOpen) { boolean result = true; boolean dbPopulated = databaseFieldsArePopulated(); @@ -1125,15 +1148,15 @@ public final class MultiUserSettingsPanel extends javax.swing.JPanel { boolean messageServicePopulated = messageServiceFieldsArePopulated(); // PostgreSQL Database - bnTestDatabase.setEnabled(dbPopulated); + bnTestDatabase.setEnabled(dbPopulated && !caseOpen); // Solr Indexing - bnTestSolr8.setEnabled(solr8Populated); - bnTestSolr4.setEnabled(solr4Populated); - bnTestZK.setEnabled(zkPopulated); + bnTestSolr8.setEnabled(solr8Populated && !caseOpen); + bnTestSolr4.setEnabled(solr4Populated && !caseOpen); + bnTestZK.setEnabled(zkPopulated && !caseOpen); // ActiveMQ Messaging - bnTestMessageService.setEnabled(messageServicePopulated); + bnTestMessageService.setEnabled(messageServicePopulated && !caseOpen); if (dbPopulated && messageServicePopulated && zkPopulated && (solr8Populated || solr4Populated)) { result = true; diff --git a/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanelController.java b/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanelController.java index 212bfa7dcd..536018955e 100644 --- a/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanelController.java +++ b/Core/src/org/sleuthkit/autopsy/corecomponents/MultiUserSettingsPanelController.java @@ -27,6 +27,7 @@ import org.openide.util.Lookup; import org.openide.util.NbBundle; import org.sleuthkit.autopsy.coreutils.MessageNotifyUtil; import java.util.logging.Level; +import org.sleuthkit.autopsy.casemodule.Case; import org.sleuthkit.autopsy.coreutils.Logger; @OptionsPanelController.TopLevelRegistration(categoryName = "#OptionsCategory_Name_Multi_User_Settings", @@ -43,7 +44,7 @@ public final class MultiUserSettingsPanelController extends OptionsPanelControll @Override public void update() { - getPanel().load(); + getPanel().load(Case.isCaseOpen()); changed = false; } @@ -59,7 +60,7 @@ public final class MultiUserSettingsPanelController extends OptionsPanelControll @Override public boolean isValid() { - return getPanel().valid(); + return getPanel().valid(Case.isCaseOpen()); } @Override diff --git a/docs/doxygen-user/images/activeMQ_node_cleanup.png b/docs/doxygen-user/images/activeMQ_node_cleanup.png new file mode 100644 index 0000000000..739d6e6ad7 Binary files /dev/null and b/docs/doxygen-user/images/activeMQ_node_cleanup.png differ diff --git a/docs/doxygen-user/multi-user/installActiveMQ.dox b/docs/doxygen-user/multi-user/installActiveMQ.dox index 07a6f1dcfd..5cedc7b348 100644 --- a/docs/doxygen-user/multi-user/installActiveMQ.dox +++ b/docs/doxygen-user/multi-user/installActiveMQ.dox @@ -24,20 +24,27 @@ If you need the JRE, install it with the default settings. \subsection install_activemq_install_mq ActiveMQ Installation -1. Extract the contents of the ActiveMQ archive folder to a location of your choice, bearing in mind that the files should be in a location that the running process will have write permissions to the folder. A typical folder choice would be similar to C:\\Program Files\\apache-activemq-5.13.3. Typically, it will ask for administrator permission to move the folder. Allow it if required. +