I've discovered ClientForm
... a Python module for handling HTML forms on the client side, useful for parsing HTML forms, filling them in and returning the completed forms to the server.that is very good news for me, since I have to automate several tasks working with devices that provide only an interactive web interface. Activities like logging in, updating code, resetting the device, etc, that require more complicated mechanisms like cookies, hidden fields, and random nonces, prohibit the use of statically configured form submissions.
I had started off sniffing and dissecting web pages to manually discover the required information to submit dynamic forms. This activity can take me a whole day for just a simple user interface login. ClientForms, by doing all the hard work of parsing the form, has enabled me to cut this down to 15 minutes. I guess the only difficulty remaining is with forms being manipulated by Javascript during submission. I am still learning more about ClientForms but there is much more in the Python community (and for that, Perl) that can be harnessed to make life for programmers more productive.
I shall leave you here. In a subsequent post, I shall share some of the other tools that I have found, and also some history of my programming experience.
No comments:
Post a Comment