Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Formatting bug in PR review comment

未关闭
#100 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
30/100
Issue 类型
缺陷
描述清晰度
需要澄清
活跃度
停滞
技术栈
typescript
领域
security

调研方向

Start with the linked pull-request review and reproduce how the devfest-demo GitHub App renders the review comment containing <SUMMARY> tags. No repository file or test is named; trace the comment-formatting entry point and consider the work done when those tags display correctly in review comments.

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

描述

Related to #99 because the screenshot below is from the same repo and setup.

https://github.com/branbaratheon/ai-student-assistant/pull/8#pullrequestreview-3378739570

A comment left by the GitHub App named devfest-demo, which is powered by Gemini CLI security extension GitHub Action, has a formatting bug. The < and > tags don't get displayed correctly in review comments.

<SUMMARY>
## 📋 Review Summary

This pull request correctly fixes a critical XSS vulnerability in the chat interface by replacing `innerHTML` with `textContent`. The change is effective and follows security best practices for rendering user-provided content.

## 🔍 General Feedback

While the primary goal of this PR is achieved, a review of the related backend code in `main.py` revealed several critical security vulnerabilities that should be addressed immediately:

- **Prompt Injection:** The user-provided message is directly concatenated into the prompt sent to the language model. This creates a prompt injection vulnerability, where a malicious user could override the system prompt and manipulate the model's behavior. All user input should be properly sanitized or handled in a way that prevents it from being interpreted as instructions.

- **Sensitive Data Exposure:** The entire content of `database.py`, including student grades, is sent to the language model as part of the prompt. While the system prompt instructs the model not to reveal grades, this is not a reliable security control. The model could still be tricked into revealing this confidential data through prompt injection. Sensitive data should not be included in prompts. Instead, the backend should query the database for specific information and only provide the necessary, non-sensitive data to the model.
</SUMMARY>
主要语言
TypeScript
星标
793
派生
59
PR 合并指标
30 天内没有已合并 PR

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

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

gemini-cli-extensions/security 的其他 Issue

查看 gemini-cli-extensions/security 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

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