You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Does this allows arbitrary queries even if a RequestProcessor is enabled?
If so, this may be OK for performance reasons, but could be a surprise to anyone that configures it for security reasons after they read this in the documentation:
it allows you to whitelist only specific query IDs, and block all other ad-hoc, potentially malicious queries, which adds an extra layer of security to your API, particularly if it's public.
Perhaps the documentation could spell out that additional steps are needed to enable query whitelisting, or the code could be rewritten so that it is easier to configure whitelisting.
The first part of getRequestQueryVariables could be refactored into a new implementation of RequestProcessor, for example:
Does this allows arbitrary queries even if a RequestProcessor is enabled?
If so, this may be OK for performance reasons, but could be a surprise to anyone that configures it for security reasons after they read this in the documentation:
Perhaps the documentation could spell out that additional steps are needed to enable query whitelisting, or the code could be rewritten so that it is easier to configure whitelisting.
The first part of
getRequestQueryVariables
could be refactored into a new implementation ofRequestProcessor
, for example:Make this the default implementation of
RequestProcessor
, then simplifygetRequestQueryVariables
:Then, to enable query whitelisting, developers will have to inject
RequestIDProcessor
in place ofRequestBodyRequestProcessor
The text was updated successfully, but these errors were encountered: