From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2001:558:fe21:29:69:252:207:43; helo=resqmta-ch2-11v.sys.comcast.net; envelope-from=eklhad@comcast.net; receiver= Received: from resqmta-ch2-11v.sys.comcast.net (resqmta-ch2-11v.sys.comcast.net [IPv6:2001:558:fe21:29:69:252:207:43]) by hurricane.the-brannons.com (Postfix) with ESMTPS id 8B59277DC3 for ; Tue, 13 Mar 2018 00:47:15 -0700 (PDT) Received: from resomta-ch2-10v.sys.comcast.net ([69.252.207.106]) by resqmta-ch2-11v.sys.comcast.net with ESMTP id veg1eEZiBNM3xveg1eBdPx; Tue, 13 Mar 2018 07:48:53 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=comcast.net; s=q20161114; t=1520927333; bh=06EIPsz7inZlDri1zFm/PHZa5Yjp3XAPztXWqcXoxsU=; h=Received:Received:To:From:Reply-to:Subject:Date:Message-ID: Mime-Version:Content-Type; b=Vo8KYO3UI606Ei9cet7K4EVMWzA3D71H7H5wodQ/lHwAcnPFXgvNw9H5JJ7Rcm/n0 ZQBRhB8/VnYUt6mtGNeIuRlhWsjM76Blmn4eNWvVdZedKmgTbVU3HPzqvQTFCfLjwf CTFnQbwSmrnGJkLQuw9QAWK+JowpHcCM2Oh+OLY32HN3cX2rum7tjXsDujk020EHH4 sPsCZeZs/AgVn/o/Hggzzw4vihLmuvbvxCRcOah8XT152f8wqNwBtXsaWZ/FTaeRys Zc6H6Xc7gHqz+vmypWCq7ZXwQ6ft7Gvg5pnhwFM5UphwFgmLHsNqvqIy2vMjJtOwIG irpYVT2uxBZIA== Received: from unknown ([IPv6:2601:408:c300:8f09:21e:4fff:fec2:a0f1]) by resomta-ch2-10v.sys.comcast.net with SMTP id veg0enzFLk1Njveg1erDEz; Tue, 13 Mar 2018 07:48:53 +0000 To: Edbrowse-dev@lists.the-brannons.com From: Karl Dahlke Reply-to: Karl Dahlke User-Agent: edbrowse/3.7.2 Date: Tue, 13 Mar 2018 03:48:52 -0400 Message-ID: <20180213034852.eklhad@comcast.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=nextpart-eb-746764 Content-Transfer-Encoding: 7bit X-CMAE-Envelope: MS4wfJsoc3IrrlPYrXWz9zSwP2ptrRRULZ+HFSSzR3nw4TA6AAwlnc+7imEporl00AjUjtL1Qr7Y1yIU8o5SGj86jsZLxT5x6NpVckYP56fRqbChijqoFfM6 tysERRPOv4xLerF4AUFSdz39YqyLqT+xSw0iCUN9G5Uh/rePQKEBlGhv Subject: [Edbrowse-dev] DOMContentLoaded X-BeenThere: edbrowse-dev@lists.the-brannons.com X-Mailman-Version: 2.1.25 Precedence: list List-Id: Edbrowse Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Mar 2018 07:47:15 -0000 This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. --nextpart-eb-746764 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable tsp asked a relatively innocent question, which led to an interesting = result. Why can't we get to http://www.royalroadl.com It gives http error 503, temporarily out of service. That makes you = think their server is down, so you walk away and try later. But you = always get this misleading error, always. The page has some skeleton html and a couple dozen lines of javascript. The skeleton is a form that says they are checking our browser, and could I wait a few seconds. I waited, plenty long enough, and then pushed submit, and got the same = page with the same 503 error and the same form back again. Time to read through the somewhat cryptic javascript. The function basically attaches another function to document under the = event DOMContentLoaded, and that's it. It never dispatches that event, which means we're suppose to, and we = don't. I read about DOMContentLoaded on the internet. Is it suppose to come before or after onload? Not clear. Is it suppose to run like a function, as we do with onload, or through = the dispatchEvent system? Not clear. I did it the easiest way possible, called document.onDOMContentLoaded() = at the end of runOnload() in html.c. And what would this function do if it were run? It does all sorts of weird computations in javascript, and updates a = hidden input field with the answer, then it submits the form. When I submitted the form manually it didn't cut any ice, because js = had not put the correct answer in the hidden field. I had to run js, and update the field, and submit the form. This went to another page on the website wich verified the answer. Apparently it was correct, because http 302 redirected me back to the = home page, yes, the very same home page, and this time it let me in. Code 200. How did the home page know I had passed the test? I didn't see any cookies fly by. Did it record my IP address as ok? That's rather crude; a thousand computers on an intranet can be behind = one ip address as the gateway. I don't know how it works on the server side, which frustrates me a = little. I do know that one line of code made the difference between being = locked out and getting in. (Latest push). 1. Whoever said more and more sites will need js just to browse, was = correct. 2. Whoever said events were critical to the success of edbrowse and = javascript, was correct. This is going to be a js intensive website, almost as bad as nasa. I got you in, but not clear how many functions will work inside. I'm sure we'll discover more things that we are missing, or not = implementing correctly. Karl Dahlke --nextpart-eb-746764--