/hg/icedtea-web: 2 new changesets

omajid at icedtea.classpath.org omajid at icedtea.classpath.org
Mon Feb 28 11:33:47 PST 2011


changeset ff13474daadb in /hg/icedtea-web
details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=ff13474daadb
author: Omair Majid <omajid at redhat.com>
date: Mon Feb 28 13:40:12 2011 -0500

	Rename security warning classes to security dialog classes.

	Some of the security dialogs that are shown are not warning dialogs.

	2011-02-28 Omair Majid <omajid at redhat.com>

	 Rename files
	    * netx/net/sourceforge/jnlp/security/PasswordAuthenticationDialog.java
	: Rename to ...
	    * netx/net/sourceforge/jnlp/security/PasswordAuthenticationPane.java:
	New file.
	    * netx/net/sourceforge/jnlp/security/SecurityWarningDialog.java:
	Rename to...
	    * netx/net/sourceforge/jnlp/security/SecurityDialog.java: New file.
	    * netx/net/sourceforge/jnlp/security/SecurityWarning.java: Rename
	to...
	    * netx/net/sourceforge/jnlp/security/SecurityDialogs.java: New file.
	    * netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java,
	    * netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java,
	    * netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java,
	    * netx/net/sourceforge/jnlp/security/AccessWarningPane.java,
	    * netx/net/sourceforge/jnlp/security/AppletWarningPane.java,
	    * netx/net/sourceforge/jnlp/security/CertWarningPane.java,
	    * netx/net/sourceforge/jnlp/security/CertsInfoPane.java,
	    * netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java,
	    * netx/net/sourceforge/jnlp/security/MoreInfoPane.java,
	    * netx/net/sourceforge/jnlp/security/NotAllSignedWarningPane.java,
	    * netx/net/sourceforge/jnlp/security/SecurityDialogMessage.java,
	    * netx/net/sourceforge/jnlp/security/SecurityDialogMessageHandler.java
	,
	    * netx/net/sourceforge/jnlp/security/SecurityDialogPanel.java,
	    * netx/net/sourceforge/jnlp/security/SingleCertInfoPane.java,
	    * netx/net/sourceforge/jnlp/security/VariableX509TrustManager.java,
	    * netx/net/sourceforge/jnlp/security/viewer/CertificatePane.java,
	    * netx/net/sourceforge/jnlp/services/ServiceUtil.java,
	    * netx/net/sourceforge/jnlp/services/XClipboardService.java,
	    * netx/net/sourceforge/jnlp/services/XExtendedService.java,
	    * netx/net/sourceforge/jnlp/services/XFileOpenService.java,
	    * netx/net/sourceforge/jnlp/services/XFileSaveService.java: Update
	class names to the new classes.


changeset 54077eaf4670 in /hg/icedtea-web
details: http://icedtea.classpath.org/hg/icedtea-web?cmd=changeset;node=54077eaf4670
author: Omair Majid <omajid at redhat.com>
date: Mon Feb 28 14:30:39 2011 -0500

	Integrate JNLPAuthenticator into the rest of the security subsystem

	This patch integrates the password authentication pane into the rest
	of the security dialog system. The password authentication dialog is
	now shown using the secure thread, rather than the thread of the
	JNLP application.

	2011-02-28 Omair Majid <omajid at redhat.com>

	 * netx/net/sourceforge/jnlp/resources/Messages.properties: Add
	Password, Username and SAuthenticationPrompt.
	    * netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java
	(getPasswordAuthentication): Show password prompt using the secure
	thread.
	    * netx/net/sourceforge/jnlp/security/PasswordAuthenticationPane.java
	(PasswordAuthenticationPane): Initialize variables.
	(initialize): For consistency, rename to.. (addComponents): New
	method. Set the appropriate return value when user takes an
	action. (askUser): Remove. (main): Remove.
	    * netx/net/sourceforge/jnlp/security/SecurityDialog.java
	(initDialog): Add extra case for AUTHENTICATION dialog type.
	(installPanel): Likewise.
	    * netx/net/sourceforge/jnlp/security/SecurityDialogs.java
	(DialogType): Add AUTHENTICATION. (showAuthenicationPrompt): New
	method. Shows a password authentication prompt.


