Skip to content

Commit 6f2f0d1

Browse files
authored
Tagging 0.3.1 (#360)
Signed-off-by: Mihai Criveti <[email protected]>
1 parent 67c5717 commit 6f2f0d1

File tree

9 files changed

+243
-28
lines changed

9 files changed

+243
-28
lines changed

.bumpversion.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[bumpversion]
2-
current_version = 0.3.0
2+
current_version = 0.3.1
33
commit = False
44
tag = False
55
sign-tags = True

CHANGELOG.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,59 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
66

77
---
88

9+
## [0.3.1] - 2025-01-11 - Security and Data Validation (Pydantic, UI)
10+
11+
### Security Improvements
12+
13+
> This release adds enhanced validation rules in the Pydantic data models to help prevent XSS injection when data from untrusted MCP servers is displayed in downstream UIs. You should still ensure any downstream agents and applications perform data sanitization coming from untrusted MCP servers (apply defense in depth).
14+
15+
> Data validation has been strengthened across all API endpoints (/admin and main), with additional input and output validation in the UI to improve overall security.
16+
17+
> The Admin UI continues to follow security best practices with localhost-only access by default and feature flag controls - now set to disabled by default, as shown in `.env.example` file (`MCPGATEWAY_UI_ENABLED=false` and `MCPGATEWAY_ADMIN_API_ENABLED=false`).
18+
19+
* **Comprehensive Input Validation Framework** (#339, #340):
20+
* Enhanced data validation for all `/admin` endpoints - tools, resources, prompts, gateways, and servers
21+
* Extended validation framework to all non-admin API endpoints for consistent data integrity
22+
* Implemented configurable validation rules with sensible defaults:
23+
- Character restrictions: names `^[a-zA-Z0-9_\-\s]+$`, tool names `^[a-zA-Z][a-zA-Z0-9_]*$`
24+
- URL scheme validation for approved protocols (`http://`, `https://`, `ws://`, `wss://`)
25+
- JSON nesting depth limits (default: 10 levels) to prevent resource exhaustion
26+
- Field-specific length limits (names: 255, descriptions: 4KB, content: 1MB)
27+
- MIME type validation for resources
28+
* Clear, helpful error messages guide users to correct input formats
29+
30+
* **Enhanced Output Handling in Admin UI** (#336):
31+
* Improved data display safety - all user-controlled content now properly HTML-escaped
32+
* Protected fields include prompt templates, tool names/annotations, resource content, gateway configs
33+
* Ensures user data displays as intended without unexpected behavior
34+
35+
### Added
36+
37+
* **Test MCP Server Connectivity Tool** (#181) - new debugging feature in Admin UI to validate gateway connections
38+
* **Persistent Admin UI Filter State** (#177) - filters and view preferences now persist across page refreshes
39+
* **Revamped UI Components** - metrics and version tabs rewritten from scratch for consistency with overall UI layout
40+
41+
### Changed
42+
43+
* **Code Quality - Zero Lint Status** (#338):
44+
* Resolved all 312 code quality issues across the web stack
45+
* Updated 14 JavaScript patterns to follow best practices
46+
* Corrected 2 HTML structure improvements
47+
* Standardized JavaScript naming conventions
48+
* Removed unused code for cleaner maintenance
49+
50+
* **Validation Configuration** - new environment variables for customization. Update your `.env`:
51+
```bash
52+
VALIDATION_MAX_NAME_LENGTH=255
53+
VALIDATION_MAX_DESCRIPTION_LENGTH=4096
54+
VALIDATION_MAX_JSON_DEPTH=10
55+
VALIDATION_ALLOWED_URL_SCHEMES=["http://", "https://", "ws://", "wss://"]
56+
```
57+
58+
* **Performance** - validation overhead kept under 10ms per request with efficient patterns
59+
60+
---
61+
962
## [0.3.0] - 2025-07-08
1063

1164
### Added

Containerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
FROM registry.access.redhat.com/ubi9-minimal:9.6-1751286687
22
LABEL maintainer="Mihai Criveti" \
33
name="mcp/mcpgateway" \
4-
version="0.3.0" \
4+
version="0.3.1" \
55
description="MCP Gateway: An enterprise-ready Model Context Protocol Gateway"
66

77
ARG PYTHON_VERSION=3.11

Containerfile.lite

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ LABEL maintainer="Mihai Criveti" \
106106
org.opencontainers.image.title="mcp/mcpgateway" \
107107
org.opencontainers.image.description="MCP Gateway: An enterprise-ready Model Context Protocol Gateway" \
108108
org.opencontainers.image.licenses="Apache-2.0" \
109-
org.opencontainers.image.version="0.3.0"
109+
org.opencontainers.image.version="0.3.1"
110110

111111
# ----------------------------------------------------------------------------
112112
# Copy the entire prepared root filesystem from the builder stage

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -344,13 +344,13 @@ docker run -d --name mcpgateway \
344344
-e BASIC_AUTH_PASSWORD=changeme \
345345
-e AUTH_REQUIRED=true \
346346
-e DATABASE_URL=sqlite:///./mcp.db \
347-
ghcr.io/ibm/mcp-context-forge:0.3.0
347+
ghcr.io/ibm/mcp-context-forge:0.3.1
348348

349349
# Tail logs (Ctrl+C to quit)
350350
docker logs -f mcpgateway
351351

352352
# Generating an API key
353-
docker run --rm -it ghcr.io/ibm/mcp-context-forge:0.3.0 \
353+
docker run --rm -it ghcr.io/ibm/mcp-context-forge:0.3.1 \
354354
python -m mcpgateway.utils.create_jwt_token --username admin --exp 0 --secret my-test-key
355355
```
356356

@@ -376,7 +376,7 @@ docker run -d --name mcpgateway \
376376
-e JWT_SECRET_KEY=my-test-key \
377377
-e BASIC_AUTH_USER=admin \
378378
-e BASIC_AUTH_PASSWORD=changeme \
379-
ghcr.io/ibm/mcp-context-forge:0.3.0
379+
ghcr.io/ibm/mcp-context-forge:0.3.1
380380
```
381381

382382
SQLite now lives on the host at `./data/mcp.db`.
@@ -398,7 +398,7 @@ docker run -d --name mcpgateway \
398398
-e PORT=4444 \
399399
-e DATABASE_URL=sqlite:////data/mcp.db \
400400
-v $(pwd)/data:/data \
401-
ghcr.io/ibm/mcp-context-forge:0.3.0
401+
ghcr.io/ibm/mcp-context-forge:0.3.1
402402
```
403403

404404
Using `--network=host` allows Docker to access the local network, allowing you to add MCP servers running on your host. See [Docker Host network driver documentation](https://docs.docker.com/engine/network/drivers/host/) for more details.
@@ -414,7 +414,7 @@ podman run -d --name mcpgateway \
414414
-p 4444:4444 \
415415
-e HOST=0.0.0.0 \
416416
-e DATABASE_URL=sqlite:///./mcp.db \
417-
ghcr.io/ibm/mcp-context-forge:0.3.0
417+
ghcr.io/ibm/mcp-context-forge:0.3.1
418418
```
419419

420420
#### 2 - Persist SQLite
@@ -433,7 +433,7 @@ podman run -d --name mcpgateway \
433433
-p 4444:4444 \
434434
-v $(pwd)/data:/data \
435435
-e DATABASE_URL=sqlite:////data/mcp.db \
436-
ghcr.io/ibm/mcp-context-forge:0.3.0
436+
ghcr.io/ibm/mcp-context-forge:0.3.1
437437
```
438438

439439
#### 3 - Host networking (rootless)
@@ -451,7 +451,7 @@ podman run -d --name mcpgateway \
451451
--network=host \
452452
-v $(pwd)/data:/data \
453453
-e DATABASE_URL=sqlite:////data/mcp.db \
454-
ghcr.io/ibm/mcp-context-forge:0.3.0
454+
ghcr.io/ibm/mcp-context-forge:0.3.1
455455
```
456456

457457
---
@@ -460,7 +460,7 @@ podman run -d --name mcpgateway \
460460
<summary><strong>✏️ Docker/Podman tips</strong></summary>
461461

462462
* **.env files** - Put all the `-e FOO=` lines into a file and replace them with `--env-file .env`. See the provided [.env.example](.env.example) for reference.
463-
* **Pinned tags** - Use an explicit version (e.g. `v0.3.0`) instead of `latest` for reproducible builds.
463+
* **Pinned tags** - Use an explicit version (e.g. `v0.3.1`) instead of `latest` for reproducible builds.
464464
* **JWT tokens** - Generate one in the running container:
465465

466466
```bash
@@ -506,7 +506,7 @@ docker run --rm -i \
506506
-e MCP_SERVER_CATALOG_URLS=http://host.docker.internal:4444/servers/UUID_OF_SERVER_1 \
507507
-e MCP_TOOL_CALL_TIMEOUT=120 \
508508
-e MCP_WRAPPER_LOG_LEVEL=DEBUG \
509-
ghcr.io/ibm/mcp-context-forge:0.3.0 \
509+
ghcr.io/ibm/mcp-context-forge:0.3.1 \
510510
python3 -m mcpgateway.wrapper
511511
```
512512

@@ -586,7 +586,7 @@ docker run -i --rm \
586586
-e MCP_SERVER_CATALOG_URLS=http://localhost:4444/servers/UUID_OF_SERVER_1 \
587587
-e MCP_AUTH_TOKEN=${MCPGATEWAY_BEARER_TOKEN} \
588588
-e MCP_TOOL_CALL_TIMEOUT=120 \
589-
ghcr.io/ibm/mcp-context-forge:0.3.0 \
589+
ghcr.io/ibm/mcp-context-forge:0.3.1 \
590590
python3 -m mcpgateway.wrapper
591591
```
592592

0 commit comments

Comments
 (0)