blockchain-verification-mcp 1.0.0__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.
- blockchain_verification_mcp-1.0.0/.github/workflows/mcp-smithery-publish.yml +26 -0
- blockchain_verification_mcp-1.0.0/.gitignore +6 -0
- blockchain_verification_mcp-1.0.0/.mcp.json +69 -0
- blockchain_verification_mcp-1.0.0/LICENSE +13 -0
- blockchain_verification_mcp-1.0.0/PKG-INFO +28 -0
- blockchain_verification_mcp-1.0.0/README.md +22 -0
- blockchain_verification_mcp-1.0.0/package.json +19 -0
- blockchain_verification_mcp-1.0.0/pyproject.toml +24 -0
- blockchain_verification_mcp-1.0.0/server.py +78 -0
- blockchain_verification_mcp-1.0.0/smithery.yaml +34 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: Publish to Smithery
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
jobs:
|
|
8
|
+
publish:
|
|
9
|
+
name: Publish MCP Server to Smithery
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
permissions:
|
|
12
|
+
contents: read
|
|
13
|
+
steps:
|
|
14
|
+
- name: Checkout repository
|
|
15
|
+
uses: actions/checkout@v4
|
|
16
|
+
|
|
17
|
+
- name: Setup Node.js
|
|
18
|
+
uses: actions/setup-node@v4
|
|
19
|
+
with:
|
|
20
|
+
node-version: '20'
|
|
21
|
+
|
|
22
|
+
- name: Publish to Smithery
|
|
23
|
+
env:
|
|
24
|
+
SMITHERY_API_KEY: ${{ secrets.SMITHERY_API_KEY }}
|
|
25
|
+
run: |
|
|
26
|
+
npx @smithery/cli mcp publish "https://github.com/${{ github.repository }}" -n nicholastempleman/${{ github.event.repository.name }}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "blockchain-verification-mcp",
|
|
3
|
+
"description": "> **By [MEOK AI Labs](https://meok.ai)** \u2014 MEOK AI Labs MCP Server",
|
|
4
|
+
"version": "1.0.0",
|
|
5
|
+
"tools": [
|
|
6
|
+
{
|
|
7
|
+
"name": "mint_certificate",
|
|
8
|
+
"description": "Mint a blockchain-backed certificate with SHA-256 hash chain verification.",
|
|
9
|
+
"parameters": {
|
|
10
|
+
"type": "object",
|
|
11
|
+
"properties": {
|
|
12
|
+
"organization": {
|
|
13
|
+
"type": "string"
|
|
14
|
+
},
|
|
15
|
+
"framework": {
|
|
16
|
+
"type": "string"
|
|
17
|
+
},
|
|
18
|
+
"scope": {
|
|
19
|
+
"type": "string"
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"required": [
|
|
23
|
+
"organization",
|
|
24
|
+
"framework",
|
|
25
|
+
"scope"
|
|
26
|
+
]
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
"name": "verify_certificate",
|
|
31
|
+
"description": "Verify a certificate's authenticity by checking its hash chain and signatures.",
|
|
32
|
+
"parameters": {
|
|
33
|
+
"type": "object",
|
|
34
|
+
"properties": {
|
|
35
|
+
"certificate_id": {
|
|
36
|
+
"type": "string"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
"required": [
|
|
40
|
+
"certificate_id"
|
|
41
|
+
]
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"name": "audit_trail",
|
|
46
|
+
"description": "Get the full audit trail for a certificate including all verification events.",
|
|
47
|
+
"parameters": {
|
|
48
|
+
"type": "object",
|
|
49
|
+
"properties": {
|
|
50
|
+
"organization": {
|
|
51
|
+
"type": "string"
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
"required": [
|
|
55
|
+
"organization"
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"name": "integrity_check",
|
|
61
|
+
"description": "Run integrity checks on the certificate store to detect tampering or corruption.",
|
|
62
|
+
"parameters": {
|
|
63
|
+
"type": "object",
|
|
64
|
+
"properties": {},
|
|
65
|
+
"required": []
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
]
|
|
69
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 MEOK AI Labs
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: blockchain-verification-mcp
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: MEOK AI Labs — blockchain-verification-mcp
|
|
5
|
+
Project-URL: Homepage, https://meok.ai
|
|
6
|
+
Project-URL: Repository, https://github.com/CSOAI-ORG/blockchain-verification-mcp
|
|
7
|
+
Author-email: MEOK AI Labs <nicholas@meok.ai>
|
|
8
|
+
License: MIT License
|
|
9
|
+
|
|
10
|
+
Copyright (c) 2026 MEOK AI Labs
|
|
11
|
+
|
|
12
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
13
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
14
|
+
in the Software without restriction, including without limitation the rights
|
|
15
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
17
|
+
furnished to do so, subject to the following conditions:
|
|
18
|
+
|
|
19
|
+
The above copyright notice and this permission notice shall be included in all
|
|
20
|
+
copies or substantial portions of the Software.
|
|
21
|
+
License-File: LICENSE
|
|
22
|
+
Keywords: ai,blockchain,mcp,meok,verification
|
|
23
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
24
|
+
Classifier: Operating System :: OS Independent
|
|
25
|
+
Classifier: Programming Language :: Python :: 3
|
|
26
|
+
Classifier: Topic :: Software Development :: Libraries
|
|
27
|
+
Requires-Python: >=3.10
|
|
28
|
+
Requires-Dist: mcp>=1.0.0
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# Blockchain Verification MCP Server
|
|
2
|
+
|
|
3
|
+
By **MEOK AI Labs** | https://meok.ai
|
|
4
|
+
|
|
5
|
+
## Overview
|
|
6
|
+
|
|
7
|
+
Blockchain Verification is an MCP server providing specialized tools for AI systems.
|
|
8
|
+
|
|
9
|
+
## Tools
|
|
10
|
+
|
|
11
|
+
See `server.py` for the full tool catalog.
|
|
12
|
+
|
|
13
|
+
## Installation
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
pip install mcp
|
|
17
|
+
python server.py
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## License
|
|
21
|
+
|
|
22
|
+
MIT — see LICENSE
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "blockchain-verification-mcp",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Blockchain Verification MCP Server by MEOK AI Labs",
|
|
5
|
+
"main": "server.py",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"start": "python server.py"
|
|
8
|
+
},
|
|
9
|
+
"keywords": [
|
|
10
|
+
"mcp",
|
|
11
|
+
"ai",
|
|
12
|
+
"meok"
|
|
13
|
+
],
|
|
14
|
+
"license": "MIT",
|
|
15
|
+
"repository": {
|
|
16
|
+
"type": "git",
|
|
17
|
+
"url": "https://github.com/CSOAI-ORG/blockchain-verification-mcp"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
[project]
|
|
5
|
+
name = "blockchain-verification-mcp"
|
|
6
|
+
version = "1.0.0"
|
|
7
|
+
description = "MEOK AI Labs — blockchain-verification-mcp"
|
|
8
|
+
license = {file = "LICENSE"}
|
|
9
|
+
requires-python = ">=3.10"
|
|
10
|
+
authors = [{name = "MEOK AI Labs", email = "nicholas@meok.ai"}]
|
|
11
|
+
dependencies = ["mcp>=1.0.0"]
|
|
12
|
+
keywords = ["mcp", "ai", "meok", "blockchain", "verification"]
|
|
13
|
+
classifiers = [
|
|
14
|
+
"Programming Language :: Python :: 3",
|
|
15
|
+
"License :: OSI Approved :: MIT License",
|
|
16
|
+
"Operating System :: OS Independent",
|
|
17
|
+
"Topic :: Software Development :: Libraries",
|
|
18
|
+
]
|
|
19
|
+
[project.urls]
|
|
20
|
+
Homepage = "https://meok.ai"
|
|
21
|
+
Repository = "https://github.com/CSOAI-ORG/blockchain-verification-mcp"
|
|
22
|
+
[tool.hatch.build.targets.wheel]
|
|
23
|
+
packages = ["."]
|
|
24
|
+
only-include = ["server.py"]
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""Blockchain Verification MCP Server — Immutable audit trails for compliance certifications."""
|
|
3
|
+
import json, hashlib, time
|
|
4
|
+
from datetime import datetime, timezone
|
|
5
|
+
from collections import defaultdict
|
|
6
|
+
from mcp.server.fastmcp import FastMCP
|
|
7
|
+
import sys, os
|
|
8
|
+
sys.path.insert(0, os.path.expanduser('~/clawd/meok-labs-engine/shared'))
|
|
9
|
+
from auth_middleware import check_access
|
|
10
|
+
|
|
11
|
+
mcp = FastMCP("blockchain-verification", instructions="MEOK AI Labs MCP Server")
|
|
12
|
+
|
|
13
|
+
FREE_DAILY_LIMIT = 15
|
|
14
|
+
_usage = defaultdict(list)
|
|
15
|
+
def _rl(c="anon"):
|
|
16
|
+
now = datetime.now(timezone.utc)
|
|
17
|
+
_usage[c] = [t for t in _usage[c] if (now-t).total_seconds() < 86400]
|
|
18
|
+
if len(_usage[c]) >= FREE_DAILY_LIMIT: return json.dumps({"error": f"Limit {FREE_DAILY_LIMIT}/day"})
|
|
19
|
+
_usage[c].append(now); return None
|
|
20
|
+
_LEDGER: list = []
|
|
21
|
+
|
|
22
|
+
def _hash_block(data: str, prev_hash: str) -> str:
|
|
23
|
+
return hashlib.sha256(f"{prev_hash}{data}{time.time()}".encode()).hexdigest()
|
|
24
|
+
|
|
25
|
+
@mcp.tool()
|
|
26
|
+
def mint_certificate(organization: str, framework: str, scope: str, api_key: str = "") -> str:
|
|
27
|
+
"""Mint a blockchain-backed certificate with SHA-256 hash chain verification."""
|
|
28
|
+
allowed, msg, tier = check_access(api_key)
|
|
29
|
+
if not allowed:
|
|
30
|
+
return {"error": msg, "upgrade_url": "https://meok.ai/pricing"}
|
|
31
|
+
if err := _rl(): return err
|
|
32
|
+
|
|
33
|
+
prev = _LEDGER[-1]["hash"] if _LEDGER else "0" * 64
|
|
34
|
+
payload = json.dumps({"org": organization, "framework": framework, "scope": scope, "ts": time.time()})
|
|
35
|
+
h = _hash_block(payload, prev)
|
|
36
|
+
block = {"index": len(_LEDGER), "hash": h, "prev": prev, "data": payload}
|
|
37
|
+
_LEDGER.append(block)
|
|
38
|
+
return {"certificate_id": h[:16], "block_index": block["index"], "status": "minted"}
|
|
39
|
+
|
|
40
|
+
@mcp.tool()
|
|
41
|
+
def verify_certificate(certificate_id: str, api_key: str = "") -> str:
|
|
42
|
+
"""Verify a certificate's authenticity by checking its hash chain and signatures."""
|
|
43
|
+
allowed, msg, tier = check_access(api_key)
|
|
44
|
+
if not allowed:
|
|
45
|
+
return {"error": msg, "upgrade_url": "https://meok.ai/pricing"}
|
|
46
|
+
if err := _rl(): return err
|
|
47
|
+
|
|
48
|
+
for block in _LEDGER:
|
|
49
|
+
if block["hash"].startswith(certificate_id):
|
|
50
|
+
return {"valid": True, "block_index": block["index"], "data": json.loads(block["data"])}
|
|
51
|
+
return {"valid": False, "error": "Certificate not found"}
|
|
52
|
+
|
|
53
|
+
@mcp.tool()
|
|
54
|
+
def audit_trail(organization: str, api_key: str = "") -> str:
|
|
55
|
+
"""Get the full audit trail for a certificate including all verification events."""
|
|
56
|
+
allowed, msg, tier = check_access(api_key)
|
|
57
|
+
if not allowed:
|
|
58
|
+
return {"error": msg, "upgrade_url": "https://meok.ai/pricing"}
|
|
59
|
+
if err := _rl(): return err
|
|
60
|
+
|
|
61
|
+
results = [json.loads(b["data"]) for b in _LEDGER if json.loads(b["data"]).get("org") == organization]
|
|
62
|
+
return {"organization": organization, "events": results}
|
|
63
|
+
|
|
64
|
+
@mcp.tool()
|
|
65
|
+
def integrity_check(api_key: str = "") -> str:
|
|
66
|
+
"""Run integrity checks on the certificate store to detect tampering or corruption."""
|
|
67
|
+
allowed, msg, tier = check_access(api_key)
|
|
68
|
+
if not allowed:
|
|
69
|
+
return {"error": msg, "upgrade_url": "https://meok.ai/pricing"}
|
|
70
|
+
if err := _rl(): return err
|
|
71
|
+
|
|
72
|
+
for i in range(1, len(_LEDGER)):
|
|
73
|
+
if _LEDGER[i]["prev"] != _LEDGER[i-1]["hash"]:
|
|
74
|
+
return {"valid": False, "broken_at_index": i}
|
|
75
|
+
return {"valid": True, "blocks": len(_LEDGER)}
|
|
76
|
+
|
|
77
|
+
if __name__ == "__main__":
|
|
78
|
+
mcp.run()
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
name: blockchain-verification-mcp
|
|
2
|
+
description: MEOK AI Labs MCP Server
|
|
3
|
+
version: 1.0.0
|
|
4
|
+
tools:
|
|
5
|
+
- name: mint_certificate
|
|
6
|
+
description: Mint a blockchain-backed certificate with SHA-256 hash chain verification.
|
|
7
|
+
parameters:
|
|
8
|
+
- name: organization
|
|
9
|
+
type: string
|
|
10
|
+
required: true
|
|
11
|
+
- name: framework
|
|
12
|
+
type: string
|
|
13
|
+
required: true
|
|
14
|
+
- name: scope
|
|
15
|
+
type: string
|
|
16
|
+
required: true
|
|
17
|
+
- name: verify_certificate
|
|
18
|
+
description: Verify a certificate's authenticity by checking its hash chain and
|
|
19
|
+
signatures.
|
|
20
|
+
parameters:
|
|
21
|
+
- name: certificate_id
|
|
22
|
+
type: string
|
|
23
|
+
required: true
|
|
24
|
+
- name: audit_trail
|
|
25
|
+
description: Get the full audit trail for a certificate including all verification
|
|
26
|
+
events.
|
|
27
|
+
parameters:
|
|
28
|
+
- name: organization
|
|
29
|
+
type: string
|
|
30
|
+
required: true
|
|
31
|
+
- name: integrity_check
|
|
32
|
+
description: Run integrity checks on the certificate store to detect tampering or
|
|
33
|
+
corruption.
|
|
34
|
+
parameters: []
|