knative / knative/func

mcp: createHandler lacks readonly mode guard

Open
#3,810 1 comment 0 reactions 1 assignee Claimed by @Elvand-Lie View on GitHub
kind/bug
Dominant language
Go
Stars
365
Forks
223
Avg merge
2d 3h
Merged PRs (30d)
25

Description

## Description
The \createHandler\ in \pkg/mcp/tools_create.go\ lacks the \s.readonly.Load()\ check that is present in other mutating tools like \deployHandler\ and \deleteHandler\.

Because of this, an MCP client can execute the \create\ command (which writes project scaffolding files to the disk) even when the server is operating in readonly mode.

## Expected Behavior
The \create\ tool should check \s.readonly.Load()\ and return an error if readonly mode is enabled, matching the behavior of \deploy\ and \delete\.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.