|
7#
楼主 |
发表于 2013-7-10 16:37:11
|
只看该作者
web_reg_save_param("jsessionid",
"LB/IC=cas_61/login;jsessionid=",
"RB/IC=\"",
"Ord=1",
"NotFound=WARNING",
"Search=All",
LAST);
web_reg_save_param("lt",
"LB/IC=<input type=\"hidden\" name=\"lt\"\r\n value=\"",
"RB/IC=\"",
"Ord=1",
"NotFound=WARNING",
"Search=All",
LAST);
web_url("check_cert_status.jsp",
"URL=http://192.168.3.18:9014/cas_61/check_cert_status.jsp",
"Resource=0",
"RecContentType=text/html",
"Referer=",
"Snapshot=t2.inf",
"Mode=HTML",
EXTRARES,
"Url=images/livecom_h_default_ngls_str.jpg", "Referer=http://192.168.3.18:9014/cas_61/login", ENDITEM,
"Url=images/dot-h.gif", "Referer=http://192.168.3.18:9014/cas_61/login", ENDITEM,
"Url=../favicon.ico", "Referer=", ENDITEM,
LAST);
lr_output_message("the jsessionid is: %s", lr_eval_string("{jsessionid}"));
lr_output_message("the It is: %s", lr_eval_string("{It}"));
回放结果:Action.c(43): the jsessionid is: 6LR5RdXTKWNfFsvncykLy4txXMG6Lcthw68kLJMp5MTH5dSQv99C!79763331
Action.c(44): the It is: {It}---
web_submit_data("login;jsessionid={jsessionid}",
"Action=http://192.168.3.18:9014/cas_61/login;jsessionid={jsessionid}",
"Method=POST",
"RecContentType=text/html",
"Referer=http://192.168.3.18:9014/cas_61/login",
"Snapshot=t3.inf",
"Mode=HTML",
ITEMDATA,
"Name=username", "Value=4403013070043", ENDITEM,
"Name=password", "Value=Test1234", ENDITEM,
"Name=lt", "Value={lt}", ENDITEM,
"Name=_eventId", "Value=submit", ENDITEM,
"Name=submit", "Value=登录", ENDITEM,
EXTRARES,
"Url=images/menulist.gif", ENDITEM,
"Url=images/book_next.png", ENDITEM,
"Url=../favicon.ico", "Referer=", ENDITEM,
LAST);
lr_output_message("the jsessionid is: %s", lr_eval_string("{jsessionid}"));
回放结果:lgoin.c(4): Error -26612: HTTP Status-Code=500 (Internal Server Error) for "http://192.168.3.18:9014/cas_61/login;jsessionid=6LR5RdXTKWNfFsvncykLy4txXMG6Lcthw68kLJMp5MTH5dSQv99C!79763331" [MsgId: MERR-26612]
可见是{It}没有取到值导致登录失败,打开http://192.168.3.18:9014/cas_61/check_cert_status.jsp页面,查看源代码
<input type="hidden" name="lt" value="_cEA9E6218-B5B9-7379-8862-EB3ED0239B6F_kEE910C9A-FA7F-04A6-BDC1-7B52C41363E9" />
It的左右边界应该没放错,位置也应该在http://192.168.3.18:9014/cas_61/check_cert_status.jsp,如果是的话也应该没错。
那么,问题出在哪里呢? |
|