From: Vasudevan C. <vco...@gm...> - 2015-06-23 14:10:55
|
Hi Ahmed, Did the response data help you to isolate why HTMLUnit was not executing the Recaptcha.finish_reload method? I observed one more thing. The "th" value in reload was different BROWSERVERSION settings. Looks like you have set the useragent to IE. Another thing which I noticed is that HTMLUnit generates "th" string length to 286 bytes but real IE browser is setting the length to 308. Let me know if you need any additional information. Thanks for your help in advance Regards Vasu On 23 June 2015 at 02:45, Vasudevan Comandur <vco...@gm...> wrote: > Hi Ahmed, > > The response for the reload request is as follows: > > Recaptcha.finish_reload('03AHJ_VuupE7eFIaVzElqiohfV-RnNw6OlUHBMGQK1KNYGXK1KEtqX_zV0g6OOu9I_oqT7VXPBuWPDIf0ag4CnfN-7BEVvX8avSmWFcMtSzeLhkXBfGOFuSfAD-1oE_XlevZhg8OPKk-JS-v6nIhlW0wa-d9SErbtn8ClCB3Zw8Ak1Vzo-a_cTCxYrRWML4mc3j2Vs48KaR-ttkJDoPpP2w_ontPfxSmWhVg', > 'image', null, null); > > It is a Javascript and I did not see the next request going out of > HTMLUnit as part executing finish_reload method. > > I hope this helps. > > Regards > Vasu > > On 22 June 2015 at 20:07, Ahmed Ashour <asa...@ya...> wrote: > >> Hi Vasu, >> >> >> Is the above URL not getting out?. Please confirm. >> No, even after waiting for 60 seconds. >> >> Please try to isolate the root cause of the this happens. >> >> Ahmed >> ------------------------------ >> *From:* Vasudevan Comandur <vco...@gm...> >> *To:* Ahmed Ashour <asa...@ya...>; " >> htm...@li..." <htm...@li...> >> >> *Sent:* Monday, June 22, 2015 4:31 PM >> >> *Subject:* Re: [Htmlunit-user] HTMLUnit does not seem to execute the >> Javascript >> >> Hi Ahmed, >> >> Thanks for the quick reply. >> >> There will one more request after reload that should be sent out by >> HTMLUnit JS with the following URL >> >> http://www.google.com/recaptcha/api/image?c=<Value>&th=<Value> >> <http://www.google.com/recaptcha/api/reload?c=03AHJ_VuuJxcEAlP3p0KXevhNvSdWgtJIM9cmzQbO8X5Gu67S4ZA5F8pl39BrM9WwWuDHlhecfTmLoAHOwXewcBEQeHToglSKrbeR-i_T6X4pTX3R_c5rdtoq2m0-YO-wkg4r03er91AaklYR6HUWxSYMYBVnFrH8i2QICeoByfiMJD937D1scnxueoEKPOUS1Eso16cuu0B1Xm9oITS84J4Baz5QPExnPdg&k=6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83&reason=i&type=image&lang=de&th=,O8qwRlaYQ3I2Nm-2Bw9Y0Ts_q4fwAAABzqAAAABa2AC1wSLWCchSO1806pYdaFV5g9jCrj45n9cAM5r4rzgHg527aZ3M10YUKm1iVJeEUD4rZ19_NaFZF8I-zVEYgmiMCr5EUxVR8mkuhazTEVXvx3XsIDmR2n2lVUvoQNeMhXRabZFIRf0DeRI-WRmjpc0gwF4VH35kwVH2Sl150CQ8-gPfM-jpiZEcN5B0HhzVnybf5vINTNzO_1hqhBSw3Rc_6R2L0Be27DnUdwGZ_a6fVKuSxZ3tuA> >> >> Is the above URL not getting out?. Please confirm. >> >> Thanks for your help. >> >> Regards >> Vasu >> >> On 22 June 2015 at 19:45, Ahmed Ashour <asa...@ya...> wrote: >> >> >> >> Hi Vasu, >> >> Latest snapshot. >> >> URLs loaded are: >> >> http://www.patcurtis.com/captcha/recaptcha_demo.php >> >> >> http://api.recaptcha.net/challenge?k=6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83 >> >> >> http://www.google.com/recaptcha/api/challenge?k=6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83 >> >> http://www.google.com/recaptcha/api/js/recaptcha.js >> >> http://www.google.com/js/th/W5bj_YtY4Tq-XbVSluZLG7r5uKtSPEkuA-7vAHqkHjA.js >> >> >> http://www.google.com/recaptcha/api/reload?c=03AHJ_VuuJxcEAlP3p0KXevhNvSdWgtJIM9cmzQbO8X5Gu67S4ZA5F8pl39BrM9WwWuDHlhecfTmLoAHOwXewcBEQeHToglSKrbeR-i_T6X4pTX3R_c5rdtoq2m0-YO-wkg4r03er91AaklYR6HUWxSYMYBVnFrH8i2QICeoByfiMJD937D1scnxueoEKPOUS1Eso16cuu0B1Xm9oITS84J4Baz5QPExnPdg&k=6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83&reason=i&type=image&lang=de&th=,O8qwRlaYQ3I2Nm-2Bw9Y0Ts_q4fwAAABzqAAAABa2AC1wSLWCchSO1806pYdaFV5g9jCrj45n9cAM5r4rzgHg527aZ3M10YUKm1iVJeEUD4rZ19_NaFZF8I-zVEYgmiMCr5EUxVR8mkuhazTEVXvx3XsIDmR2n2lVUvoQNeMhXRabZFIRf0DeRI-WRmjpc0gwF4VH35kwVH2Sl150CQ8-gPfM-jpiZEcN5B0HhzVnybf5vINTNzO_1hqhBSw3Rc_6R2L0Be27DnUdwGZ_a6fVKuSxZ3tuA >> >> >> ------------------------------ >> *From:* Vasudevan Comandur <vco...@gm...> >> *To:* Ahmed Ashour <asa...@ya...>; " >> htm...@li..." <htm...@li...> >> >> *Sent:* Monday, June 22, 2015 3:24 PM >> >> *Subject:* Re: [Htmlunit-user] HTMLUnit does not seem to execute the >> Javascript >> >> HI Ahmed, >> >> Did it work fine with 2.17 version or with the latest snapshot? >> >> Also,if you can send me the last request URL that was sent to >> google.com as a string after executing the >> JS, that would help me. >> >> I appreciate your quick reply. >> >> Regards >> Vasu >> >> On 22 June 2015 at 14:52, Ahmed Ashour <asa...@ya...> wrote: >> >> >> >> Hi Vasu, >> >> There is no exception with me with the below: >> >> >> final CollectingAlertHandler handler = new >> CollectingAlertHandler(); >> try (final WebClient webClient = new WebClient()) { >> webClient.setAlertHandler(handler); >> >> final HtmlPage page = webClient.getPage(" >> http://www.patcurtis.com/captcha/recaptcha_demo.php"); >> Thread.sleep(5000); >> } >> finally { >> for (String x : handler.getCollectedAlerts()) { >> System.out.println("Alert " + x); >> } >> } >> >> >> Ahmed >> ------------------------------ >> *From:* Vasudevan Comandur <vco...@gm...> >> *To:* Ahmed Ashour <asa...@ya...>; " >> htm...@li..." <htm...@li...> >> >> *Sent:* Friday, June 19, 2015 5:53 PM >> *Subject:* Re: [Htmlunit-user] HTMLUnit does not seem to execute the >> Javascript >> >> Hi Ahmed, >> >> This is the error I am getting during script execution. I saw the >> download of recaptcha.js file happening. >> >> Inside Catch of With-page-withproxy #<ScriptException >> com.gargoylesoftware.htmlunit.ScriptException: Wrapped >> com.gargoylesoftware.ht >> mlunit.ScriptException: Exception invoking jsxFunction_createElement >> (dnaukri.clj#2503)> >> >> Is the same error happening to you or you are able to get the >> successful execution of JS? >> >> Thanks in advance for your help. >> >> Regards >> Vasu >> >> On 19 June 2015 at 18:42, Ahmed Ashour <asa...@ya...> wrote: >> >> >> >> Hi Vasu, >> >> The URL provided is of javascript. >> >> Please provide the URL of the html used, or your minimal java code. >> >> Ahmed >> ------------------------------ >> *From:* Vasudevan Comandur <vco...@gm...> >> *To:* "htm...@li..." < >> htm...@li...> >> *Sent:* Friday, June 19, 2015 12:40 PM >> *Subject:* [Htmlunit-user] HTMLUnit does not seem to execute the >> Javascript >> >> Hi, >> >> I tried the initial URL >> http://www.google.com/recaptcha/api/challenge?k=6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83 >> to google recaptcha service which sent the response >> a javascript file. The javascript file had a line as follows which is >> given below: >> >> *********************************************** >> var RecaptchaState = { >> challenge : >> '03AHJ_VuvDfAzpjod2KO2emYL2RLhxNxZvUyYqynapgkkc_OkLbqV93bxmdirD3B4Wtd66edBqRc_k6OZfBQ1XVAA9i0uMHPjQOKJ46OLZm0UenLc7trte3O6VMfItNaGtMGZGj35Sod10ITmuYFUwHjkHoak4OkacvVaJmXpnynPFfheVoqLO-ier_b2LmNpcfIXoIUqMACHWmf5JJYpKN_j7Hj2Xw2G9dyKAgmOpZkxsyV_n-9rNQqWdO0CcDddZlGc99CnadTMluLHl8gTwYsU15lqTD3DhbQ', >> timeout : 1800, >> lang : 'en', >> server : 'http://www.google.com/recaptcha/api/', >> site : '6Lf1-AQAAAAAAL9EskceOVja5Uh5_yo1FRtb1Q83', >> error_message : '', >> programming_error : '', >> is_incorrect : false, >> rtl : false >> }; >> >> document.write('<scr'+'ipt type="text/javascript" s'+'rc="' + >> RecaptchaState.server + 'js/recaptcha.js"></scr'+'ipt>'); >> >> ************************************************** >> >> I did not see the request in Charles for downloading the recaptcha.js >> as part of >> JS execution in HTMLUnit. >> >> I had enabled webclient to execute JS. >> >> Is there any issue with HTMLUnit.? >> >> I see the normal browser sending the request to download the >> recaptcha.js file. >> >> Any idea why this discrepancy. >> >> Any pointers and help is greatly appreciated >> >> Regards >> Vasu >> >> >> >> >> ------------------------------------------------------------------------------ >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> Monitor 25 network devices or servers for free with OpManager! >> OpManager is web-based network management software that monitors >> network devices and physical & virtual servers, alerts via email & sms >> for fault. Monitor 25 devices for free with no restriction. Download now >> http://ad.doubleclick.net/ddm/clk/292181274;119417398;o >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> Monitor 25 network devices or servers for free with OpManager! >> OpManager is web-based network management software that monitors >> network devices and physical & virtual servers, alerts via email & sms >> for fault. Monitor 25 devices for free with no restriction. Download now >> http://ad.doubleclick.net/ddm/clk/292181274;119417398;o >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> Monitor 25 network devices or servers for free with OpManager! >> OpManager is web-based network management software that monitors >> network devices and physical & virtual servers, alerts via email & sms >> for fault. Monitor 25 devices for free with no restriction. Download now >> http://ad.doubleclick.net/ddm/clk/292181274;119417398;o >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> Monitor 25 network devices or servers for free with OpManager! >> OpManager is web-based network management software that monitors >> network devices and physical & virtual servers, alerts via email & sms >> for fault. Monitor 25 devices for free with no restriction. Download now >> http://ad.doubleclick.net/ddm/clk/292181274;119417398;o >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> >> >> ------------------------------------------------------------------------------ >> Monitor 25 network devices or servers for free with OpManager! >> OpManager is web-based network management software that monitors >> network devices and physical & virtual servers, alerts via email & sms >> for fault. Monitor 25 devices for free with no restriction. Download now >> http://ad.doubleclick.net/ddm/clk/292181274;119417398;o >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> > |