Repository navigation
feat(privacy): support automatic privacy extraction and restore for sessions - #6278
Open
J-StrawHat wants to merge 24 commits into
Open
J-StrawHat wants to merge 24 commits into
J-StrawHat wants to merge 24 commits into
Conversation
11 of 21 tasks
# Conflicts: # openviking/session/session.py
J-StrawHat
marked this pull request as ready for review
October 20, 2026 02:42
yeshion23333
requested changes
Oct 20, 2026
yeshion23333
left a comment
Collaborator
There was a problem hiding this comment.
本次审查确认 4 个需要修复的问题:默认 JSONL 读取可能暴露已经保护的凭据;同批重复凭据会制造歧义并阻断后续消息写入;普通英文被误识别为 Basic 认证信息;此前允许的 Session ID 在首次保存凭据时被拒绝。
验证:130 项相关 Python 测试和 6 项 Rust 测试通过;额外 7 个回归用例复现了上述问题,使用真实的 Session、Privacy、FS 业务代码及原生匹配器,仅以内存适配器替换存储。完整服务测试受本地向量引擎版本限制未完成。具体触发条件和修复建议见 4 条行内评论。
Collaborator
Author
|
根据 review,修复了以下四个问题:
同时,还做了如下改动:
|
This branch has not been deployed
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.
Description
Session messages can contain sensitive values that would otherwise be stored as plaintext. This PR extends OpenViking's privacy extraction and restore capabilities to Sessions, following the existing Skill privacy workflow.
Sensitive values are replaced with placeholders before message persistence and tool output externalization. Registered privacy values are reused, with preference given to uniquely matching personal credentials; newly detected values are saved in the current Session's privacy config.
When reading Session content, placeholders are restored from the active privacy configs through the existing Privacy service. Default reads continue to apply standard privacy sanitization.
Human Involvement
Related Issue
Extends the Privacy management capabilities introduced in PR #6161.
Type of Change
Changes Made
Testing
Focused validation for the retained changes:
Checklist
Screenshots (if applicable)
Before:
After: (Sensitive credentials have been automatically replaced with placeholders)
Additional Notes