Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AUT-2480 UI ct license #7865

Open
wants to merge 8 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public class CTCloudException extends Exception{

public enum ErrorCode {
BAD_REQUEST("CT-400", "Unknown or Bad request. Please contact Basis support at " + Constants.SUPPORT_AT_CYBERTRIAGE_DOT_COM + " for help diagnosing the problem."),
INVALID_KEY("CT-401", "An invalid license ID was used to access CyberTriage Cloud Service. Please contact Basis support " + Constants.SUPPORT_AT_CYBERTRIAGE_DOT_COM + " for help diagnosing the problem."),
INVALID_KEY("CT-401", "An invalid license ID was used to access CyberTriage Cloud Service. Please remove the license from the Cyber Triage options panel."),
GATEWAY_TIMEOUT("CT-504", "Request to CyberTriage Cloud Service timed out. Please retry after some time. If issue persists, please contact Basis support at " + Constants.SUPPORT_AT_CYBERTRIAGE_DOT_COM + " for assistance."),
UN_AUTHORIZED("CT-403", "An authorization error occurred. Please contact Basis support " + Constants.SUPPORT_AT_CYBERTRIAGE_DOT_COM + " for help diagnosing the problem."),
PROXY_UNAUTHORIZED("CT-407", "Proxy authentication failed. Please validate the connection settings from the Options panel Proxy Settings."),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
*/
public class CTOptionsPanel extends IngestModuleGlobalSettingsPanel {

private static final int MAX_SUBPANEL_WIDTH = 650;
private static final int MAX_SUBPANEL_WIDTH = 700;

private static final Logger logger = Logger.getLogger(CTOptionsPanel.class.getName());

Expand Down Expand Up @@ -70,14 +70,14 @@ public CTOptionsPanel() {
}

private void addSubOptionsPanels(List<CTOptionsSubPanel> subPanels) {
GridBagConstraints disclaimerConstraints = new GridBagConstraints();
disclaimerConstraints.gridx = 0;
disclaimerConstraints.gridy = 0;
disclaimerConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
disclaimerConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
disclaimerConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
disclaimerConstraints.weighty = 0;
disclaimerConstraints.weightx = 0;
GridBagConstraints disclaimerConstraints = new GridBagConstraints();
disclaimerConstraints.gridx = 0;
disclaimerConstraints.gridy = 0;
disclaimerConstraints.fill = java.awt.GridBagConstraints.HORIZONTAL;
disclaimerConstraints.anchor = java.awt.GridBagConstraints.NORTHWEST;
disclaimerConstraints.insets = new java.awt.Insets(5, 5, 5, 5);
disclaimerConstraints.weighty = 0;
disclaimerConstraints.weightx = 0;

for (int i = 0; i < subPanels.size(); i++) {
CTOptionsSubPanel subPanel = subPanels.get(i);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ EULADialog.cancelButton.text=Cancel
EULADialog.acceptButton.text=Accept
EULADialog.title=Cyber Triage End User License Agreement
CTMalwareScannerOptionsPanel.licenseInfoMessageLabel.text=
CTMalwareScannerOptionsPanel.disclaimer.text=<html>The Cyber Triage Malware Scanner module uses 40+ malware scanning engines to identify if Windows executables are malicious. It requires a paid subscription to use.</html>
CTMalwareScannerOptionsPanel.purchaseFromLabel.text=For licensing information, visit
CTLicenseDialog.licenseNumberTextField.toolTipText=AUT-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
CTMalwareScannerOptionsPanel.licenseErrorLabel.text=
CTMalwareScannerOptionsPanel.licenseInfoRemoveButton.text=Remove License
CTMalwareScannerOptionsPanel.text=<html>The Cyber Triage Malware Scanner module uses 40+ malware scanning engines to identify if Windows executables are malicious. It requires a paid subscription to use.</html>
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ CTMalwareScannerOptionsPanel_licenseAddDialog_desc=License Number:
CTMalwareScannerOptionsPanel_licenseAddDialog_title=Add a License...
CTMalwareScannerOptionsPanel_licenseAddDialogEnteredErr_desc=The license number has already been entered
CTMalwareScannerOptionsPanel_licenseAddDialogEnteredErr_title=License Number Already Entered
CTMalwareScannerOptionsPanel_licenseAddDialogPatternErr_desc=Please verify that license number is of format 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX'
CTMalwareScannerOptionsPanel_licenseAddDialogPatternErr_desc=Please verify that license number is of format 'AUT-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX'
CTMalwareScannerOptionsPanel_licenseAddDialogPatternErr_title=Invalid License Number
CTMalwareScannerOptionsPanel_LicenseFetcher_apiErr_title=Server Error
# {0} - licenseCode
Expand Down Expand Up @@ -63,6 +63,9 @@ EULADialog.cancelButton.text=Cancel
EULADialog.acceptButton.text=Accept
EULADialog.title=Cyber Triage End User License Agreement
CTMalwareScannerOptionsPanel.licenseInfoMessageLabel.text=
CTMalwareScannerOptionsPanel.disclaimer.text=<html>The Cyber Triage Malware Scanner module uses 40+ malware scanning engines to identify if Windows executables are malicious. It requires a paid subscription to use.</html>
CTMalwareScannerOptionsPanel.purchaseFromLabel.text=For licensing information, visit
CTLicenseDialog.licenseNumberTextField.toolTipText=AUT-XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
CTMalwareScannerOptionsPanel.licenseErrorLabel.text=
CTMalwareScannerOptionsPanel.licenseInfoRemoveButton.text=Remove License
CTMalwareScannerOptionsPanel.text=<html>The Cyber Triage Malware Scanner module uses 40+ malware scanning engines to identify if Windows executables are malicious. It requires a paid subscription to use.</html>
Installer_LicenseCheck_cloudExceptionTitle=Cyber Triage Error
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ public class CTLicensePersistence {
public static CTLicensePersistence getInstance() {
return instance;
}

public synchronized boolean deleteLicenseResponse() {
File licenseFile = getCTLicenseFile();
if (licenseFile.exists()) {
return licenseFile.delete();
} else {
return false;
}
}

public synchronized boolean saveLicenseResponse(LicenseResponse licenseResponse) {
if (licenseResponse != null) {
Expand Down