Data from all potentially untrusted sources should be subject to input validation, including not only Internet-facing web clients but also backend feeds over extranets, from suppliers, partners, vendors or regulators, each of which may be compromised on their own and start sending malformed data.Input Validation should not be used as the primary method of preventing XSS, SQL Injection and other attacks which are covered in respective cheat sheets but can significantly contribute to reducing their impact if implemented properly.
Input validation should happen as early as possible in the data flow, preferably as soon as the data is received from the external party.
This information is then stored in a SQLite database.
I needed a way to validate the data in the form's widgets before saving that data in the application's database.
In this tutorial we will use Awesome Validation Library to validate input fields in the form.
This Library supports the following validation rules : We will create a simple form with multiple Edit Text widget and Button, you can find the screenshot of the form below.