Skip to content

fix(server): reject whitespace-only and non-string slug and title in POST /sandboxed - #387

Merged
davidmckayv merged 2 commits into
CopilotKit:mainfrom
Ayush7614:fix/sandboxed-whitespace-validation
Sep 6, 2026
Merged

fix(server): reject whitespace-only and non-string slug and title in POST /sandboxed#387
davidmckayv merged 2 commits into
CopilotKit:mainfrom
Ayush7614:fix/sandboxed-whitespace-validation

Conversation

@Ayush7614

Copy link
Copy Markdown
Contributor

POST /api/sandboxed accepted a whitespace-only or non-string slug/title: the truthiness guard let " " and 123 through, storing a blank title verbatim or failing later with a misleading error (or a 500 on a non-string title).

Rejects non-string and whitespace-only slug/title with 400 and trims both before save, mirroring the POST /servers/custom validation. Verified with an 8-case guard script (whitespace, numeric, null, padded inputs) and server typecheck.

@davidmckayv davidmckayv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deep-reviewed against live code (correctness, governance, no vendor/secret/scale issues). Composed build+tests green. CHANGELOG/format rebase on CI-validated substance.

@davidmckayv
davidmckayv merged commit fee851c into CopilotKit:main Sep 6, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants