Advanced Web application definition not entering data into Change Password page

  • 7940289
  • 19-Aug-2009
  • 30-Jan-2014

Environment

SecureLogin
SecureLogin SSO
All Versions


Situation

Issue

The customer is SSO enabling a web page. The application name is intranet.hrsystem. You can either use the wizard or write a definition yourself if you wish to customize (e.g. add auditing, change the default messages etc.)

The customer wants SecureLogin to handle all pages in the web app e.g. ChangePassword.htm, Logon,.htm, LoginFailed.htm etc. and decided to create an application definition. They began by creating the following ""Advanced Web"" application definition for the web site.

However, logon via SSO is handled correctly but the ChangePassword process does not enter any text. Nothing happens at all.

#=============================================================# 
# URL/ID: intranet.hrsystem # 
# Name: HR Web Site # 
# Type: Advanced Web # #=============================================================# #==================# 
# Logon Prompt # 
#==================# 
If -Text ""Logon"" 
SetPrompt ""HR UserID:"" Type $UserID 
SetPrompt ""HR Password:"" Type $Password password 
EndIf 
#===========================# 
# Change Password Success # 
# Set and Save Password # 
#===========================# 
If -Text ""Password Changed Successfully"" 
Set $Password ?NewPwd 
EndScript 
EndIf 
#==========================# 
# Change Password Prompt # 
#==========================# 
If -Text ""Current Password"" 
Type $Password #1 
ChangePassword ?NewPwd ""Please enter a new password"" 
Type ?NewPwd #2 
Type ?NewPwd #3 
Submit 
EndIf 
SetPrompt ""Please enter your logon credentials.""

Cause

The application definition for this web site would not work properly with a mix of the following commands in the script, the web page was ""confused"";

Type $Password password

Web programmers define which fields on the page are password fields. This command will locate the password field and enter the stored password into it.

And

Type $Password #2

This command searches for the second field on the page and enters the password into it. #1 identifies the first field, #3 identifies the third field and so on.

Resolution

Cause

The application definition for this web site would not work properly with a mix of the following commands in the script, the web page was ""confused"";

Type $Password password

Web programmers define which fields on the page are password fields. This command will locate the password field and enter the stored password into it.

And

Type $Password #2

This command searches for the second field on the page and enters the password into it. #1 identifies the first field, #3 identifies the third field and so on.

Solution

SecureLogin is extremely flexible and customizable. SSO administrators can configure SecureLogin to web pages in a number of ways, depending on your requirements.

1. In this case the SSO administrator edited the application connector and removed references to Type $Password password as per the following;

#================# 
# Logon Prompt # 
#================# 
If -Text ""Logon"" 
SetPrompt ""HR UserID:"" 
Type $UserID #1 
SetPrompt ""HR Password:"" 
Type $Password #2 
Submit 
EndIf 
#==========================# 
# Change Password Success # 
#==========================# 
If -Text ""Password Changed Successfully"" 
Set $Password ?NewPwd 
EndScript 
EndIf 
#==========================# 
# Change Password Prompt # 
#==========================# 
If -Text ""Current Password"" 
Type $Password #1 
ChangePassword ?NewPwd ""Please enter a new password"" 
Type ?NewPwd #2 
Type ?NewPwd #3 
Submit 
EndIf 
#==========================# 
# Change Password Success # 
#==========================# 
If -Text ""Password Changed Successfully"" 
Set $Password ?NewPwd 
EndScript 
EndIf 
SetPrompt ""Please enter your logon credentials.""


2. In other cases, it might make sense to ""reverse"" that logic and set SecureLogin up so it uses the password identifier in the Type command. You should test to see which solution meets your requirements.

#=================# 
# Logon Prompt # 
#=================# 
If -Text ""Logon"" 
SetPrompt ""HR UserID:"" 
Type $UserID 
SetPrompt ""HR Password:"" 
Type $Password password 
EndIf 
#===========================# 
# Change Password Success # 
#===========================# 
If -Text ""Password Changed Successfully"" 
Set $Password ?NewPwd 
EndScript 
EndIf 
#============================# 
# Change Password Prompt # 
#============================# 
If -Text ""Current Password"" 
Type $Password password 
ChangePassword ?NewPwd ""Please enter a new password"" 
Type ?NewPwd password  
Type ?NewPwd password 
EndIf 
SetPrompt ""Please enter your logon credentials.""