langprotect-mcp-gateway 1.2.3__tar.gz → 1.2.4__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/PKG-INFO +1 -1
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway/setup_helper.py +48 -3
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/PKG-INFO +1 -1
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/pyproject.toml +1 -1
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/LICENSE +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/README.md +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway/__init__.py +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway/gateway.py +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/SOURCES.txt +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/dependency_links.txt +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/entry_points.txt +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/requires.txt +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway.egg-info/top_level.txt +0 -0
- {langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/setup.cfg +0 -0
|
@@ -86,6 +86,45 @@ def update_vscode_settings(wrapper_path):
|
|
|
86
86
|
return settings_path
|
|
87
87
|
|
|
88
88
|
|
|
89
|
+
def get_claude_config_path():
|
|
90
|
+
"""Get the Claude Desktop config path based on OS"""
|
|
91
|
+
home = Path.home()
|
|
92
|
+
if sys.platform == "darwin":
|
|
93
|
+
return home / "Library/Application Support/Claude/claude_desktop_config.json"
|
|
94
|
+
elif sys.platform == "win32":
|
|
95
|
+
return home / "AppData/Roaming/Claude/claude_desktop_config.json"
|
|
96
|
+
else:
|
|
97
|
+
return home / ".config/Claude/claude_desktop_config.json"
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
def update_claude_config(wrapper_path):
|
|
101
|
+
"""Update Claude Desktop config to use the wrapper"""
|
|
102
|
+
config_path = get_claude_config_path()
|
|
103
|
+
config_path.parent.mkdir(parents=True, exist_ok=True)
|
|
104
|
+
|
|
105
|
+
if config_path.exists():
|
|
106
|
+
with open(config_path, 'r') as f:
|
|
107
|
+
try:
|
|
108
|
+
config = json.load(f)
|
|
109
|
+
except json.JSONDecodeError:
|
|
110
|
+
config = {}
|
|
111
|
+
else:
|
|
112
|
+
config = {}
|
|
113
|
+
|
|
114
|
+
if "mcpServers" not in config:
|
|
115
|
+
config["mcpServers"] = {}
|
|
116
|
+
|
|
117
|
+
config["mcpServers"]["langprotect-gateway"] = {
|
|
118
|
+
"command": str(wrapper_path),
|
|
119
|
+
"args": []
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
with open(config_path, 'w') as f:
|
|
123
|
+
json.dump(config, f, indent=2)
|
|
124
|
+
|
|
125
|
+
return config_path
|
|
126
|
+
|
|
127
|
+
|
|
89
128
|
def setup():
|
|
90
129
|
"""Main setup function"""
|
|
91
130
|
print("🚀 Setting up LangProtect MCP Gateway...")
|
|
@@ -102,11 +141,17 @@ def setup():
|
|
|
102
141
|
try:
|
|
103
142
|
settings_path = update_vscode_settings(wrapper_path)
|
|
104
143
|
print(f" ✅ Updated: {settings_path}")
|
|
105
|
-
print()
|
|
106
144
|
except Exception as e:
|
|
107
145
|
print(f" ⚠️ Could not update VS Code settings: {e}")
|
|
108
|
-
|
|
109
|
-
|
|
146
|
+
|
|
147
|
+
# Update Claude Desktop config
|
|
148
|
+
print("🍏 Configuring Claude Desktop (for high compatibility)...")
|
|
149
|
+
try:
|
|
150
|
+
claude_path = update_claude_config(wrapper_path)
|
|
151
|
+
print(f" ✅ Updated: {claude_path}")
|
|
152
|
+
except Exception as e:
|
|
153
|
+
print(f" ⚠️ Could not update Claude Desktop config: {e}")
|
|
154
|
+
print()
|
|
110
155
|
|
|
111
156
|
# Print next steps
|
|
112
157
|
print("✅ Setup complete!")
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "langprotect-mcp-gateway"
|
|
7
|
-
version = "1.2.
|
|
7
|
+
version = "1.2.4"
|
|
8
8
|
description = "Security gateway for Model Context Protocol (MCP) to protect AI tool interactions"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.8"
|
|
File without changes
|
|
File without changes
|
{langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway/__init__.py
RENAMED
|
File without changes
|
{langprotect_mcp_gateway-1.2.3 → langprotect_mcp_gateway-1.2.4}/langprotect_mcp_gateway/gateway.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|