-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sql injection? #3
Comments
All strings (or other types) are escaped before being sent to the database, so there is no risk of sql injection. Documentation should probably cover this. |
I thought more about this. Custom queries are still dangerous though, right?
so I noticed the session.db.query function doesn't allow you to supply params:
I expected that it would take a list of params and simply pass them onto the database so the database can avoid 'executing' the params like it does the sql query. We're using serverpod with a pretty intricate database schema, so we use custom queries a lot in order to make efficient queries rather than hitting the database constantly. |
You are right, we should provide the option to provide parameters for this reason. |
Parameters are now available for custom queries :) |
I wasn't able to find, in the docs, anything about sql injection or if it's guarded against or handled by serverpod.
The text was updated successfully, but these errors were encountered: