Ajax database interaction is extremely powerful and provides a lot of flexibility to web applications. Of course, with great power there are also great security risks. This chapter will explain what security holes are exposed in the application we created, and how to create unique passwords for your XHRs to avoid these security issues. A password alone will not protect your XHR, so we will need to add a verification process on the server side in the serviceConnector.php file from Chapter 20, "Understanding Ajax Database Interaction." This will provide us with the ability to avoid unwanted requests, if they should occur, before they even reach the PHP classes that connect to the database. This not only keeps unwanted requests out, it also keeps them a layer away from the classes that contain critical information about our database and other proprietary information.