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
Copy file name to clipboardExpand all lines: README.md
+16-1Lines changed: 16 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -894,7 +894,7 @@ The following sets of tools are available:
894
894
-**add_issue_comment** - Add comment to issue or pull request
895
895
-**Required OAuth Scopes**: `repo`
896
896
-`body`: Comment content. Required unless reaction is provided. (string, optional)
897
-
-`comment_id`: The numeric ID of the issue or pull request comment to react to. Use this for reactions to comments; omit it to react to the issue or pull request itself. Cannot be combined with body. (number, optional)
897
+
-`comment_id`: The numeric ID of the issue or pull request comment to react to. Use this for reactions to comments; omit it to react to the issue or pull request itself. Cannot be combined with body. (integer, optional)
898
898
-`issue_number`: Issue or pull request number to comment on or react to. (number, required)
899
899
-`owner`: Repository owner (string, required)
900
900
-`reaction`: Emoji reaction to add. Required unless body is provided. (string, optional)
@@ -1284,6 +1284,7 @@ The following sets of tools are available:
1284
1284
1285
1285
-**create_or_update_file** - Create or update file
1286
1286
-**Required OAuth Scopes**: `repo`
1287
+
-`allow_symlink_write`: Set true to update a symbolic link itself; content must be its new target path. (boolean, optional)
1287
1288
-`branch`: Branch to create/update the file in (string, required)
1288
1289
-`content`: Content of the file, exactly as it should appear once written. Do not base64-encode it; this server does that before calling the REST API. (string, required)
1289
1290
-`message`: Commit message (string, required)
@@ -1308,6 +1309,11 @@ The following sets of tools are available:
1308
1309
-`path`: Path to the file to delete (string, required)
-`owner`: Repository owner (username or organization) (string, required)
1315
+
-`repo`: Repository name (string, required)
1316
+
1311
1317
-**fork_repository** - Fork repository
1312
1318
-**Required OAuth Scopes**: `repo`
1313
1319
-`organization`: Organization to fork to (string, optional)
@@ -1596,6 +1602,10 @@ docker run -i --rm \
1596
1602
1597
1603
Lockdown mode limits the content that the server will surface from public repositories. When enabled, the server checks whether the author of each item has push access to the repository. Private repositories are unaffected, and collaborators keep full access to their own content.
1598
1604
1605
+
Lockdown mode is a best-effort content filter intended to reduce the risk of prompt injection from untrusted repository content (issues, pull requests, comments, commits, etc.). It is **not** an authorization boundary: it does not change what the underlying GitHub credential can read or write, and content withheld from a filtered tool response may still be reachable through other tools or direct GitHub API access with the same credential.
1606
+
1607
+
As an intentional exception, content authored by a small set of trusted bot accounts (currently `github-actions[bot]` and `copilot`) is always treated as safe, regardless of push access. This avoids filtering routine automation output (e.g. CI-generated commits or comments) that would otherwise be withheld under lockdown mode.
1608
+
1599
1609
```bash
1600
1610
./github-mcp-server --lockdown-mode
1601
1611
```
@@ -1609,12 +1619,17 @@ docker run -i --rm \
1609
1619
ghcr.io/github/github-mcp-server
1610
1620
```
1611
1621
1622
+
In HTTP mode, this flag (or `GITHUB_LOCKDOWN_MODE`) is an upper bound: the `X-MCP-Lockdown` request header can enable lockdown mode when the operator has not, but it cannot disable lockdown mode the operator has already enabled. See the [Server Configuration Guide](docs/server-configuration.md#lockdown-mode) for details.
1623
+
1612
1624
The behavior of lockdown mode depends on the tool invoked.
1613
1625
1614
1626
Following tools will return an error when the author lacks the push access:
1615
1627
1616
1628
-`issue_read:get`
1617
1629
-`pull_request_read:get`
1630
+
-`pull_request_read:get_diff`
1631
+
-`pull_request_read:get_files`
1632
+
-`pull_request_read:get_commits`
1618
1633
1619
1634
Following tools will filter out content from users lacking the push access:
Copy file name to clipboardExpand all lines: docs/remote-server.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -67,9 +67,10 @@ The Remote GitHub MCP server has optional headers equivalent to the Local server
67
67
-`X-MCP-Readonly`: Enables only "read" tools.
68
68
- Equivalent to `GITHUB_READ_ONLY` env var for Local server.
69
69
- If this header is empty, "false", "f", "no", "n", "0", or "off" (ignoring whitespace and case), it will be interpreted as false. All other values are interpreted as true.
70
-
-`X-MCP-Lockdown`: Enables lockdown mode, hiding public issue details created by users without push access.
70
+
-`X-MCP-Lockdown`: Enables lockdown mode, hiding public issue details created by users without push access. Lockdown mode is a best-effort content filter, not a security boundary.
71
71
- Equivalent to `GITHUB_LOCKDOWN_MODE` env var for Local server.
72
72
- If this header is empty, "false", "f", "no", "n", "0", or "off" (ignoring whitespace and case), it will be interpreted as false. All other values are interpreted as true.
73
+
- Server-side lockdown configuration is an upper bound: if the operator has already enabled lockdown mode, this header cannot disable it for a request. The header can only enable (or redundantly re-enable) lockdown mode; it cannot relax lockdown mode below the operator's configuration.
73
74
-`X-MCP-Insiders`: Enables insiders mode for early access to new features.
74
75
- Equivalent to `GITHUB_INSIDERS` env var or `--insiders` flag for Local server.
75
76
- If this header is empty, "false", "f", "no", "n", "0", or "off" (ignoring whitespace and case), it will be interpreted as false. All other values are interpreted as true.
Copy file name to clipboardExpand all lines: docs/server-configuration.md
+8Lines changed: 8 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,6 +29,8 @@ Note: **read-only** mode acts as a strict security filter that takes precedence
29
29
30
30
Note: **excluded tools** takes precedence over toolsets and individual tools — listed tools are always excluded, even if their toolset is enabled or they are explicitly added via `--tools` / `X-MCP-Tools`.
31
31
32
+
Note: server-side **lockdown mode** (`--lockdown-mode` / `GITHUB_LOCKDOWN_MODE`) is an upper bound in HTTP mode — once an operator enables it, the `X-MCP-Lockdown` header can no longer disable it for a given request. A request may still use the header to enable lockdown mode for itself when the operator has not already enabled it server-wide, but it can never relax lockdown mode below what the operator configured. Lockdown mode remains a best-effort content filter, not a security boundary.
33
+
32
34
---
33
35
34
36
## Configuration Examples
@@ -292,6 +294,12 @@ When active, this mode will disable all tools that are not read-only even if the
292
294
293
295
Lockdown mode ensures the server only surfaces content in public repositories from users with push access to that repository. Private repositories are unaffected, and collaborators retain full access to their own content.
294
296
297
+
> In HTTP mode, server-side lockdown mode (`--lockdown-mode` / `GITHUB_LOCKDOWN_MODE`) is an upper bound: the `X-MCP-Lockdown` header can enable lockdown mode for a request when the operator has not enabled it server-wide, but it cannot disable lockdown mode the operator has already enabled.
298
+
299
+
Lockdown mode is a best-effort content filter meant to reduce prompt-injection risk from untrusted repository content; it is not an authorization boundary. It does not restrict what the underlying credential can otherwise read or write, and content withheld from a filtered tool response may still be reachable through other tools or direct GitHub API access with the same credential.
300
+
301
+
As an intentional exception, content authored by trusted bot accounts (currently `github-actions[bot]` and `copilot`) is always treated as safe, regardless of push access, so routine automation output isn't filtered.
When `--scope-challenge` is enabled, requests with insufficient scopes receive a `403 Forbidden` response with a `WWW-Authenticate` header indicating the required scopes.
34
34
35
+
### Repository deletion and request-state encryption
36
+
37
+
The `delete_repository` tool uses multi-round-trip elicitation and carries its
38
+
confirmed target through client-held request state. To expose this tool in HTTP
39
+
mode, configure a stable 32-byte encryption key encoded with standard Base64:
0 commit comments