Programmatic POST Requests with JavaScript: Form Emulator in Action
(Page 1 of 5 )
In the fourth and final part of our series, we examine the form emulator we built in the third part in the context of a practical example that puts the program to work. The form emulator can be used as a simple testing bed to help you build more robust and safer Web applications.
Introduction
This is the last part of the series “Programmatic POST Requests with JavaScript.” Welcome back. Throughout the previous article, I offered a full explanation of how to build a JavaScript-based form emulator program, aimed specifically at sending post requests to a given host, in order to simulate the use of Web forms for submitting potentially dangerous information.
Indeed, this http-based hacking method has become extremely popular due mainly to the extensive use of JavaScript to make asynchronous http requests without page reloads. Certainly, it’s rather pointless to judge a technical tool itself within an ethical sense, either as evil or good-intended, since the responsibility for its usage relies completely on the user’s purposes.
However, very often in real conditions, it’s useful to consider how hacking techniques may be used to attack websites, and accordingly to improve the overall security, whether within the application and/or at administrative levels. As a result, hopefully safer Web programs will be written and more efficient security strategies will be implemented.
So, returning to the form emulator script, in the previous article I defined all the required functions to make the program fully functional. Therefore, in this last part I’ll set up a practical example that puts the program to work and demonstrates that post Web forms may be easily emulated, either with malicious purposes or for use as a simple testing bed.
Now that the article’s objectives have been defined, it’s time to go forward and start coding the example.
Next: The first step in coding the example: listing the program’s functions >>
More JavaScript Articles
More By Alejandro Gervasio