Bug: Personal Vault stores plaintext passwords and allows unsafe note paths

未关闭
#15,759 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
python

调研方向

The payload names only users.json and the note-path construction under each user's vault; it does not name source files or tests. Start by finding where the login check compares passwords and where note names are joined into paths. Done means passwords are stored and verified with a salted hash from the standard library, note names are validated so they cannot leave the vault directory, and a test covers both. Scope is open, so confirm the approach with maintainers first.

由索引模型根据 Issue 内容生成。

描述

bug
Repository commit

unknown

Python version (python --version)

Python 3.x

Dependencies version (pip freeze)

The app uses a local users.json file and standard library modules only. No dependency list was provided for the sample application.

Expected behavior

The Personal Vault application should not store passwords in plaintext, and note filenames should be validated before being used to construct filesystem paths. The login flow should verify credentials securely and user note operations should remain confined to the current vault directory.

Actual behavior

The sample application stores each password in users.json as plaintext and compares it directly during login. It accepts arbitrary note names and uses them to build paths under the user's vault without validating or normalizing them. This can allow credential disclosure and filesystem access outside the intended vault directory, and file operations can crash or behave unexpectedly when an invalid path is used.

主要语言
Python
星标
226k
派生
51.3k
平均合并
8 小时 58 分钟
30 天内合并 PR
4

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

TheAlgorithms/Python 的其他 Issue

查看 TheAlgorithms/Python 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。