diff --git a/.changeset/drift-deepobject-query-params.md b/.changeset/drift-deepobject-query-params.md new file mode 100644 index 0000000000..e76a699399 --- /dev/null +++ b/.changeset/drift-deepobject-query-params.md @@ -0,0 +1,6 @@ +--- +'@redocly/cli': patch +--- + +Fixed the `drift` command's `schema-consistency` rule reporting false-positive "Undocumented query parameter" findings for `deepObject`-style query parameters. +Traffic keys like `namespace[id]=...&namespace[name]=...` are now matched to the documented `namespace` parameter, and the reconstructed object is validated against the parameter schema. diff --git a/.changeset/drift-ignore-headers.md b/.changeset/drift-ignore-headers.md new file mode 100644 index 0000000000..c60f1e9dd5 --- /dev/null +++ b/.changeset/drift-ignore-headers.md @@ -0,0 +1,7 @@ +--- +'@redocly/cli': minor +--- + +Added an `--ignore-headers` option to the experimental `drift` and `proxy` commands. +It takes a comma-separated list of header names to skip in undocumented-header checks, and a trailing `*` matches by prefix (for example `x-consumer-*`). +Use it to silence headers a gateway or proxy adds that are not part of the API contract. diff --git a/.changeset/drift-skip-request-checks-on-4xx.md b/.changeset/drift-skip-request-checks-on-4xx.md new file mode 100644 index 0000000000..5e8ad60549 --- /dev/null +++ b/.changeset/drift-skip-request-checks-on-4xx.md @@ -0,0 +1,9 @@ +--- +'@redocly/cli': patch +--- + +Fixed an issue where the `drift` command's `schema-consistency` rule reported false-positive request findings for exchanges the server rejected with a `4xx` client error. +For example: missing required parameter, missing required body, request-body schema mismatch. +A `4xx` response means the server never accepted the request. +Validating it against the operation's success-path contract flagged the server's own correct rejection as drift. +Response-side validation still runs, so a documented error response whose shape differs from reality is still reported. diff --git a/.changeset/loopback-drift-transport.md b/.changeset/loopback-drift-transport.md new file mode 100644 index 0000000000..c767f280f4 --- /dev/null +++ b/.changeset/loopback-drift-transport.md @@ -0,0 +1,6 @@ +--- +'@redocly/cli': patch +--- + +Fixed an issue where the `drift` command's `security-baseline` rule reported false-positive "credential exposure over insecure HTTP transport" warnings for traffic captured against loopback hosts, for example: `localhost`, `*.localhost`, `127.0.0.0/8`, `[::1]`. +Sandboxed recordings no longer produce transport warnings. diff --git a/docs/@v2/commands/drift.md b/docs/@v2/commands/drift.md index ea030f9953..36e0f3a9f4 100644 --- a/docs/@v2/commands/drift.md +++ b/docs/@v2/commands/drift.md @@ -55,6 +55,7 @@ redocly drift --api [--match-mode=