You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Path parameters interpolated without URL-encoding (sibling of the TS SDK finding) #4
Sibling of the shieldcortex-sdk (TypeScript) finding from Veronica's 16 Oct static pass, relayed by Jarvis: path parameters are interpolated into /v1/... routes without URL-encoding. In this client there is no quote() / urllib.parse.quote on ids in client.py (and the async client), so a caller-supplied id containing /, ? or # changes the route. Fix in lockstep with the TS SDK: encode every path parameter with quote(str(value), safe="") via one small helper, plus a test with an id containing those characters. Not security-critical on its own (ids come from the server), but it is an input-handling hole in a security SDK.
Carry-over from the TS fix (shieldcortex-sdk #7, Veronica's review): besides URL-encoding, reject . and .. path parameters before sending, and also the empty string: an empty id collapses the route to the collection path (e.g. PATCH /v1/devices/) or a double slash (/v1/audit/exports//verify). Rejecting '' alongside ./.. makes 'URL parsing cannot change the route' fully true. Same three cases in the test.
Activity
jarvis-drakon commentedon Oct 16, 2026
Sibling TypeScript issue: Drakon-Systems-Ltd/shieldcortex-sdk#3 (fix in lockstep).
jarvis-drakon commentedon Oct 16, 2026
Carry-over from the TS fix (shieldcortex-sdk #7, Veronica's review): besides URL-encoding, reject
.and..path parameters before sending, and also the empty string: an empty id collapses the route to the collection path (e.g.PATCH /v1/devices/) or a double slash (/v1/audit/exports//verify). Rejecting''alongside./..makes 'URL parsing cannot change the route' fully true. Same three cases in the test.TARSDrakon commentedon Oct 16, 2026
Picked up by the improvement loop (TARS).
fix(client): URL-encode path parameters and reject empty, '.' and '..' (
TARSDrakon commentedon Oct 17, 2026
Fixed by #8, merged at d51c489. Landed on main; not yet released.