Response message: Unauthorized in Jmeter using a https request
I'm new to JMeter, I am recording a web application with HTTPS test script recorder but when I play it after recording I am getting error 401 on the login screen of the application. Could anyone please help me out.
Thread Name: Thread Group 1-1 Sample Start: 2018-10-18 13:32:08 IST Load time: 719 Connect Time: 1 Latency: 719 Size in bytes: 650 Sent bytes:785 Headers size in bytes: 464 Body size in bytes: 186 Sample Count: 1 Error Count: 1 Data type ("text"|"bin"|""): text Response code: 401 Response message: Unauthorized Response headers: HTTP/1.1 401 Unauthorized Date: Thu, 18 Oct 2018 08:02:09 GMT Set-Cookie: JSESSIONID=b41b8586e333d68ac7ee1077d9c377dec3088845eccd0437d3de9910bed77f3b.e34Qah0Rb3eObi0Lb38PahiKa3aTe0; path=/OA_HTML; secure Keep-Alive: timeout=15 Connection: Keep-Alive Transfer-Encoding: chunked Content-Type: application/xml Set-Cookie: BIGipServersteria-otl_oracleoutsourcing_com_http=1686646671.7975.0000; expires=Thu, 18-Oct-2018 16:02:09 GMT; path=/; Httponly; Secure HTTPSampleResult fields: ContentType: application/xml DataEncoding: null
morde last edited by
If it doesn't help - inspect your script and try to locate dynamic parameters. The majority of modern web applications widely use dynamic data for various reasons including but not limited to client state tracking or for CSRF protection
Try recording your scenario one more time and compare the scripts. If there are differences - you will need to perform correlation of the dynamic parameters to wit extract them from the previous response using suitable JMeter Post-Processor and save it into a JMeter Variable. Then replace recorded hard-coded parameter with the variable from previous step.