When I set up an auth adapter, to prevent sql injection, do I need to filter or process the user input before giving it to the setIdentity and setCredential methods?
This is my code. I use the unprocessed post data from $request->getPost('username')
and feed it right into setIdentity() and setCredential(). Is this insecure? I've seen most blogging examples do this without doing anything else, but that could be bad practice. Do setIdentity() and setCredential() handle the input correctly when adding the data to the query?
$request = $this->getRequest();
$adapter->setIdentity($request->getPost('username'))
$adapter->setCredential($request->getPost('password'));