jmeter--cookie的获取
2019-04-07 本文已影响124人
那个村王富贵
我们以 www.zxzx119.com为列
首先通过控制台或者抓包工具获取他的登录接口 通过jmeter模拟他的登录请求

运行一下结果:

运行一下 发现取样器结果里面有set-cookie 根据cookie运行机制 有以下思路
cookie是通过set-cookie 设置的(看不懂的某人就不要在意)
所以 第一步设置正则提取器来提取set-cookie:

然后在http信息头管理器里添加参数set-cookie的变量

通过抓包工具等获取 返回地址的接口 然后使用jmeter模拟请求

然后运行一下 pretty
