QtSslSocket * socket = new QtSslSocket( QtSslSocket::Cliet );connect( socket, SIGNAL(connected()), SLOT(connected()) );...void This::connected(){ QHttp * http = new Http( "www.site.com", 80, this ); http->setSocket( socket ); // get OR post}
<FORM ACTION="https://bla-bla" METHOD="POST"><INPUT type=text ID=login NAME=login TABINDEX=1 class=auth SIZE=20 MAXLENGTH=20><INPUT align=left ID=p type=password NAME=p TABINDEX=2 class=auth SIZE=19 MAXLENGTH=20><INPUT type=image onMouseDown="this.src='../images/logo/3_1_1.gif';"; onMouseOut="this.src='../images/logo/3_1.gif';" src="../images/logo/3_1.gif" alt='Вход' border=0><INPUT type=hidden NAME=scr VALUE='e14a534a6358930b76849224abefded5c6ee431c'><INPUT type=hidden NAME=action VALUE='login'></FORM>
loginpsrcaction
socket->connectToHost("some-host", 443);my_http->setHost("some-host", 443);my_http->setSocket(socket);QHttpRequestHeader header("POST", "/index.spl"); header.setValue("Host", "some-host"); header.setContentType("application/x-www-form-urlencoded"); my_http->request(header, "login=****&p=******&src=58b28b0351e2126466ade74ce709cad9b34e704f&action=login");
QHttpRequestHeader header("POST", "/index.spl"); header.setValue("Host", "some-host");header.setValue ("login","***");header.setValue ("p","***");header.setValue ("src","58b28b0351e2126466ade74ce709cad9b34e704");header.setValue ("action","login"); my_http->request(header);