On 13/11/2007, Richard G. Reyes <[EMAIL PROTECTED]> wrote: > I changed the misspelled subject :) > > Richard G. Reyes wrote: > > Hi All, > > > > I am trying to automate a configuration of a device via httpclient. The > > device have a web interface and I can configure it via browser without a > > problem. But when I try to configure it via httpclient my application > > just hangs here... > > > >> 2007/11/13 15:52:24:984 CST [DEBUG] HttpConnection - Open connection > >> to 192.168.15.18:80 > >> 2007/11/13 15:52:25:000 CST [DEBUG] header - >> "POST /dologin.htm > >> HTTP/1.1[\r][\n]" > >> 2007/11/13 15:52:25:000 CST [DEBUG] HttpMethodBase - Adding Host > >> request header > >> 2007/11/13 15:52:25:000 CST [DEBUG] HttpMethodBase - Default charset > >> used: ISO-8859-1 > >> 2007/11/13 15:52:25:015 CST [DEBUG] HttpMethodBase - Default charset > >> used: ISO-8859-1 > >> 2007/11/13 15:52:25:015 CST [DEBUG] header - >> "User-Agent: Jakarta > >> Commons-HttpClient/3.1[\r][\n]" > >> 2007/11/13 15:52:25:015 CST [DEBUG] header - >> "Host: > >> 192.168.15.18[\r][\n]" > >> 2007/11/13 15:52:25:015 CST [DEBUG] header - >> "Content-Length: > >> 31[\r][\n]" > >> 2007/11/13 15:52:25:015 CST [DEBUG] header - >> "Content-Type: > >> application/x-www-form-urlencoded[\r][\n]" > >> 2007/11/13 15:52:25:015 CST [DEBUG] header - >> "[\r][\n]" > >> 2007/11/13 15:52:25:015 CST [DEBUG] content - >> > >> "P2=admin&gnkey=0b82&Login=Login" > >> 2007/11/13 15:52:25:015 CST [DEBUG] EntityEnclosingMethod - Request > >> body sent > > > > This above is the last line and stops there. I have captured the the > > post and heres what I got. Theres a huge difference between the post the > > browser sent from the one sent by the httpclient. But I am not certain > > that the problem lies in here. > > > > Heres the browser post packet... > >> POST /dologin.htm HTTP/1.1 > >> Host: 192.168.15.18 > >> User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; > >> rv:1.8.1.9) Gecko/20071025 Firefox/2.0.0.9 > >> Accept: > >> text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5 > >> > >> Accept-Language: en-us,en;q=0.5 > >> Accept-Encoding: gzip,deflate > >> Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 > >> Keep-Alive: 300 > >> Connection: keep-alive > >> Referer: http://192.168.15.18/index.htm > >> Content-Type: application/x-www-form-urlencoded > >> Content-Length: 29
Does not agree with other post. > >> > > > > Heres the application post packet... > >> POST /dologin.htm HTTP/1.1 > >> User-Agent: Jakarta Commons-HttpClient/3.1 > >> Host: 192.168.15.18 > >> Content-Length: 31 Does not agree. I've no idea whether this is the problem or not, but it seems the most likely to me ... > >> Content-Type: application/x-www-form-urlencoded > >> > > > > I hope someone could point me to the right direction in solving this > > problem. > > > > Thanks in advance. > > Richard > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]