Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request adds a new secured agent MCP server example to the
examples-kotlinproject, demonstrating OAuth2 JWT-based security for agent endpoints. It introduces a newMarketIntelligenceAgentwith fine-grained authority requirements, provides a secure profile and configuration, and includes local JWT key generation and validation setup.Security and configuration enhancements:
embabel-agent-mcp-securityinexamples-common/pom.xmlto enable security features.SECURED_PROFILEinMcpServers.ktfor activating secured configuration.application-secured.ymlwith OAuth2 JWT resource server configuration, server port, and application metadata for the secured profile.Secured agent server and agent implementation:
KotlinAgentSecuredMcpServerApplication.kt, a new Spring Boot application entry point that runs the secured MCP server with Docker and JWT security profiles.MarketIntelligenceAgent.kt, a new agent requiring themarket:adminauthority, which produces structured market intelligence reports with a multi-step LLM pipeline and detailed data classes for report structure.Local JWT key management and testing:
keysdirectory with instructions (README.txt) and a sample public key (public.pem) for local JWT validation; included a Python script (generate_token.py) to generate test JWTs using the private key. [1] [2] [3]Build configuration:
enable-secured-agent-mcp-serverinexamples-kotlin/pom.xmlto build and run the secured agent server example, including required dependencies and main class setup.