mirror of
https://github.com/wso2/open-mcp-auth-proxy.git
synced 2025-08-18 04:09:57 +00:00
Update MCP proxy to adhere to the latest draft of MCP specification
This commit is contained in:
parent
3e2c49db5c
commit
d71ee4052c
7 changed files with 169 additions and 19 deletions
19
internal/authz/policy.go
Normal file
19
internal/authz/policy.go
Normal file
|
@ -0,0 +1,19 @@
|
|||
package authz
|
||||
|
||||
import "net/http"
|
||||
|
||||
type Decision int
|
||||
|
||||
const (
|
||||
DecisionAllow Decision = iota
|
||||
DecisionDeny
|
||||
)
|
||||
|
||||
type PolicyResult struct {
|
||||
Decision Decision
|
||||
Message string
|
||||
}
|
||||
|
||||
type PolicyEngine interface {
|
||||
Evaluate(r *http.Request, claims *TokenClaims, requiredScope string) PolicyResult
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue