feat: sanitize sensitive data in spec-renderer [KHCP-20404]#860
Draft
sharmaadityaHQ wants to merge 6 commits into
Draft
feat: sanitize sensitive data in spec-renderer [KHCP-20404]#860sharmaadityaHQ wants to merge 6 commits into
sharmaadityaHQ wants to merge 6 commits into
Conversation
ValeryG
previously approved these changes
Apr 27, 2026
adamdehaven
reviewed
Apr 27, 2026
| export type SensitiveDataMaskType = 'full' | 'regex' | 'hash' | 'remove' | ||
|
|
||
| export interface XSensitiveData { | ||
| mask: SensitiveDataMaskType |
Member
There was a problem hiding this comment.
needs a comment above the property
| } | ||
|
|
||
| export interface SecuritySchemeMaskRule { | ||
| location: 'header' | 'query' | 'cookie' |
Member
There was a problem hiding this comment.
needs a comment above the property
| path: '/search', | ||
| request: { | ||
| query: [ | ||
| // @ts-ignore |
Member
There was a problem hiding this comment.
need descriptions after ts-ignore
Collaborator
🔴 PR audit failed. 🔴🔥 Renovate Security PRs detected.There are 1 open renovate security PRs older than 3 days. This PR cannot be merged until all renovate security PRs created more than 3 days ago are resolved. 🔥 PNPM Audit issues detected.PR with those issues cannot be merged. How to resolve:
|
Collaborator
Install the preview package from this PR@kong/spec-renderer@pr-860 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR aims to implement mechanisms to sanitize sensitive data in spec-renderer.
Why?
Prevent data leakage, requested by customer (InteliiTrans).
Jira - https://konghq.atlassian.net/browse/KHCP-20404
Consuming app PR - https://github.com/kong-konnect/portal/pull/2333
Demo
Screen.Recording.2026-04-28.at.1.59.32.AM.mov