Highlighted
Absent Member.
Absent Member.
2703 views

How to add a new web_custom_request, how do you know which URL to use?

 

Hi,

Please help me correlate the value ab.

Inorder to correlate the sessionid I looked at the response under the web_custom_request("login") transaction id 113.  Correlation for jsessionid worked. 
However transaction id 113 does not have the response for ab vallue.  I found the response for ab under transaction id 159.


Now I don't understand where to put my ab correlation.  I belive I'm missing a web_custom_request for transaction id 159,
How can I add a custom request?  how do I know which URL to enter?

//Correlations
  web_reg_save_param_ex(
  "ParamName=jsessionid", 
  "LB=JSESSIONID=", 
  "RB=;",  
  SEARCH_FILTERS,
  "Scope=Cookies",  
  "RequestUrl=*/login*",   
  LAST);


 web_reg_save_param_ex(
  "ParamName=AB",
  "LB=name=\"ab\" value=\"",  
  "RB=\"",
  SEARCH_FILTERS,
  "IgnoreRedirections=Yes",
  "RequestUrl=*/login*", 
  LAST);

 

 

//Login request
 web_custom_request("login;jsessionid=saewerwqrqwqrwrwreqwerqwerqwerqwert87o0MfsVw4!196633223",
  "URL=https://mysite/login;jsessionid={jsessionid}?service=https%1A%4F%site%2Fabc%2F22%2Flogon%2Fogon.xhtml%3FtargetWindowName%3DHome",
  "Method=POST",
  "Resource=0",
  "RecContentType=text/html",   
  "Referer=https://mysite/login?service=https%1A%4F%site%2Fabc%2F22%2Flogon%2Fogon.xhtml%3FtargetWindowName%3DHome",
  "Snapshot=t20.inf",
  "Mode=HTTP",
  "Body=username=usertest&password=testtest&ab={AB}&submit=Login",
  LAST);
 

Here's the response for ab under transaction id 159.

<input type="hidden" name="AB" value="LT-1222-44EG555FFFHhtP0t2dPOlvJDSFGKKK3Eeayq" />

 

Thanks in advance

0 Likes
2 Replies
Highlighted
Regular Contributor.
Regular Contributor.

Re: How to add a new web_custom_request, how do you know which URL to use?

Hi, 

Did you write the correlation function by yourself? Normally it will be generated automatically using correlation studio.

In your example, you should use "LB/IC=name=\"ab\" value=\"" because "ab" does not match "AB". 

And "IgnoreRedirections=Yes" will ignore all the redirection pages so they won't be searched.

0 Likes
Highlighted
Absent Member.
Absent Member.

Re: How to add a new web_custom_request, how do you know which URL to use?

Hi,

Thanks for the response, I did write the correlation myself;  thanks for pointing out the problem;  however even after fixing the correlation I'm still getting the same error. 

Why doesn't transacton id 159 has the Add Event section?  Isn't that a problem?

web_reg_save_param_ex(
  "ParamName=AB",
  "LB/IC=name=\"ab\" value=\"", 
  "RB/IC=\"",
  SEARCH_FILTERS,
  "IgnoreRedirections=No",
  "RequestUrl=*/login*",
  LAST);

 

 

thanks

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.