Description: remove policy editor for Java 25 This patch removes policy editor panels when compiled with Java 25. Author: Vladimir Petko Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1108568 Forwarded: not-needed Last-Update: 2025-12-15 --- a/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java +++ b/netx/net/sourceforge/jnlp/controlpanel/ControlPanel.java @@ -253,8 +253,6 @@ // TODO: This is commented out since this is not implemented yet // new SettingsPanel(Translator.R("CPTabRuntimes"), createRuntimesSettingsPanel()), new SettingsPanel(Translator.R("CPTabSecurity"), createSecuritySettingsPanel()), - //todo refactor to work with tmp file and apply as asu designed it - new SettingsPanel(Translator.R("CPTabPolicy"), createPolicySettingsPanel()), new SettingsPanel(Translator.R("APPEXTSECControlPanelExtendedAppletSecurityTitle"), new UnsignedAppletsTrustingListPanel(PathsAndFiles.APPLET_TRUST_SETTINGS_SYS.getFile(), PathsAndFiles.APPLET_TRUST_SETTINGS_USER.getFile(), this.config)) }; @@ -349,10 +347,6 @@ return new SecuritySettingsPanel(this.config); } - private JPanel createPolicySettingsPanel() { - return new PolicyPanel(this, this.config); - } - private JPanel createJVMSettingsPanel() { return new JVMPanel(this.config); } --- a/netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java +++ b/netx/net/sourceforge/jnlp/security/dialogs/CertWarningPane.java @@ -238,7 +238,6 @@ run.setText(R("ButRun")); } sandbox = new JButton(R("ButSandbox")); - advancedOptions = new TemporaryPermissionsButton(file, securityDelegate, sandbox); cancel = new JButton(); if (isHttpsCertTrustDialog) { @@ -253,7 +252,6 @@ run.setToolTipText(R("CertWarnRunTip")); } sandbox.setToolTipText(R("CertWarnSandboxTip")); - advancedOptions.setToolTipText(R("CertWarnPolicyTip")); if (isHttpsCertTrustDialog) { cancel.setToolTipText(R("CertWarnHTTPSRejectTip")); } else { @@ -273,15 +271,7 @@ initialFocusComponent = cancel; buttonPanel.add(run); - // Only iff this dialog is being invoked by VariableX509TrustManager. - // In this case, the "sandbox" button and temporary permissions do not make any sense, - // as we are asking the user if they trust some certificate that is not being used to sign an app - // (eg "do you trust this certificate presented for the HTTPS connection to the applet's host site") - // Since this dialog isn't talking about an applet/application, there is nothing to run sandboxed. - if (!isHttpsCertTrustDialog) { - buttonPanel.add(sandbox); - buttonPanel.add(advancedOptions); - } + buttonPanel.add(cancel); buttonPanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); --- a/netx/net/sourceforge/jnlp/security/dialogs/apptrustwarningpanel/PartiallySignedAppTrustWarningPanel.java +++ b/netx/net/sourceforge/jnlp/security/dialogs/apptrustwarningpanel/PartiallySignedAppTrustWarningPanel.java @@ -55,7 +55,6 @@ import net.sourceforge.jnlp.security.dialogresults.DialogResult; import net.sourceforge.jnlp.security.dialogresults.SetValueHandler; import net.sourceforge.jnlp.security.dialogresults.YesNoSandbox; -import net.sourceforge.jnlp.security.dialogs.TemporaryPermissionsButton; import net.sourceforge.jnlp.security.dialogs.remember.ExecuteAppletAction; import net.sourceforge.jnlp.tools.CertInformation; import net.sourceforge.jnlp.tools.JarCertVerifier; @@ -64,7 +63,6 @@ private final JarCertVerifier jcv; private final JButton sandboxButton; - private final JButton advancedOptionsButton; public PartiallySignedAppTrustWarningPanel(JNLPFile file, SecurityDialog securityDialog, SecurityDelegate securityDelegate) { super(file, securityDialog); @@ -72,13 +70,11 @@ this.INFO_PANEL_HEIGHT = 250; sandboxButton = new JButton(); - sandboxButton.setText(R("ButSandbox")); + sandboxButton.setText(R("ButRun")); sandboxButton.addActionListener(SetValueHandler.createSetValueListener(parent, YesNoSandbox.sandbox())); - advancedOptionsButton = new TemporaryPermissionsButton(file, securityDelegate, sandboxButton); buttons.add(1, sandboxButton); - buttons.add(2, advancedOptionsButton); addComponents(); securityDialog.getViwableDialog().setMinimumSize(new Dimension(600, 400)); --- a/netx/net/sourceforge/jnlp/security/dialogs/AccessWarningPane.java +++ b/netx/net/sourceforge/jnlp/security/dialogs/AccessWarningPane.java @@ -303,7 +303,6 @@ initialFocusComponent = cancel; buttonPanel.add(run); buttonPanel.add(cancel); - buttonPanel.add(showAdvanced); buttonPanel.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); //all of the above