🇰🇷 한글 설명
Strawberry GraphQL 라이브러리의 MaxAliasesLimiter 확장 기능에서 FragmentSpreadNode의 증폭 효과를 제대로 계산하지 못하는 취약점이 발견되었습니다. 공격자는 이를 이용해 설정된 별칭(Alias) 제한을 우회하고 서버에 과도한 리소스를 소모하게 하여 서비스 거부(DoS) 공격을 수행할 수 있습니다.
💡 쉬운 설명
GraphQL API를 만들 때 사용하는 도구에서 중복 계산 오류가 발생하여, 정해진 규칙보다 훨씬 많은 양의 데이터를 한꺼번에 요청할 수 있는 문제입니다. 이로 인해 서버에 과부하가 걸려 서비스가 멈출 수 있습니다.
🇺🇸 원문 (English)
Strawberry GraphQL is a library for creating GraphQL APIs. In versions 0.172.0 through0.315.6, the MaxAliasesLimiter extension in Strawberry fails to account for the multiplicative/amplification effect of FragmentSpreadNode. While it correctly counts static aliases within the AST it does not consider how many times a fragments internal aliases are expanded during execution. this allows an attacker to bypass alias limits and force the server to resolve and render a significantly higher number of aliases than allowed, potentially leading to a dos via resource exhaustion. Version 0.315.7 contains a fix for the issue.
📍 영향받는 시스템
Strawberry GraphQL versions 0.172.0 through 0.315.6
⚔️ 공격 벡터
FragmentSpreadNode를 활용하여 별칭(Alias)의 수를 기하급수적으로 늘리는 특수하게 조작된 GraphQL 쿼리 전송
🛡️ 대응 방법
Strawberry GraphQL을 버전 0.315.7 이상으로 업데이트하십시오.
🔧 검증 코드
출력된 버전이 0.315.7 미만(0.172.0 ~ 0.315.6 사이)이면 취약한 상태입니다.
pip show strawberry-graphql | grep Version