diff --git a/rse/plugins/org.eclipse.rse.ui/UI/org/eclipse/rse/ui/dialogs/SystemPasswordPromptDialog.java b/rse/plugins/org.eclipse.rse.ui/UI/org/eclipse/rse/ui/dialogs/SystemPasswordPromptDialog.java index 20fc33112fa..78aeab584e0 100644 --- a/rse/plugins/org.eclipse.rse.ui/UI/org/eclipse/rse/ui/dialogs/SystemPasswordPromptDialog.java +++ b/rse/plugins/org.eclipse.rse.ui/UI/org/eclipse/rse/ui/dialogs/SystemPasswordPromptDialog.java @@ -16,6 +16,7 @@ * Martin Oberhuber (Wind River) - [184095] Replace systemTypeName by IRSESystemType * David Dykstal (IBM) - [210474] Deny save password function missing * David Dykstal (IBM) - [210242] Credentials dialog should look different if password is not supported or optional + * Richie Yu (IBM) - [241716] Handle change expired password ********************************************************************************/ package org.eclipse.rse.ui.dialogs; @@ -504,6 +505,8 @@ public final class SystemPasswordPromptDialog extends SystemPromptDialog impleme IRSESystemType systemType = connectorService.getHost().getSystemType(); ICredentials credentials = new SystemSignonInformation(hostName, userId, password, systemType); SystemMessage m = signonValidator.validate(credentials); + // update the password in case an expired password was changed in validate - ry + password = credentials.getPassword(); setErrorMessage(m); } boolean closeDialog = (getErrorMessage() == null); diff --git a/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/ui/subsystems/StandardCredentialsProvider.java b/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/ui/subsystems/StandardCredentialsProvider.java index 0466cd26071..98bf2f846fa 100644 --- a/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/ui/subsystems/StandardCredentialsProvider.java +++ b/rse/plugins/org.eclipse.rse.ui/subsystems/org/eclipse/rse/ui/subsystems/StandardCredentialsProvider.java @@ -12,6 +12,7 @@ * David Dykstal (IBM) - [210474] Deny save password function missing * David Dykstal (IBM) - [225089][ssh][shells][api] Canceling connection leads to exception * Martin Oberhuber (Wind River) - [218304] Improve deferred adapter loading + * Richie Yu (IBM) - [241716] Handle change expired password ********************************************************************************/ package org.eclipse.rse.ui.subsystems; @@ -206,8 +207,11 @@ public class StandardCredentialsProvider extends AbstractCredentialsProvider { } ICredentialsValidator validator = getSignonValidator(); boolean signonValid = true; + ICredentials credentials = getCredentials(); if (validator != null) { - SystemMessage m = validator.validate(getCredentials()); + SystemMessage m = validator.validate(credentials); + // update the password in case an expired password was changed in validate - ry + password = credentials.getPassword(); signonValid = (m == null); if (!signonValid) { // If we ran into an invalid stored password we need to tell the user. Shell shell = getShell();