beautypg.com

HID ActivID Web Soft Token and Citrix XenApp User Manual

Page 10

background image

ActivIdentity Web Soft Token Option for Citrix® XenApp™ | Integration Handbook

P 10

External Use | May 31, 2012 | © 2012 ActivIdentity

// Try an applet method just in case

var tokenStatus=null;

try {

tokenStatus = applet.getTokenStatus();

} catch (err) {

AIsetTimeout("checkAppletLoad()", 500);

return;

}

// Applet is now loaded and we have its status

try {

// Get token serial number and update the UI

var sn = applet.getSerialNumber();

// Check the token status

// 0 = READY TO BE ACTIVATED

// 1 = ACTIVATED

// 2 = LOCKED

if (tokenStatus!=1) {

if(tokenStatus == 2 ) {

AIshowError("<%=wiContext.getString("AITokenLocked")%>");

} else {

AIshowError("<%=wiContext.getString("AITokenNotEnabled")%>");

}

return;

} else {

AIsetFocusPasscode();

// Paste the token in if they are in pinless mode

}