3. Publishing Applications to Users
7. SGD Servers, Arrays, and Load Balancing
B. Secure Global Desktop Server Settings
C. User Profiles, Applications, and Application Servers
Login Scripts Supplied With SGD
Login Scripts Used When Configuring Applications
Login Scripts Containing Common Code
Login Script Tcl Commands and Procedures
Controlling the SGD Application Authentication Dialog
Guaranteed Login Script Variables
The login scripts supplied with SGD use several Tcl commands and procedures for communication with the application server.
The Tcl commands are commands that are defined in the Execution Protocol Engine component of SGD. The commands can be used in your own login scripts to provide control over the connection to the application server, and the display of the SGD Application Authentication and Progress dialogs.
The Tcl procedures are defined in the login scripts only. The procedures can be used to provide more control over the SGD Application Authentication dialog.
The following Tcl commands and procedures are used to control the display of the SGD Application Authentication dialog when starting applications:
authrequest [ -normal | -changed ] -showuser 0|1 -title title -message message -customuserlabel 0|1 -userlabel label -custompasswdlabel 0|1 -passwdlabel label -showpasscache 0|1 -showsmartcard 0|1 -isuserdialog 0|1|2
This Tcl command displays a dialog box that indicates a problem with the user name or password.
Typically you do not call the authrequest command directly in your login scripts. Instead, you use the defined Tcl procedures to call this command with the required arguments.
This command has the following arguments.
|
The following example displays a dialog box that says the password is incorrect.
authrequest -normal
Displays a dialog box that indicates a problem with the user name or password.
This Tcl procedure calls the authrequest command with the following options.
authenticate [ -normal | -changed ]
Displays a dialog box that indicates a problem with the user name or password. You can use your own title for the dialog and display your own message. You can also control whether the user name and password fields display.
This Tcl procedure calls the authrequest command with the following arguments.
authenticate2 [ -normal | -changed ] -showuser 0|1 -showpasswd 0| -title title -message message
Displays a dialog box that indicates a problem with the user name or password. You can fully customize the authentication dialog.
With this procedure, the Execution Protocol Engine does not check the text the user types in the user name field. If Secure Shell (SSH) is used as the connection method for the application and the user changes the user name, the Execution Protocol Engine does not break the connection and reconnect as the new user name. This can cause applications to fail to start. If you are using SSH and allow the user to change the user name, use the userauthenticate procedure instead.
This Tcl procedure calls the authrequest command with the following arguments.
customauthenticate [ -normal | -changed ] -showuser 0|1 -title title -message message -customuserlabel 0|1 -userlabel label -custompasswdlabel 0|1 -passwdlabel label -showpasscache 0|1 -showsmartcard 0|1
Displays a dialog box that indicates a problem with the user name or password. You can fully customize the authentication dialog.
This procedure is the same as customauthenticate except that it does check whether the user has changed the user name. If the user name is changed, the Execution Protocol Engine breaks the connection to the application server and reconnects as the changed user.
This Tcl procedure calls the authrequest command with the following arguments:
userauthenticate [ -normal | -changed ] -showuser 0|1 -showpasswd 0|1 -title title -message message -customuserlabel 0|1 -userlabel label -custompasswdlabel 0|1 -passwdlabel label -showpasscache 0|1 -showsmartcard 0|1
The following Tcl commands are used to control the display of the SGD progress dialog when starting applications:
loaderror error
You can use this Tcl command to override the error message returned by
the login script. You can use this function, for example, to replace the
standard login script error messages with your own message. If the application fails
to start, the error is displayed in the progress dialog and in the
log files. See Login Script Error Messages.
clienttimer [ time ] [ message ] [ timers ]
This Tcl command displays message in the progress dialog box for the specified time. The progress bar has timers sections in total. The following is an example.
clienttimer 10 "Launching the application" 4
canceltimer
This Tcl command cancels the clienttimer command. This command has no arguments.
progress [ message ]
This Tcl command displays message in the progress dialog box. The following is an example.
progress "Initializing..."
The following Tcl commands are used to control the connection to the application server:
setbuffer [ -buffer num ] [ -output 0|1 ]
This Tcl command defines the number of bytes to read from the application server.
|
The following is an example.
setbuffer -buffer 1000
locallaunch [ -start ] [ -abort ] [ -user launchspec -root launchspec ]
This Tcl command starts an application when the application server is also the SGD server. This is known as an optimized launch.
|
The following is an example.
locallaunch -abort
tarantella -nosocket -portnumber num -thirdtiershell shell
This Tcl command is used to configure the connection to the application server. You must configure the connection before you use the sgdconnect command.
|
The following example connects to the application server on TCP port 5999.
tarantella -portnumber 5999
sgdconnect
Instructs the Execution Protocol Engine to connect to the application server. This command has no arguments.
Most of the SGD login scripts use sgdconnect to make the connection. If you want to handle the connection to the application server yourself, you must ensure that your script does not use this command.
The wcpwts.exp standard login script is an example of a login script that does not use this command to connect to an application server.