weixin_33720452 2017-04-19 13:02 采纳率: 0%
浏览 123

在JMeter中捕获Cookie

I am facing issue for AJAX call in jmeter.

A new Ajax Token generated every time by taking value of cookies

efpcookieiQmdOSdtYvVcktctGnNfrwCC4350121699716256984xxxxxxxxx=nAgvF4MhWoTTb7NTV8zaowCC;

I need to pass the cookie in the following URL:

http://www.example.com/?usecase=maintain_account&command=load_acc_type_command&guid=${uid6}&commandorigin=0.create_account_step1_view&fpid=efpcookieiQmdOSdtYvVcktctGnNfrwCC4350121699716256984xxxxxxxxx&view=create_account_step1_view&pipe=ajax&hash=hash1287912XXXX&ajaxtoken=${ajaxtokan}&accProdId=1

How can I capture this?

  • 写回答

1条回答 默认 最新

  • 衫裤跑路 2017-04-19 13:39
    关注

    Edit the jmeter.properties file inside the JMeter bin directory, and set CookieManager.save.cookies=true

    Restart JMeter and add a HTTP Cookie Manager. Now, just replace the Cookie value with ${COOKIE_fpid}, this is:

    usecase=maintain_account&command=load_acc_type_command&guid=${uid6}&commandorigin=0.create_account_step1_view&fpid=${COOKIE_fpid}&view=create_account_step1_view&pipe=ajax&hash=hash1287912XXXX&ajaxtoken=${ajaxtokan}&accProdId=1

    评论

报告相同问题?

悬赏问题

  • ¥20 机器学习能否像多层线性模型一样处理嵌套数据
  • ¥20 西门子S7-Graph,S7-300,梯形图
  • ¥50 用易语言http 访问不了网页
  • ¥50 safari浏览器fetch提交数据后数据丢失问题
  • ¥15 matlab不知道怎么改,求解答!!
  • ¥15 永磁直线电机的电流环pi调不出来
  • ¥15 用stata实现聚类的代码
  • ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效