diffstat:

15 files changed, 493 insertions(+), 479 deletions(-)
ChangeLog                                                            |   29 +
netx/net/sourceforge/jnlp/resources/Messages.properties              |    1 
netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java           |    1 
netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java               |    1 
netx/net/sourceforge/jnlp/security/AccessWarningPane.java            |    2 
netx/net/sourceforge/jnlp/security/CertWarningPane.java              |    2 
netx/net/sourceforge/jnlp/security/PasswordAuthenticationDialog.java |  123 ------
netx/net/sourceforge/jnlp/security/PasswordAuthenticationPane.java   |   91 ++++
netx/net/sourceforge/jnlp/security/SecurityDialog.java               |  186 ++++++++++
netx/net/sourceforge/jnlp/security/SecurityDialogMessage.java        |    1 
netx/net/sourceforge/jnlp/security/SecurityDialogPanel.java          |    2 
netx/net/sourceforge/jnlp/security/SecurityDialogs.java              |  183 +++++++++
netx/net/sourceforge/jnlp/security/SecurityWarning.java              |  165 --------
netx/net/sourceforge/jnlp/security/SecurityWarningDialog.java        |  184 ---------
netx/net/sourceforge/jnlp/services/ServiceUtil.java                  |    1 

diffs (truncated from 2452 to 500 lines):

diff -r 02ef9ba4d8a2 -r 54077eaf4670 ChangeLog
--- a/ChangeLog	Fri Feb 25 18:16:48 2011 -0500
+++ b/ChangeLog	Mon Feb 28 14:30:39 2011 -0500
@@ -1,3 +1,59 @@ 2011-02-25  Omair Majid  <omajid at redhat.
+2011-02-28  Omair Majid  <omajid at redhat.com>
+
+	* netx/net/sourceforge/jnlp/resources/Messages.properties: Add Password,
+	Username and SAuthenticationPrompt.
+	* netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java
+	(getPasswordAuthentication): Show password prompt using the secure thread.
+	* netx/net/sourceforge/jnlp/security/PasswordAuthenticationPane.java
+	(PasswordAuthenticationPane): Initialize variables.
+	(initialize): For consistency, rename to..
+	(addComponents): New method. Set the appropriate return value when user
+	takes an action.
+	(askUser): Remove.
+	(main): Remove.
+	* netx/net/sourceforge/jnlp/security/SecurityDialog.java
+	(initDialog): Add extra case for AUTHENTICATION dialog type.
+	(installPanel): Likewise.
+	* netx/net/sourceforge/jnlp/security/SecurityDialogs.java
+	(DialogType): Add AUTHENTICATION.
+	(showAuthenicationPrompt): New method. Shows a password authentication
+	prompt.
+
+2011-02-28  Omair Majid  <omajid at redhat.com>
+
+	Rename files
+	* netx/net/sourceforge/jnlp/security/PasswordAuthenticationDialog.java:
+	Rename to ...
+	* netx/net/sourceforge/jnlp/security/PasswordAuthenticationPane.java: New
+	file.
+	* netx/net/sourceforge/jnlp/security/SecurityWarningDialog.java: Rename
+	to...
+	* netx/net/sourceforge/jnlp/security/SecurityDialog.java: New file.
+	* netx/net/sourceforge/jnlp/security/SecurityWarning.java: Rename to...
+	* netx/net/sourceforge/jnlp/security/SecurityDialogs.java: New file.
+	* netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java,
+	* netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java,
+	* netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java,
+	* netx/net/sourceforge/jnlp/security/AccessWarningPane.java,
+	* netx/net/sourceforge/jnlp/security/AppletWarningPane.java,
+	* netx/net/sourceforge/jnlp/security/CertWarningPane.java,
+	* netx/net/sourceforge/jnlp/security/CertsInfoPane.java,
+	* netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java,
+	* netx/net/sourceforge/jnlp/security/MoreInfoPane.java,
+	* netx/net/sourceforge/jnlp/security/NotAllSignedWarningPane.java,
+	* netx/net/sourceforge/jnlp/security/SecurityDialogMessage.java,
+	* netx/net/sourceforge/jnlp/security/SecurityDialogMessageHandler.java,
+	* netx/net/sourceforge/jnlp/security/SecurityDialogPanel.java,
+	* netx/net/sourceforge/jnlp/security/SingleCertInfoPane.java,
+	* netx/net/sourceforge/jnlp/security/VariableX509TrustManager.java,
+	* netx/net/sourceforge/jnlp/security/viewer/CertificatePane.java,
+	* netx/net/sourceforge/jnlp/services/ServiceUtil.java,
+	* netx/net/sourceforge/jnlp/services/XClipboardService.java,
+	* netx/net/sourceforge/jnlp/services/XExtendedService.java,
+	* netx/net/sourceforge/jnlp/services/XFileOpenService.java,
+	* netx/net/sourceforge/jnlp/services/XFileSaveService.java: Update class
+	names to the new classes.
+
 2011-02-25  Omair Majid  <omajid at redhat.com>
 
 	* Makefile.am (stamps/netx-dist.stamp): Do not add extra files to
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/resources/Messages.properties
--- a/netx/net/sourceforge/jnlp/resources/Messages.properties	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/resources/Messages.properties	Mon Feb 28 14:30:39 2011 -0500
@@ -22,8 +22,10 @@ Field=Field
 Field=Field
 From=From
 Name=Name
