From: ken on
hello ALL

im making some simple python post script but it not working well.

there is 2 part to have to login.

first login is using '
UserInfo.asp' this one.

and second login is using '

i can login first login page, but i couldn't login second page

and return some error 'illegal access' such like .

i heard this is related with some cooke but i don't know how to
implement to resolve this problem.

if anyone can help me much appreciated!! Thanks!

import re,sys,os,mechanize,urllib,time
import datetime,socket

params = urllib.urlencode({'ID':'ph896011', 'PWD':'pk1089' })
rq = mechanize.Request("
UserInfo.asp", params)
rs = mechanize.urlopen(rq)
data =

logged_fail = r';history.back();</script>' in
if not logged_fail:
print 'login success'
params = urllib.urlencode({'PASSWORD':'pk1089'})
rq = mechanize.Request("
UserCheckPWExec.asp", params )
rs = mechanize.urlopen(rq)
data =
print data
print 'error'