Repository navigation
Generate experimental API commands with compatibility error guidance - #69
dennis-chen-vanta wants to merge 1 commit into
Conversation
Co-authored-by: Codex <noreply@openai.com>
| target = (target as Record<string, unknown>)?.[ | ||
| part.replace(/~1/g, "/").replace(/~0/g, "~") | ||
| ]; |
There was a problem hiding this comment.
🟡 Medium severity blocking issue identified in your code:
Possibility of prototype polluting function detected. By adding or modifying attributes of an object prototype, it is possible to create attributes that exist on every object, or replace critical attributes with malicious ones. This can be problematic if the software depends on existence or non-existence of certain attributes, or uses pre-defined attributes of object prototype (such as hasOwnProperty, toString or valueOf). Possible mitigations might be: freezing the object prototype, using an object without prototypes (via Object.create(null) ), blocking modifications of attributes that resolve to object prototype, using Map instead of object.
Why this might be safe to ignore:
The matched code only reads a property while resolving an internal JSON reference; it does not assign to an object or modify a prototype. Although an unusual reference could access inherited properties, this context does not provide a meaningful prototype-pollution exploit.
To resolve this comment:
🔧 No guidance has been designated for this issue. Fix according to your organization's approved methods.
💬 Ignore this finding
Reply with Semgrep commands to ignore this finding.
/fp <comment>for false positive/ar <comment>for acceptable risk/other <comment>for all other reasons
Alternatively, triage in Semgrep AppSec Platform to ignore the finding created by prototype-pollution-loop.
You can view more details about this finding in the Semgrep AppSec Platform.
Experimental API endpoints can change or disappear without notice. This adds generated commands under
vanta experimental <operation-name>, using kebab-case OpenAPI operation IDs so experimental routes do not need to follow stable API naming conventions.pnpm generatenow builds a command catalog fromx-vanta-experimental: trueoperations and/experimental/paths. Commands preserve API paths and expose parameter flags, JSON bodies, multipart uploads, downloads, and experimental warnings. Endpoint failures include the command, HTTP status, original error, and guidance that the endpoint may have changed or been removed and the CLI may need updating. Authentication, rate-limit, transport, and local errors retain their specific messages.The checked-in API spec currently has no experimental endpoints, so the production build exposes the namespace with an explanation. Fixtures cover generation and execution without publishing sample endpoints. Stable commands keep their existing behavior.
Validation
pnpm build,pnpm typecheck, andpnpm format:checkpassed.