+Password=Password:
 Publisher=Publisher
 Unknown=<Unknown>
+Username=Username:
 Value=Value
 Version=Version
 
@@ -195,6 +197,7 @@ SNotAllSignedSummary=Only parts of this 
 SNotAllSignedSummary=Only parts of this application code are signed.
 SNotAllSignedDetail=This application contains both signed and unsigned code. While signed code is safe if you trust the provider, unsigned code may imply code outside of the trusted provider's control.
 SNotAllSignedQuestion=Do you wish to proceed and run this application anyway?
+SAuthenticationPrompt=The {0} server at {1} is requesting authentication. It says "{2}"
 
 # Security - used for the More Information dialog
 SBadKeyUsage=Resources contain entries whose signer certificate's KeyUsage extension doesn't allow code signing.
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java
--- a/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/runtime/ApplicationInstance.java	Mon Feb 28 14:30:39 2011 -0500
@@ -35,8 +35,8 @@ import net.sourceforge.jnlp.config.Deplo
 import net.sourceforge.jnlp.config.DeploymentConfiguration;
 import net.sourceforge.jnlp.event.ApplicationEvent;
 import net.sourceforge.jnlp.event.ApplicationListener;
-import net.sourceforge.jnlp.security.SecurityWarning;
-import net.sourceforge.jnlp.security.SecurityWarning.AccessType;
+import net.sourceforge.jnlp.security.SecurityDialogs;
+import net.sourceforge.jnlp.security.SecurityDialogs.AccessType;
 import net.sourceforge.jnlp.util.WeakList;
 import net.sourceforge.jnlp.util.XDesktopEntry;
 
@@ -184,12 +184,12 @@ public class ApplicationInstance {
         } else if (currentSetting.equals(ShortcutDesc.CREATE_ALWAYS)) {
             createShortcut = true;
         } else if (currentSetting.equals(ShortcutDesc.CREATE_ASK_USER)) {
-            if (SecurityWarning.showAccessWarningDialog(AccessType.CREATE_DESTKOP_SHORTCUT, file)) {
+            if (SecurityDialogs.showAccessWarningDialog(AccessType.CREATE_DESTKOP_SHORTCUT, file)) {
                 createShortcut = true;
             }
         } else if (currentSetting.equals(ShortcutDesc.CREATE_ASK_USER_IF_HINTED)) {
             if (sd != null && sd.onDesktop()) {
-                if (SecurityWarning.showAccessWarningDialog(AccessType.CREATE_DESTKOP_SHORTCUT, file)) {
+                if (SecurityDialogs.showAccessWarningDialog(AccessType.CREATE_DESTKOP_SHORTCUT, file)) {
                     createShortcut = true;
                 }
             }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java
--- a/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/runtime/JNLPClassLoader.java	Mon Feb 28 14:30:39 2011 -0500
@@ -58,8 +58,8 @@ import net.sourceforge.jnlp.cache.CacheU
 import net.sourceforge.jnlp.cache.CacheUtil;
 import net.sourceforge.jnlp.cache.ResourceTracker;
 import net.sourceforge.jnlp.cache.UpdatePolicy;
-import net.sourceforge.jnlp.security.SecurityWarning;
-import net.sourceforge.jnlp.security.SecurityWarning.AccessType;
+import net.sourceforge.jnlp.security.SecurityDialogs;
+import net.sourceforge.jnlp.security.SecurityDialogs.AccessType;
 import net.sourceforge.jnlp.tools.JarSigner;
 import net.sourceforge.jnlp.util.FileUtils;
 import sun.misc.JarIndex;
@@ -289,7 +289,7 @@ public class JNLPClassLoader extends URL
 
                 if (extLoader != null && extLoader != loader) {
                     if (loader.signing && !extLoader.signing)
-                        if (!SecurityWarning.showNotAllSignedWarningDialog(file))
+                        if (!SecurityDialogs.showNotAllSignedWarningDialog(file))
                             throw new LaunchException(file, null, R("LSFatal"), R("LCClient"), R("LSignedAppJarUsingUnsignedJar"), R("LSignedAppJarUsingUnsignedJarInfo"));
 
                     loader.merge(extLoader);
@@ -436,7 +436,7 @@ public class JNLPClassLoader extends URL
                 signing = true;
 
                 if (!js.allJarsSigned() &&
-                                    !SecurityWarning.showNotAllSignedWarningDialog(file))
+                                    !SecurityDialogs.showNotAllSignedWarningDialog(file))
                     throw new LaunchException(file, null, R("LSFatal"), R("LCClient"), R("LSignedAppJarUsingUnsignedJar"), R("LSignedAppJarUsingUnsignedJarInfo"));
 
                 //user does not trust this publisher
@@ -503,7 +503,7 @@ public class JNLPClassLoader extends URL
 
     private void checkTrustWithUser(JarSigner js) throws LaunchException {
         if (!js.getRootInCacerts()) { //root cert is not in cacerts
-            boolean b = SecurityWarning.showCertWarningDialog(
+            boolean b = SecurityDialogs.showCertWarningDialog(
                     AccessType.UNVERIFIED, file, js);
             if (!b)
                 throw new LaunchException(null, null, R("LSFatal"),
@@ -511,10 +511,10 @@ public class JNLPClassLoader extends URL
         } else if (js.getRootInCacerts()) { //root cert is in cacerts
             boolean b = false;
             if (js.noSigningIssues())
-                b = SecurityWarning.showCertWarningDialog(
+                b = SecurityDialogs.showCertWarningDialog(
                         AccessType.VERIFIED, file, js);
             else if (!js.noSigningIssues())
-                b = SecurityWarning.showCertWarningDialog(
+                b = SecurityDialogs.showCertWarningDialog(
                         AccessType.SIGNING_ERROR, file, js);
             if (!b)
                 throw new LaunchException(null, null, R("LSFatal"),
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java
--- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java	Mon Feb 28 14:30:39 2011 -0500
@@ -30,7 +30,7 @@ import javax.swing.JWindow;
 import javax.swing.JWindow;
 
 import net.sourceforge.jnlp.JNLPFile;
-import net.sourceforge.jnlp.security.SecurityWarning.AccessType;
+import net.sourceforge.jnlp.security.SecurityDialogs.AccessType;
 import net.sourceforge.jnlp.services.ServiceUtil;
 import net.sourceforge.jnlp.util.WeakList;
 import sun.awt.AWTSecurityManager;
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/AccessWarningPane.java
--- a/netx/net/sourceforge/jnlp/security/AccessWarningPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/AccessWarningPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -58,11 +58,11 @@ import javax.swing.SwingConstants;
 import javax.swing.SwingConstants;
 
 import net.sourceforge.jnlp.JNLPFile;
-import net.sourceforge.jnlp.security.SecurityWarning.AccessType;
+import net.sourceforge.jnlp.security.SecurityDialogs.AccessType;
 import net.sourceforge.jnlp.util.FileUtils;
 
 /**
- * Provides a panel to show inside a SecurityWarningDialog. These dialogs are
+ * Provides a panel to show inside a SecurityDialog. These dialogs are
  * used to warn the user when either signed code (with or without signing
  * issues) is going to be run, or when service permission (file, clipboard,
  * printer, etc) is needed with unsigned code.
@@ -74,12 +74,12 @@ public class AccessWarningPane extends S
     JCheckBox alwaysAllow;
     Object[] extras;
 
-    public AccessWarningPane(SecurityWarningDialog x, CertVerifier certVerifier) {
+    public AccessWarningPane(SecurityDialog x, CertVerifier certVerifier) {
         super(x, certVerifier);
         addComponents();
     }
 
-    public AccessWarningPane(SecurityWarningDialog x, Object[] extras, CertVerifier certVerifier) {
+    public AccessWarningPane(SecurityDialog x, Object[] extras, CertVerifier certVerifier) {
         super(x, certVerifier);
         this.extras = extras;
         addComponents();
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/AppletWarningPane.java
--- a/netx/net/sourceforge/jnlp/security/AppletWarningPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/AppletWarningPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -51,7 +51,7 @@ import javax.swing.JPanel;
 
 public class AppletWarningPane extends SecurityDialogPanel {
 
-    public AppletWarningPane(SecurityWarningDialog x, CertVerifier certVerifier) {
+    public AppletWarningPane(SecurityDialog x, CertVerifier certVerifier) {
         super(x, certVerifier);
         addComponents();
     }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/CertWarningPane.java
--- a/netx/net/sourceforge/jnlp/security/CertWarningPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/CertWarningPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -68,11 +68,11 @@ import net.sourceforge.jnlp.runtime.JNLP
 import net.sourceforge.jnlp.runtime.JNLPRuntime;
 import net.sourceforge.jnlp.security.KeyStores.Level;
 import net.sourceforge.jnlp.security.KeyStores.Type;
-import net.sourceforge.jnlp.security.SecurityWarning.AccessType;
+import net.sourceforge.jnlp.security.SecurityDialogs.AccessType;
 import net.sourceforge.jnlp.util.FileUtils;
 
 /**
- * Provides the panel for using inside a SecurityWarningDialog. These dialogs are
+ * Provides the panel for using inside a SecurityDialog. These dialogs are
  * used to warn the user when either signed code (with or without signing
  * issues) is going to be run, or when service permission (file, clipboard,
  * printer, etc) is needed with unsigned code.
@@ -84,7 +84,7 @@ public class CertWarningPane extends Sec
     JCheckBox alwaysTrust;
     CertVerifier certVerifier;
 
-    public CertWarningPane(SecurityWarningDialog x, CertVerifier certVerifier) {
+    public CertWarningPane(SecurityDialog x, CertVerifier certVerifier) {
         super(x, certVerifier);
         this.certVerifier = certVerifier;
         addComponents();
@@ -231,7 +231,7 @@ public class CertWarningPane extends Sec
 
     private class MoreInfoButtonListener implements ActionListener {
         public void actionPerformed(ActionEvent e) {
-            SecurityWarningDialog.showMoreInfoDialog(parent.getJarSigner(),
+            SecurityDialog.showMoreInfoDialog(parent.getJarSigner(),
                                 parent);
         }
     }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/CertsInfoPane.java
--- a/netx/net/sourceforge/jnlp/security/CertsInfoPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/CertsInfoPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -75,7 +75,7 @@ public class CertsInfoPane extends Secur
     private String[] columnNames = { R("Field"), R("Value") };
     protected ArrayList<String[][]> certsData;
 
-    public CertsInfoPane(SecurityWarningDialog x, CertVerifier certVerifier) {
+    public CertsInfoPane(SecurityDialog x, CertVerifier certVerifier) {
         super(x, certVerifier);
         addComponents();
     }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java
--- a/netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/JNLPAuthenticator.java	Mon Feb 28 14:30:39 2011 -0500
@@ -42,6 +42,7 @@ import java.net.PasswordAuthentication;
 
 public class JNLPAuthenticator extends Authenticator {
 
+    @Override
     public PasswordAuthentication getPasswordAuthentication() {
 
         // No security check is required here, because the only way to set
@@ -50,12 +51,16 @@ public class JNLPAuthenticator extends A
 
         String type = this.getRequestorType() == RequestorType.PROXY ? "proxy" : "web";
 
-        // request auth info from user
-        PasswordAuthenticationDialog pwDialog = new PasswordAuthenticationDialog();
-        PasswordAuthentication auth = pwDialog.askUser(this.getRequestingHost(), this.getRequestingPort(), this.getRequestingPrompt(), type);
+        String host = getRequestingHost();
+        int port = getRequestingPort();
+        String prompt = getRequestingPrompt();
 
-        // send it along
-        return auth;
+        Object[] response = SecurityDialogs.showAuthenicationPrompt(host, port, prompt, type);
+        if (response == null) {
+            return null;
+        } else {
+            return new PasswordAuthentication((String) response[0], (char[]) response[1]);
+        }
     }
 
 }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/MoreInfoPane.java
--- a/netx/net/sourceforge/jnlp/security/MoreInfoPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/MoreInfoPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -61,7 +61,7 @@ import javax.swing.SwingConstants;
  */
 public class MoreInfoPane extends SecurityDialogPanel {
 
-    public MoreInfoPane(SecurityWarningDialog x, CertVerifier certVerifier) {
+    public MoreInfoPane(SecurityDialog x, CertVerifier certVerifier) {
         super(x, certVerifier);
         addComponents();
     }
@@ -105,7 +105,7 @@ public class MoreInfoPane extends Securi
 
     private class CertInfoButtonListener implements ActionListener {
         public void actionPerformed(ActionEvent e) {
-            SecurityWarningDialog.showCertInfoDialog(parent.getJarSigner(),
+            SecurityDialog.showCertInfoDialog(parent.getJarSigner(),
                                 parent);
         }
     }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/NotAllSignedWarningPane.java
--- a/netx/net/sourceforge/jnlp/security/NotAllSignedWarningPane.java	Fri Feb 25 18:16:48 2011 -0500
+++ b/netx/net/sourceforge/jnlp/security/NotAllSignedWarningPane.java	Mon Feb 28 14:30:39 2011 -0500
@@ -57,7 +57,7 @@ import net.sourceforge.jnlp.JNLPFile;
 
 public class NotAllSignedWarningPane extends SecurityDialogPanel {
 
-    public NotAllSignedWarningPane(SecurityWarningDialog x) {
+    public NotAllSignedWarningPane(SecurityDialog x) {
         super(x);
         addComponents();
     }
diff -r 02ef9ba4d8a2 -r 54077eaf4670 netx/net/sourceforge/jnlp/security/PasswordAuthenticationDialog.java
--- a/netx/net/sourceforge/jnlp/security/PasswordAuthenticationDialog.java	Fri Feb 25 18:16:48 2011 -0500
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,247 +0,0 @@
-/* PasswordAuthenticationDialog -- requests authentication information from users
-   Copyright (C) 2009  Red Hat
-
-This file is part of IcedTea.
-
-IcedTea is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-IcedTea is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with IcedTea; see the file COPYING.  If not, write to the
-Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-02110-1301 USA.
-
-Linking this library statically or dynamically with other modules is
-making a combined work based on this library.  Thus, the terms and
-conditions of the GNU General Public License cover the whole
-combination.
-
-As a special exception, the copyright holders of this library give you
-permission to link this library with independent modules to produce an
-executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under
-terms of your choice, provided that you also meet, for each linked
-independent module, the terms and conditions of the license of that
-module.  An independent module is a module which is not derived from
-or based on this library.  If you modify this library, you may extend
-this exception to your version of the library, but you are not
-obligated to do so.  If you do not wish to do so, delete this
-exception statement from your version. */
-
-package net.sourceforge.jnlp.security;
-
-import java.awt.Dimension;
-import java.awt.GridBagConstraints;
-import java.awt.GridBagLayout;
-import java.awt.Insets;
-import java.awt.event.ActionEvent;
-import java.awt.event.ActionListener;
-import java.net.PasswordAuthentication;
-
-import javax.swing.JButton;
-import javax.swing.JDialog;
-import javax.swing.JLabel;
-import javax.swing.JPasswordField;
-import javax.swing.JTextField;
-import javax.swing.SwingUtilities;
-
-import net.sourceforge.jnlp.runtime.JNLPRuntime;
-
-/**
- * Modal non-minimizable dialog to request http authentication credentials
- */
-
-public class PasswordAuthenticationDialog extends JDialog {
-
-    private JLabel jlInfo = new JLabel("");
-    private JTextField jtfUserName = new JTextField();
-    private JPasswordField jpfPassword = new JPasswordField();
-    private boolean userCancelled;
-
-    public PasswordAuthenticationDialog() {
-        initialize();
-    }
-
-    /**
-     * Initialized the dialog components
-     */
-
-    public void initialize() {
-
-        setTitle("IcedTea Java Plugin - Authorization needed to proceed");
-
-        setLayout(new GridBagLayout());
-
-        JLabel jlUserName = new JLabel("Username: ");
-        JLabel jlPassword = new JLabel("Password: ");
-        JButton jbOK = new JButton("OK");
-        JButton jbCancel = new JButton("Cancel");
-
-        jtfUserName.setSize(20, 10);
-        jpfPassword.setSize(20, 10);
-
-        GridBagConstraints c;
-
-        c = new GridBagConstraints();
-        c.fill = c.HORIZONTAL;
-        c.gridx = 0;
-        c.gridy = 0;
-        c.gridwidth = 2;
-        c.insets = new Insets(10, 5, 3, 3);
-        add(jlInfo, c);
-
-        c = new GridBagConstraints();
-        c.gridx = 0;
-        c.gridy = 1;
-        c.insets = new Insets(10, 5, 3, 3);
-        add(jlUserName, c);
-
-        c = new GridBagConstraints();
-        c.fill = c.HORIZONTAL;
-        c.gridx = 1;
-        c.gridy = 1;
-        c.insets = new Insets(10, 5, 3, 3);
-        c.weightx = 1.0;
-        add(jtfUserName, c);
-
-        c = new GridBagConstraints();
-        c.gridx = 0;
-        c.gridy = 2;
-        c.insets = new Insets(5, 5, 3, 3);
-        add(jlPassword, c);
-
-        c = new GridBagConstraints();
-        c.fill = c.HORIZONTAL;
-        c.gridx = 1;
-        c.gridy = 2;
-        c.insets = new Insets(5, 5, 3, 3);
-        c.weightx = 1.0;
-        add(jpfPassword, c);
-
-        c = new GridBagConstraints();
-        c.anchor = c.SOUTHEAST;
-        c.gridx = 1;
-        c.gridy = 3;
-        c.insets = new Insets(5, 5, 3, 70);
-        c.weightx = 0.0;
-        add(jbCancel, c);
-
-        c = new GridBagConstraints();
-        c.anchor = c.SOUTHEAST;
-        c.gridx = 1;
-        c.gridy = 3;
-        c.insets = new Insets(5, 5, 3, 3);
-        c.weightx = 0.0;
-        add(jbOK, c);
-
-        setMinimumSize(new Dimension(400, 150));
-        setMaximumSize(new Dimension(1024, 150));
-        setAlwaysOnTop(true);
-
-        setSize(400, 150);
-        setLocationRelativeTo(null);
-
-        // OK => read supplied info and pass it on
-        jbOK.addActionListener(new ActionListener() {
-            public void actionPerformed(ActionEvent e) {
-                userCancelled = false;
-                dispose();
-            }
-        });
-
-        // Cancel => discard supplied info and pass on an empty auth



More information about the distro-pkg-dev mailing list