SGAFuzzer: Stateful GraphQL API Fuzzing | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article SGAFuzzer: Stateful GraphQL API Fuzzing Jingge Sun, Xiangpu Song, Xiaofeng Liu, Shanqing Guo, Chengyu Hu This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-8078365/v1 This work is licensed under a CC BY 4.0 License Status: Under Review Version 1 posted 10 You are reading this latest preprint version Abstract GraphQL has become increasingly popular in modern web development due to its flexibility and efficiency in data retrieval. However, existing fuzzing techniques for GraphQL APIs face challenges in handling dependencies between operations, which limits their ability to generate effective test cases and detect deep software bugs. This paper proposes SGAFuzzer, an automated stateful fuzzing framework designed to enhance the testing of GraphQL APIs. Specifically, SGAFuzzer performs static analysis of GraphQL schemas, using dependency object mapping and return path analysis to infer producer-consumer dependencies between operations. Subsequently, SGAFuzzer generates request templates based on the schema and employs a state-aware instantiation method, leveraging dependency storage and state caching to generate stateful test cases. We evaluated SGAFuzzer on five real-world GraphQL services. Experimental results demonstrate that SGAFuzzer outperforms state-of-the-art fuzzers in both operation coverage and bug detection count, successfully identifying 227 new bugs. These findings highlight {SGAFuzzer’s} effectiveness in deep stateful fuzzing of GraphQL APIs, leading to the discovery of complex state-dependent bugs. GraphQL API Stateful Fuzzing Dependency Bug Detection SGAFuzzer Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Under Review Version 1 posted Editorial decision: Revision requested 30 Jan, 2026 Reviews received at journal 29 Jan, 2026 Reviews received at journal 02 Jan, 2026 Reviewers agreed at journal 29 Dec, 2025 Reviewers agreed at journal 22 Dec, 2025 Reviewers agreed at journal 03 Dec, 2025 Reviewers invited by journal 03 Dec, 2025 Editor assigned by journal 12 Nov, 2025 Submission checks completed at journal 12 Nov, 2025 First submitted to journal 10 Nov, 2025 You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-8078365","acceptedTermsAndConditions":true,"allowDirectSubmit":false,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":554814070,"identity":"e74aa37f-8651-451a-93e3-ad41f3787db3","order_by":0,"name":"Jingge Sun","email":"","orcid":"","institution":"Shandong University","correspondingAuthor":false,"prefix":"","firstName":"Jingge","middleName":"","lastName":"Sun","suffix":""},{"id":554814071,"identity":"4bd1e08f-3cfb-4cb8-9e26-4ce9ed7d074a","order_by":1,"name":"Xiangpu Song","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAABGUlEQVRIiWNgGAWjYNACAzDJ+ICBQUIGymUmSgszkJLgIVILBLBJAAnCWuTbew+/5imwy5OP7jGrulFjwcPAf3ibBEOFdWID+9kDWJ105lya5QyD5GLDO2fMbuccAzpMIq1MguFMemIDT14CVi0SOWYGHwyYEzfOyAFqYQNp4TGTYGw7nNggwWOA1WFAlQYJBvVgLcU5/4Ba+M8AtfzDrYXhRo7xgw8GhxPnA61jzm0DhVgOUEsDbi0GZ86YMc4wOJ64QeZYsXRunwQPm0RasUXCsXTjNp4c7A5r7zH+zPOnOnH+7OaNn3O+1cnx8x/eeONDjbVsP/sZ7A6DRgeDwQ0YF0QkwBjYAfMHSDjgVjEKRsEoGAUjHAAAKPZXAwq3FpkAAAAASUVORK5CYII=","orcid":"","institution":"Shandong University","correspondingAuthor":true,"prefix":"","firstName":"Xiangpu","middleName":"","lastName":"Song","suffix":""},{"id":554814073,"identity":"647b4f4c-ea80-4d8a-888b-92c6a14febf4","order_by":2,"name":"Xiaofeng Liu","email":"","orcid":"","institution":"Shandong University","correspondingAuthor":false,"prefix":"","firstName":"Xiaofeng","middleName":"","lastName":"Liu","suffix":""},{"id":554814074,"identity":"07e8e064-ea19-43e6-9ebc-d337a70305c0","order_by":3,"name":"Shanqing Guo","email":"","orcid":"","institution":"Shandong University","correspondingAuthor":false,"prefix":"","firstName":"Shanqing","middleName":"","lastName":"Guo","suffix":""},{"id":554814075,"identity":"32eaf679-b370-4b26-9b24-64722495266e","order_by":4,"name":"Chengyu Hu","email":"","orcid":"","institution":"Shandong University","correspondingAuthor":false,"prefix":"","firstName":"Chengyu","middleName":"","lastName":"Hu","suffix":""}],"badges":[],"createdAt":"2025-11-10 14:53:24","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-8078365/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-8078365/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":97495901,"identity":"51a7cd6f-0f8f-4394-a87c-5a3f33f51bf9","added_by":"auto","created_at":"2025-12-05 04:35:27","extension":"json","order_by":0,"title":"","display":"","copyAsset":false,"role":"acdc-reference","size":6168,"visible":true,"origin":"","legend":"","description":"","filename":"ccdfa7fa7b4c4c4e8cf9bb94a1015253.json","url":"https://assets-eu.researchsquare.com/files/rs-8078365/v1/f6c856b2d6081a95c243f868.json"},{"id":97670903,"identity":"a89afe01-3ba2-472f-8d62-9477150df1f3","added_by":"auto","created_at":"2025-12-08 09:31:30","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":512436,"visible":true,"origin":"","legend":"","description":"","filename":"SGAFuzzerStatefulGraphQLAPIFuzzing.pdf","url":"https://assets-eu.researchsquare.com/files/rs-8078365/v1_covered_7a7b6416-4538-4891-b46e-f032c0db895e.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"SGAFuzzer: Stateful GraphQL API Fuzzing","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":false,"hideJournal":false,"highlight":"","institution":"","isAcceptedByJournal":true,"isAuthorSuppliedPdf":true,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"
[email protected]","identity":"software-quality-journal","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":false,"externalIdentity":"sqjo","sideBox":"Learn more about [Software Quality Journal](http://link.springer.com/journal/11219)","snPcode":"11219","submissionUrl":"https://submission.nature.com/new-submission/11219/3","title":"Software Quality Journal","twitterHandle":"","acdcEnabled":true,"dfaEnabled":true,"editorialSystem":"em","reportingPortfolio":"Springer Hybrid","inReviewEnabled":true,"inReviewRevisionsEnabled":false},"keywords":"GraphQL API, Stateful Fuzzing, Dependency, Bug Detection, SGAFuzzer","lastPublishedDoi":"10.21203/rs.3.rs-8078365/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-8078365/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"GraphQL has become increasingly popular in modern web development due to its flexibility and efficiency in data retrieval. However, existing fuzzing techniques for GraphQL APIs face challenges in handling dependencies between operations, which limits their ability to generate effective test cases and detect deep software bugs. This paper proposes SGAFuzzer, an automated stateful fuzzing framework designed to enhance the testing of GraphQL APIs. Specifically, SGAFuzzer performs static analysis of GraphQL schemas, using dependency object mapping and return path analysis to infer producer-consumer dependencies between operations. Subsequently, SGAFuzzer generates request templates based on the schema and employs a state-aware instantiation method, leveraging dependency storage and state caching to generate stateful test cases. We evaluated SGAFuzzer on five real-world GraphQL services. Experimental results demonstrate that SGAFuzzer outperforms state-of-the-art fuzzers in both operation coverage and bug detection count, successfully identifying 227 new bugs. These findings highlight {SGAFuzzer’s} effectiveness in deep stateful fuzzing of GraphQL APIs, leading to the discovery of complex state-dependent bugs.","manuscriptTitle":"SGAFuzzer: Stateful GraphQL API Fuzzing","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2025-12-05 04:35:22","doi":"10.21203/rs.3.rs-8078365/v1","editorialEvents":[{"type":"communityComments","content":0},{"type":"decision","content":"Revision requested","date":"2026-01-30T08:39:06+00:00","index":"","fulltext":""},{"type":"editorInvitedReview","content":"","date":"2026-01-29T20:24:28+00:00","index":"hide","fulltext":""},{"type":"editorInvitedReview","content":"","date":"2026-01-02T21:53:49+00:00","index":"hide","fulltext":""},{"type":"reviewerAgreed","content":"19079944418309938074083508691654211046","date":"2025-12-29T21:47:55+00:00","index":"hide","fulltext":""},{"type":"reviewerAgreed","content":"311727444306463422156084783724062088834","date":"2025-12-22T13:10:05+00:00","index":"hide","fulltext":""},{"type":"reviewerAgreed","content":"214220724895519106320168123847020589368","date":"2025-12-03T16:50:07+00:00","index":"hide","fulltext":""},{"type":"reviewersInvited","content":"","date":"2025-12-03T09:57:23+00:00","index":"","fulltext":""},{"type":"editorAssigned","content":"","date":"2025-11-13T01:39:53+00:00","index":"","fulltext":""},{"type":"checksComplete","content":"","date":"2025-11-13T01:38:54+00:00","index":"","fulltext":""},{"type":"submitted","content":"Software Quality Journal","date":"2025-11-10T14:47:27+00:00","index":"","fulltext":""}],"status":"published","journal":{"display":true,"email":"
[email protected]","identity":"software-quality-journal","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":false,"externalIdentity":"sqjo","sideBox":"Learn more about [Software Quality Journal](http://link.springer.com/journal/11219)","snPcode":"11219","submissionUrl":"https://submission.nature.com/new-submission/11219/3","title":"Software Quality Journal","twitterHandle":"","acdcEnabled":true,"dfaEnabled":true,"editorialSystem":"em","reportingPortfolio":"Springer Hybrid","inReviewEnabled":true,"inReviewRevisionsEnabled":false}}],"origin":"","ownerIdentity":"e99d219b-0494-4853-ae6e-e8417ab50cac","owner":[],"postedDate":"December 5th, 2025","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"under-review","subjectAreas":[],"tags":[],"updatedAt":"2026-05-18T06:40:51+00:00","versionOfRecord":[],"versionCreatedAt":"2025-12-05 04:35:22","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-8078365","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-8078365","identity":"rs-8078365","version":["v1"]},"buildId":"8U1c8b4HqxoKbykW_rLl7","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}
Text is read by the "Ask this paper" AI Q&A widget below.
Extraction quality varies by source — PMC NXML preserves structure
cleanly, OA-HTML may include some navigation residue, and OA-PDF can
have broken hyphenation. The publisher copy
(via DOI)
is the canonical version.