{"question":"Our assistant uses the AWS Labs Serverless MCP server to deploy and check serverless projects, and on some machines we run it with --allow-write. What is CVE-2026-116635, which version fixes it, and what could someone do with it?","slug":"can-a-project-name-make-the-aws-serverless-mcp-server-read-or-overwrite-files-outside-its-folder-cve-2026-116635","url":"https://www.rightshold.com/answers/can-a-project-name-make-the-aws-serverless-mcp-server-read-or-overwrite-files-outside-its-folder-cve-2026-116635","short_answer":"It could before version 0.2.1. CVE-2026-116635 (GHSA-r6mm-377j-qg8m and AWS security bulletin 2026-164-AWS, both published November 2, 2026, rated moderate) affects awslabs.aws-serverless-mcp-server before 0.2.1. The server keeps deployment status as JSON files in a status folder, and it built each file's path from the project name without confining it, so a name containing ../ segments or an absolute path pointed it at a JSON file anywhere the server's account can reach. Reading returned that file into the assistant's context; with writing enabled, the server could also create or overwrite a JSON file there with deployment metadata. The project name is something the assistant fills in, so text the assistant reads, in a ticket, a README or a web page, could steer it. AWS says 0.2.1 fixes it and there is no workaround. PyPI shows 0.2.1 uploaded October 30, 2026, and 0.2.3 as the newest release on November 27, 2026.","checklist":["Check the installed version: awslabs.aws-serverless-mcp-server before 0.2.1 is affected. PyPI listed 0.2.3, uploaded November 25, 2026, as the newest release on November 27, 2026.","If your client launches the server through uvx with the latest tag, restart it so it resolves a new build; a pinned or cached copy stays where it was.","Know which machines run it with --allow-write, the README's option for mutating tools such as sam_deploy and deploy_webapp. The read path needs nothing extra, but creating or overwriting a JSON file needs write access turned on.","Until every copy is upgraded, keep write access off and don't let the assistant read outside content (issues, web pages, other people's repositories) in the same session as this server.","Read the project name in any approval prompt before a deployment tool runs. A name with ../ or a leading / isn't a project name.","Run the server under an account that can't reach other JSON files that matter: application config, credentials helpers' caches, editor and tool settings in your home directory.","If an affected version ran with write access while the assistant read outside content, look for recently changed JSON files outside the deployment status folder, and restore any that now hold deployment metadata."],"sections":[{"heading":"What CVE-2026-116635 in the AWS Serverless MCP server does","points":["AWS's advisory GHSA-r6mm-377j-qg8m (CVE-2026-116635, moderate, published November 2, 2026) and bulletin 2026-164-AWS describe the deployment status component. Under certain conditions, someone who can influence the MCP agent could make it read JSON files outside the intended deployment status directory and, where write access has been enabled, create or overwrite JSON files outside it. The route is a directory traversal sequence or an absolute path in the project name.","The advisory spells out the effect. If the path ended at a valid JSON file, the assistant could read from that location, and write to it if the server was started with write access. A read puts a JSON file from outside the intended directory into the assistant's context; a write clobbers an existing file, replacing its contents with the serverless deployment's metadata.","Nothing here needs a network attacker. Like the other AWS Labs MCP advisories this autumn, it starts with text the assistant reads that persuades it to pass a crafted value into a tool, and the server then acts with its own account's file access."]},{"heading":"How version 0.2.1 fixes it, and what to upgrade to","points":["AWS's bulletin says the issue is addressed in awslabs.aws-serverless-mcp-server 0.2.1 and that no workarounds are available. It recommends upgrading to the latest version and carrying the fix into any fork or derivative of the code. The server's README now documents project_name for deploy_webapp as letters, digits, hyphens and underscores only, up to 128 characters, which leaves no room for ../ or a leading slash.","PyPI's release history shows 0.2.1 uploaded October 30, 2026, three days before the advisory, then 0.2.2 on November 17 and 0.2.3 on November 25. Anyone who updated in November already has the fix; copies pinned to 0.2.0 or earlier don't.","An upgrade fixes this one path. The habits that limit the next one are the same as for any MCP server that writes files: start it without write access unless the task needs it, and keep it on an account whose files you could lose."]},{"heading":"Why tool arguments that name files need a check of their own","points":["A project name looks like a label, but this server used it to build a file path. Any argument that ends up in a path is a place on disk the model can choose, and a model will pass whatever text in its context persuades it to. That makes the server, not the prompt, the place to confine it.","If you build MCP servers: resolve every path built from an argument against a fixed base directory, reject anything that escapes it after resolving symlinks, and accept project or file names against a strict pattern before they reach the file system. Mark a tool that can create a file with readOnlyHint false.","If you run them: route calls that deploy or write through an approval step that shows the arguments, so a person sees the project name before the call goes ahead."]}],"checks":[],"ask_rightshold":{"start":"https://www.rightshold.com/start?ref=seo","mcp_endpoint":"https://www.rightshold.com/mcp","ask":"Before my assistant runs a deployment tool on the AWS Serverless MCP server, ask me to approve that exact call, with the project name and stage in the request, so a crafted name can't point it at another folder.","mcp_call":{"tool":"request_human_approval","arguments":{"action":{"tool":"deploy_webapp","mcp_server":"awslabs.aws-serverless-mcp-server","server_version":"0.2.3","deployment_type":"backend","project_name":"<project name>","project_root":"/work/<project folder>","region":"us-east-1"},"summary":"Deploy a serverless project through the AWS Serverless MCP server","expires_in_minutes":30}},"also":["Needs your API key. The action is hashed, and you decide once with decide_human_approval (approve or deny); the decision is a signed, timestamped receipt. The token works once.","It doesn't check your server version, resolve file paths or stop a call your client sends straight to the Serverless MCP server. It only covers calls your agent or harness routes through it first, so upgrade as well."],"scope":"Rightshold isn't affiliated with AWS. It doesn't scan MCP server code or client settings, and an approval record isn't a finding that a call is safe. Advisory details are as published by AWS in GitHub's advisory database (GHSA-r6mm-377j-qg8m) and AWS security bulletin 2026-164-AWS, the server's --allow-write option and deploy_webapp parameters as described in its README in the awslabs/mcp repository, and release dates as listed on PyPI, all read November 27, 2026; advisories get updated, so confirm fixed versions on the linked pages."},"sources":[{"title":"GitHub Advisory: GHSA-r6mm-377j-qg8m / CVE-2026-116635, improper limitation of a pathname to a restricted directory in the AWS Serverless MCP Server","url":"https://github.com/awslabs/mcp/security/advisories/GHSA-r6mm-377j-qg8m"},{"title":"AWS Security Bulletin 2026-164-AWS: CVE-2026-116635, AWS Serverless MCP Server deployment status component","url":"https://aws.amazon.com/security/security-bulletins/2026-164-aws/"},{"title":"awslabs/mcp: AWS Serverless MCP server README","url":"https://github.com/awslabs/mcp/tree/main/src/aws-serverless-mcp-server"},{"title":"PyPI: awslabs.aws-serverless-mcp-server release history","url":"https://pypi.org/project/awslabs.aws-serverless-mcp-server/#history"}],"related":[{"title":"Can an MCP tool marked read-only write files? The AWS Pricing MCP server's CVE-2026-126816","url":"https://www.rightshold.com/answers/can-an-mcp-tool-marked-read-only-write-files-aws-pricing-mcp-server-cve-2026-126816"},{"title":"Blocking SSRF and path traversal in MCP tool URL arguments and resource templates","url":"https://www.rightshold.com/answers/how-to-block-ssrf-and-path-traversal-in-mcp-tool-url-arguments-and-resource-templates"},{"title":"Require human confirmation before MCP write tools run","url":"https://www.rightshold.com/answers/how-to-require-human-confirmation-before-mcp-write-tools-run"},{"title":"Sandboxing a local stdio MCP server to only the files and hosts it needs","url":"https://www.rightshold.com/answers/how-to-sandbox-a-local-stdio-mcp-server-to-only-the-files-and-hosts-it-needs"}],"computed_from":"Curated guidance; license verdicts computed from Rightshold's license profiles at render time. Not legal advice.","updated":"2026-11-27"}