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
+54-7Lines changed: 54 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -137,17 +137,64 @@ The inspector supports bearer token authentication for SSE connections. Enter yo
137
137
138
138
The MCP Inspector includes a proxy server that can run and communicate with local MCP processes. The proxy server should not be exposed to untrusted networks as it has permissions to spawn local processes and can connect to any specified MCP server.
139
139
140
+
#### Authentication
141
+
142
+
The MCP Inspector proxy server requires authentication by default. When starting the server, a random session token is generated and printed to the console:
This token must be included as a Bearer token in the Authorization header for all requests to the server. The inspector will automatically open your browser with the token pre-filled in the URL.
152
+
153
+
**Automatic browser opening** - The inspector now automatically opens your browser with the token pre-filled in the URL when authentication is enabled.
154
+
155
+
**Alternative: Manual configuration** - If you already have the inspector open:
156
+
157
+
1. Click the "Configuration" button in the sidebar
158
+
2. Find "Proxy Session Token" and enter the token displayed in the proxy console
159
+
3. Click "Save" to apply the configuration
160
+
161
+
The token will be saved in your browser's local storage for future use.
162
+
163
+
If you need to disable authentication (NOT RECOMMENDED), you can set the `DANGEROUSLY_OMIT_AUTH` environment variable:
164
+
165
+
```bash
166
+
DANGEROUSLY_OMIT_AUTH=true npm start
167
+
```
168
+
169
+
#### Local-only Binding
170
+
171
+
By default, the MCP Inspector proxy server binds only to `127.0.0.1` (localhost) to prevent network access. This ensures the server is not accessible from other devices on the network. If you need to bind to all interfaces for development purposes, you can override this with the `HOST` environment variable:
172
+
173
+
```bash
174
+
HOST=0.0.0.0 npm start
175
+
```
176
+
177
+
**Warning:** Only bind to all interfaces in trusted network environments, as this exposes the proxy server's ability to execute local processes.
178
+
179
+
#### DNS Rebinding Protection
180
+
181
+
To prevent DNS rebinding attacks, the MCP Inspector validates the `Origin` header on incoming requests. By default, only requests from the client origin are allowed (respects `CLIENT_PORT` if set, defaulting to port 6274). You can configure additional allowed origins by setting the `ALLOWED_ORIGINS` environment variable (comma-separated list):
|`MCP_SERVER_REQUEST_TIMEOUT`| Timeout for requests to the MCP server (ms) | 10000 |
194
+
|`MCP_REQUEST_TIMEOUT_RESET_ON_PROGRESS`| Reset timeout on progress notifications | true |
195
+
|`MCP_REQUEST_MAX_TOTAL_TIMEOUT`| Maximum total timeout for requests sent to the MCP server (ms) (Use with progress notifications) | 60000 |
196
+
|`MCP_PROXY_FULL_ADDRESS`| Set this if you are running the MCP Inspector Proxy on a non-default address. Example: http://10.1.1.22:5577| "" |
197
+
|`MCP_AUTO_OPEN_ENABLED`| Enable automatic browser opening when inspector starts (works with authentication enabled). Only as environment var, not configurable in browser. | true |
151
198
152
199
These settings can be adjusted in real-time through the UI and will persist across sessions.
0 commit comments