Skip to content

Navigation Menu

Sign in
Sign up

Proper way to address directive overloading vulnerability #2620

Unanswered
matthewsuan asked this question in Q&A
Discussion options

Hi, I just wanted to know what's the proper way to address directive overloading vulnerabilities for lighthouse graphql servers. It seems the Query complexity limit and query depth limit is not sufficient to address this issue.

Ty

You must be logged in to vote

Replies: 2 comments 1 reply

Comment options

Can you explain this a bit more?

It seems the Query complexity limit and query depth limit is not sufficient to address this issue.

Why is complexity and query depth limiting not sufficient?

You must be logged in to vote
0 replies
Comment options

Directive overloading does not count against the query complexity no matter how low you set the limit. I tried putting the query complexity limit to 10 and tried directive overloading with 500 directives and its not triggering the query complexity limit error.

image
You must be logged in to vote
1 reply
Comment options

That is expected, because that is not what query complexity analysis does. Given you set reasonable limits on the maximum request body size and limit the amount of memory and execution time per PHP request, I don't see how this can be considered a vulnerability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /