aboutsummaryrefslogtreecommitdiffstats
path: root/netx/net/sourceforge/jnlp/security/SecurityDialog.java
diff options
context:
space:
mode:
authorOmair Majid <[email protected]>2011-02-28 14:30:39 -0500
committerOmair Majid <[email protected]>2011-02-28 14:30:39 -0500
commit5df1503c77c6c1b6104baa22354bd1cd215f9cbc (patch)
tree3eee8ad62ede221369452fba3dd2423113e0df38 /netx/net/sourceforge/jnlp/security/SecurityDialog.java
parent05dd25bd43df11fc874d857ced49bbe3c6e72a74 (diff)
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 <[email protected]> * 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 (limited to 'netx/net/sourceforge/jnlp/security/SecurityDialog.java')
-rw-r--r--netx/net/sourceforge/jnlp/security/SecurityDialog.java4
1 files changed, 4 insertions, 0 deletions
diff --git a/netx/net/sourceforge/jnlp/security/SecurityDialog.java b/netx/net/sourceforge/jnlp/security/SecurityDialog.java
index cb37395..2fc201d 100644
--- a/netx/net/sourceforge/jnlp/security/SecurityDialog.java
+++ b/netx/net/sourceforge/jnlp/security/SecurityDialog.java
@@ -219,6 +219,8 @@ public class SecurityDialog extends JDialog {
dialogTitle = "Applet Warning";
else if (dialogType == DialogType.NOTALLSIGNED_WARNING)
dialogTitle = "Security Warning";
+ else if (dialogType == DialogType.AUTHENTICATION)
+ dialogTitle = "Authentication Required";
setTitle(dialogTitle);
setModalityType(ModalityType.MODELESS);
@@ -291,6 +293,8 @@ public class SecurityDialog extends JDialog {
panel = new AppletWarningPane(this, this.certVerifier);
else if (dialogType == DialogType.NOTALLSIGNED_WARNING)
panel = new NotAllSignedWarningPane(this);
+ else if (dialogType == DialogType.AUTHENTICATION)
+ panel = new PasswordAuthenticationPane(this, extras);
add(panel, BorderLayout.CENTER);
}