Skip to content

Commit

Permalink
Wrap SpEL documentation with admonition.
Browse files Browse the repository at this point in the history
Closes #4085
  • Loading branch information
mp911de committed Jun 14, 2022
1 parent ebc4678 commit 864c94f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/asciidoc/reference/mongo-repositories.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -501,9 +501,9 @@ public interface PersonRepository extends MongoRepository<Person, String> {
}
----

SpEL in query strings can be a powerful way to enhance queries.
WARNING: SpEL in query strings can be a powerful way to enhance queries.
However, they can also accept a broad range of unwanted arguments.
You should make sure to sanitize strings before passing them to the query to avoid unwanted changes to your query.
Make sure to sanitize strings before passing them to the query to avoid creation of vulnerabilities or unwanted changes to your query.

Expression support is extensible through the Query SPI: `org.springframework.data.repository.query.spi.EvaluationContextExtension`.
The Query SPI can contribute properties and functions and can customize the root object.
Expand Down

0 comments on commit 864c94f

Please sign in to comment.