|
|
|
|
|
|
|
|
public static final String ATTRIBUTE_ERROR = "error"; |
|
|
public static final String ATTRIBUTE_ERROR = "error"; |
|
|
|
|
|
|
|
|
// will hold the UIDL security key (for XSS protection) once received |
|
|
// will hold the UIDL security key (for XSS protection) once received |
|
|
private String uidl_security_key = "init"; |
|
|
|
|
|
|
|
|
private String uidlSecurityKey = "init"; |
|
|
|
|
|
|
|
|
private final HashMap<String, String> resourcesMap = new HashMap<String, String>(); |
|
|
private final HashMap<String, String> resourcesMap = new HashMap<String, String>(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
final String extraParams, final boolean forceSync) { |
|
|
final String extraParams, final boolean forceSync) { |
|
|
startRequest(); |
|
|
startRequest(); |
|
|
// Security: double cookie submission pattern |
|
|
// Security: double cookie submission pattern |
|
|
final String rd = uidl_security_key + VAR_BURST_SEPARATOR + requestData; |
|
|
|
|
|
|
|
|
final String rd = uidlSecurityKey + VAR_BURST_SEPARATOR + requestData; |
|
|
VConsole.log("Making UIDL Request with params: " + rd); |
|
|
VConsole.log("Making UIDL Request with params: " + rd); |
|
|
String uri; |
|
|
String uri; |
|
|
if (configuration.usePortletURLs()) { |
|
|
if (configuration.usePortletURLs()) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Get security key |
|
|
// Get security key |
|
|
if (json.containsKey(UIDL_SECURITY_TOKEN_ID)) { |
|
|
if (json.containsKey(UIDL_SECURITY_TOKEN_ID)) { |
|
|
uidl_security_key = json.getString(UIDL_SECURITY_TOKEN_ID); |
|
|
|
|
|
|
|
|
uidlSecurityKey = json.getString(UIDL_SECURITY_TOKEN_ID); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (json.containsKey("resources")) { |
|
|
if (json.containsKey("resources")) { |
|
|
|
|
|
|
|
|
windowName = newName; |
|
|
windowName = newName; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
protected String getWindowName() { |
|
|
|
|
|
return windowName; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
protected String getUidlSecurityKey() { |
|
|
|
|
|
return uidlSecurityKey; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* Use to notify that the given component's caption has changed; layouts may |
|
|
* Use to notify that the given component's caption has changed; layouts may |
|
|
* have to be recalculated. |
|
|
* have to be recalculated. |