|
现在症状又变了,没有再现昨天的form没有找到,我先把过程详细说一下:
1。脚本如下,回放过程一切正常,加红处为输入项
#include "web_api.h"
Action()
{
// web_add_cookie("10%2E1%2E5%2E165%2Fbbs%2F=StatUserID=15130508&usercookies=&userid=&userhidden=&password=&userclass=&username=; DOMAIN=10.1.5.165");
web_url("bbs",
"URL=http://10.1.5.165/bbs",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t1.inf",
"Mode=HTML",
EXTRARES,
"Url=/bbs/Skins/Default/dvmenubg3.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/Skins/Discuz/nofollow.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/Skins/Discuz/lastpost.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/images/dv_001.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/images/2007.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/images/dv_003.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/Skins/Discuz/plus.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=/bbs/images/dv_002.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
LAST);
lr_think_time( 2 );
lr_start_transaction("用户登录");
lr_think_time( 12 );
lr_rendezvous("用户登录集合");
lr_think_time( 2 );
web_submit_form("login.asp",
"Snapshot=t2.inf",
ITEMDATA,
"Name=username", "Value=user21", ENDITEM,
"Name=password", "Value=111111", ENDITEM,
"Name=CookieDate", "Value=不保存", ENDITEM,
"Name=submit", "Value=登录", ENDITEM,
EXTRARES,
"Url=Skins/Default/dvmenubg3.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/nofollow.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/lastpost.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/plus.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/2007.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_003.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_001.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_002.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
LAST);
lr_end_transaction("用户登录", LR_AUTO);
lr_think_time( 4 );
/* lr_start_transaction("用户退出");
lr_think_time( 3 );
web_link("退出",
"Text=退出",
"Snapshot=t3.inf",
EXTRARES,
"Url=Skins/Default/dvmenubg3.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/nofollow.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/lastpost.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=Skins/Discuz/plus.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/2007.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_003.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_001.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
"Url=images/dv_002.gif", "Referer=http://10.1.5.165/bbs/", ENDITEM,
LAST);
lr_end_transaction("用户退出", LR_AUTO);
*/
return 0;
}
2。控制台加压,一个用户,参数没有替换,顺利进行,貌似成功,但在结果分析中查看页面,发现应用返回错误,如下
|
|