Closed
CVE-2026-102272 #30
openeuler-ci-botAdd on  Sep 29Closed at  26 days ago
openeuler-ci-bot
openeuler-ci-botCollaborators
Sep 29 Create

一、漏洞信息
漏洞编号:CVE-2026-102272
漏洞归属组件:python-jwt
漏洞归属的版本:1.7.1,2.0.0,2.0.1,2.13.0,2.3.0,2.6.0,2.7.0,2.8.0,2.9.0
CVSS评分:
BaseScore:7.4 High
Vector:CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
漏洞简述:
PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, HMACAlgorithm.prepare_key in jwt/algorithms.py is affected because raw-JWK detector does not normalize accepted Unicode byte-order marks before checking for JSON. This occurs when a public JWK is prefixed with a UTF-8 BOM and used in a mixed-algorithm verification path. As a result, public JWK bypasses asymmetric-key detection and becomes the HMAC secret. Consequently, an attacker who knows the public key can forge authenticated tokens. This issue is fixed in version 2.14.0.
漏洞公开时间:2026-09-29 05:17:15
漏洞创建时间:2026-09-29 05:38:14
漏洞详情参考链接:
https://nvd.nist.gov/vuln/detail/CVE-2026-102272

更多参考(点击展开)
参考来源 参考链接 来源链接
https://github.com/jpadilla/pyjwt/commit/180783930de91876bc0d601f826a1f2956057291
https://github.com/jpadilla/pyjwt/security/advisories/GHSA-r6x4-923q-g947
https://github.com/jpadilla/pyjwt/releases/tag/2.14.0

漏洞分析指导链接:
https://atomgit.com/openeuler/cve-manager/blob/master/cve-vulner-manager/doc/md/manual.md
漏洞数据来源:
七彩瞬析开源风险感知平台
漏洞补丁信息:

详情(点击展开)
影响的包 修复版本 修复补丁 问题引入补丁 来源
https://github.com/jpadilla/pyjwt/commit/180783930de91876bc0d601f826a1f2956057291 circl

二、漏洞分析结构反馈
影响性分析说明:
PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, HMACAlgorithm.prepare_key in jwt/algorithms.py is affected because raw-JWK detector does not normalize accepted Unicode byte-order marks before checking for JSON. This occurs when a public JWK is prefixed with a UTF-8 BOM and used in a mixed-algorithm verification path. As a result, public JWK bypasses asymmetric-key detection and becomes the HMAC secret. Consequently, an attacker who knows the public key can forge authenticated tokens. This issue is fixed in version 2.14.0.
openEuler评分:
7.4
Vector:CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
受影响版本排查(受影响/不受影响):
1.master(2.13.0):受影响
2.openEuler-20.03-LTS-SP4(1.7.1):不受影响
3.openEuler-22.03-LTS-SP4(2.3.0):不受影响
4.openEuler-24.03-LTS-Next(2.8.0):不受影响
5.openEuler-24.03-LTS-SP1(2.8.0):不受影响
6.openEuler-24.03-LTS-SP3(2.8.0):不受影响
7.openEuler-24.03-LTS-SP4(2.8.0):不受影响

修复是否涉及abi变化(是/否):
1.master(2.13.0):否
2.openEuler-20.03-LTS-SP4(1.7.1):否
3.openEuler-22.03-LTS-SP4(2.3.0):否
4.openEuler-24.03-LTS-Next(2.8.0):否
5.openEuler-24.03-LTS-SP1(2.8.0):否
6.openEuler-24.03-LTS-SP3(2.8.0):否
7.openEuler-24.03-LTS-SP4(2.8.0):否

原因说明:
1.master(2.13.0):正常修复
2.openEuler-20.03-LTS-SP4(1.7.1):不受影响-漏洞代码不存在
3.openEuler-22.03-LTS-SP4(2.3.0):不受影响-漏洞代码不存在
4.openEuler-24.03-LTS-Next(2.8.0):不受影响-漏洞代码不存在
5.openEuler-24.03-LTS-SP1(2.8.0):不受影响-漏洞代码不存在
6.openEuler-24.03-LTS-SP3(2.8.0):不受影响-漏洞代码不存在
7.openEuler-24.03-LTS-SP4(2.8.0):不受影响-漏洞代码不存在

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Added label: CVE/UNFIXED
openeuler-ci-bot
openeuler-ci-botCollaborators
Sep 29 Comments:

issue处理注意事项:
1. 提交正常修复分支的修复PR时,必须关联当前issue,否则无法关闭当前issue;
2. 模板内容需要填写完整, 无论是受影响或者不受影响都需要填写完整内容;
3. 以下为模板中需要填写完整的内容, 请复制到评论区回复;
注: 内容的关键词(影响性分析说明, openEuler评分, 受影响版本排查(受影响/不受影响), 修复是否涉及abi变化(是/否), 原因说明)不能省略,省略后cve-manager将无法正常解析填写内容.


影响性分析说明:

openEuler评分: (评分和向量)

受影响版本排查(受影响/不受影响):
1.master(2.13.0):
2.openEuler-20.03-LTS-SP4(1.7.1):
3.openEuler-22.03-LTS-SP4(2.3.0):
4.openEuler-24.03-LTS-Next(2.8.0):
5.openEuler-24.03-LTS-SP1(2.8.0):
6.openEuler-24.03-LTS-SP3(2.8.0):
7.openEuler-24.03-LTS-SP4(2.8.0):

修复是否涉及abi变化(是/否):
1.master(2.13.0):
2.openEuler-20.03-LTS-SP4(1.7.1):
3.openEuler-22.03-LTS-SP4(2.3.0):
4.openEuler-24.03-LTS-Next(2.8.0):
5.openEuler-24.03-LTS-SP1(2.8.0):
6.openEuler-24.03-LTS-SP3(2.8.0):
7.openEuler-24.03-LTS-SP4(2.8.0):

原因说明:
1.master(2.13.0):
2.openEuler-20.03-LTS-SP4(1.7.1):
3.openEuler-22.03-LTS-SP4(2.3.0):
4.openEuler-24.03-LTS-Next(2.8.0):
5.openEuler-24.03-LTS-SP1(2.8.0):
6.openEuler-24.03-LTS-SP3(2.8.0):
7.openEuler-24.03-LTS-SP4(2.8.0):


原因说明填写请参考下方表格(注意:版本是否受影响和版本的原因说明必须对应,例如master版本分支受影响,那原因说明只能是受影响对应的原因之一!):

分支状态
原因说明 使用场景
受影响 正常修复 受影响且需要修复(包含升级版本修复)的漏洞;
受影响且已经修复的漏洞(历史修复PR也需要关联issue);
若因特殊原因无法修复,应修改原因说明为【不修复-特殊原因】,并在安委会备案相关情况。
受影响 暂不修复-漏洞仍在分析中 已关注到相关漏洞,正在处理,未明确漏洞影响和修复方案。
受影响 暂不修复-暂无解决方案或补丁 当前没有可用的修复或补救措施。【影响性分析】中应包含有关为什么没有修复或补救措施的详细说明、上游相关PR等。
受影响 不修复-超出修复范围 没有漏洞的修复计划。当版本停维、软件包宣布生命周期终止或弃用使用。
受影响 不修复-特殊原因导致不再修复 如存在其他特殊情况不修复相关漏洞,或评估后无法升级修复,应在openEuler社区安全委员会例会进行说明备案。
【影响性分析】中应包含不发布修复的详细说明、特殊情况还应有安委会会议纪要。
不受影响 不受影响-组件不存在 软件不受影响,因为易受攻击的组件不在产品中。
不受影响 不受影响-已有内置的内联控制或缓解措施 内置的内联控制或缓解措施可防止攻击者利用漏洞
不受影响 不受影响-漏洞代码不能被攻击者触发 易受攻击的组件存在,并且该组件包含易受攻击的代码。但是,易受攻击的代码的使用方式使得攻击者无法进行任何预期的攻击。
不受影响 不受影响-漏洞代码不在执行路径 易受影响的代码在执行过程中不可访问,包括产品的非预期状态。产品不使用也不执行的组件。
不受影响 不受影响-漏洞代码不存在 产品不受影响,因为漏洞背后的代码在产品中不存在。与component_not_present不同的是,有问题的组件存在,但由于某种原因(例如安全的编译器选项)使漏洞的特定代码不存在于组件中。

issue处理具体操作请参考:
https://atomgit.com/openeuler/cve-manager/blob/master/cve-vulner-manager/doc/md/manual.md
pr关联issue具体操作请参考:
https://docs.atomgit.com/docs/help/home/org_project/pullrequests/pr-related-issue

likedislike
openeuler-ci-bot
openeuler-ci-botCollaborators
Sep 29 Comments:
参考网址 关联pr 状态 补丁链接
https://www.opencve.io/cve/CVE-2026-102272
https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2026-102272
https://security-tracker.debian.org/tracker/CVE-2026-102272
http://www.cnnvd.org.cn/web/vulnerability/queryLds.tag?qcvCnnvdid=CVE-2026-102272
https://nvd.nist.gov/vuln/detail/CVE-2026-102272
https://ubuntu.com/security/CVE-2026-102272NoneNonehttps://discourse.ubuntu.com/c/project

说明:补丁链接仅供初步排查参考,实际可用性请人工再次确认,补丁下载验证可使用CVE补丁工具。
若补丁不准确,烦请在此issue下评论 '/report-patch 参考网址 补丁链接1,补丁链接2' 反馈正确信息,便于我们不断优化工具,不胜感激。
如 /report-patch https://security-tracker.debian.org/tracker/CVE-2021-3997 https://github.com/systemd/systemd/commit/5b1cf7a9be37e20133c0208005274ce4a5b5c6a1

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Assign openeuler-ci-bot、licihua、dillon_chen、overweight、zhujianwei001、xujing99、shenyangyang as responsible person
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Added label: sig/Base-service
openeuler-ci-bot
openeuler-ci-botCollaborators
Sep 29 Comments:

Welcome To openEuler Community

Hey @openeuler-ci-bot , thanks for your contribution to the community.

Bot Usage Manual

I'm the Bot here serving you. You can find the instructions on how to interact with me at Here . That means you can comment below every pull request or issue to trigger Bot Commands. You can self-configure the PR merge rules for this repository. For more details, please refer to Here.

Contact Guide

If you have any questions, please contact the SIG: Base-service ,
and any of the maintainers: @dillon_chen, @licihua, @overweight, @shenyangyang, @xujing99, @zhujianwei001 ,
and any of the committers: @yangyuan32, @zhuchunyi .

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Modify description of issue
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Removed responsible person licihua、dillon_chen、overweight、zhuchunyi、zhujianwei001、xujing99、shenyangyang
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 29 Modify description of issue
openeuler-ci-botopeneuler-ci-botCollaborators
Sep 30 Modify description of issue
Iinfra_team
Sep 30 Associated pull request
yixiangzhike
Sep 30 Comments:

CVE-2026-102272与CVE-2026-48526补丁相关,除master外的其它分支若已合入CVE-2026-48526相关补丁,则涉及CVE-2026-102272,否则,不涉及CVE-2026-102272。

CVE-2026-48526目前未修复,除master外的分支暂不受CVE-2026-102272影响,后续若修复CVE-2026-48526,则需同时关注CVE-2026-102272。
CVE-2026-48526 issue: https://gitcode.com/src-openeuler/python-jwt/issues/27

likedislike
Iinfra_team
Oct 9 Associated pull request
yixiangzhike
29 days ago Comments:

/branches openEuler-20.03-LTS-SP4,openEuler-22.03-LTS-SP4,openEuler-24.03-LTS-SP4 /name yixiangzhike /email yixiangzhike007@163.com

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

正在自动化处理任务,任务编号:TASK-gitcode__python-jwt-30-20261010104941-0,指定分支:openEuler-20.03-LTS-SP4

⏳ 进度更新 (11:00): 已运行 10 分钟 | 当前阶段: Step 4/8 源码影响性分析

✅ 任务结束 (用时: 12分钟)

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

正在自动化处理任务,任务编号:TASK-gitcode__python-jwt-30-20261010104942-1,指定分支:openEuler-22.03-LTS-SP4

⏳ 进度更新 (11:00): 已运行 10 分钟 | 当前阶段: Step 8/8 生成评论

✅ 任务结束 (用时: 12分钟)

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

正在自动化处理任务,任务编号:TASK-gitcode__python-jwt-30-20261010104942-2,指定分支:openEuler-24.03-LTS-SP4

⏳ 进度更新 (10:55): 已运行 5 分钟 | 当前阶段: Step 4/8 源码影响性分析

✅ 任务结束 (用时: 8分钟)

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

【任务 #30 · openEuler-24.03-LTS-SP4】CVE-2026-102272

1. 是否受影响

结论:不受影响。

CVE-2026-102272 的自有补丁经 Step 4 源码影响性分析判为 NOT_APPLICABLE,漏洞代码不存在于本版本源码,无需修复。

分支状态:

  • openEuler-24.03-LTS-SP4(版本 2.8.0):不受影响(漏洞代码不存在,补丁 NOT_APPLICABLE)

2. 是否有修复补丁

已找到上游社区修复补丁:

3. 补丁适配情况

无适配项。由于源码影响性分析判定该补丁 NOT_APPLICABLE(漏洞代码不存在于本版本源码),无需进行补丁适配,也无前置补丁。

4. 是否提交 PR

无 PR。本分支不受影响,无需提交修复 PR。

──────── 复制以下内容回填 issue ────────
受影响版本排查(受影响/不受影响):
1.openEuler-24.03-LTS-SP4(2.8.0): 不受影响
ABI 变化:否
原因说明:
1.不受影响-漏洞代码不存在
────────────────────────────────────────

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

【任务 #30 · openEuler-22.03-LTS-SP4】CVE-2026-102272

1. 是否受影响:不受影响

CVE-2026-102272 的自有补丁经 Step 4 源码影响性分析判为 NOT_APPLICABLE(漏洞代码不存在于本版本源码),无需修复。该漏洞位于 HMACAlgorithm.prepare_key(jwt/algorithms.py)中的 raw-JWK 探测器,而本分支 PyJWT 2.3.0 的 prepare_key(jwt/algorithms.py:184-194)仅含 force_bytes 与 PEM/SSH 密钥格式检查,不含任何 raw-JWK 探测逻辑;全树检索补丁涉及符号(jwk_obj、key_bytes、json.detect_encoding、RecursionError)均为零匹配,确认漏洞代码不存在。

各分支状态:

  • openEuler-22.03-LTS-SP4(2.3.0):不受影响

2. 是否有修复补丁

上游社区已有修复补丁:
https://github.com/jpadilla/pyjwt/commit/180783930de91876bc0d601f826a1f2956057291.patch

3. 补丁适配情况

无适配内容,亦无前置补丁。因漏洞代码不存在于本版本源码,补丁判为 NOT_APPLICABLE,本分支无需适配或回移植该补丁。

4. 是否提交 PR

未提交 PR:本分支不受影响,无需修复。

──────── 复制以下内容回填 issue ────────
受影响版本排查(受影响/不受影响):
1.openEuler-22.03-LTS-SP4(2.3.0): 不受影响
ABI 变化:否
原因说明:
1.不受影响-漏洞代码不存在
────────────────────────────────────────

likedislike
xiaoo_robot
xiaoo_robot
29 days ago Comments:

【任务 #30 · openEuler-20.03-LTS-SP4】CVE-2026-102272

是否受影响:不受影响

CVE-2026-102272 的漏洞点位于 PyJWT HMACAlgorithm.prepare_key 中 raw-JWK 检测器未对接受的密钥做规范化。经 Step 4 源码影响性分析,该漏洞代码不存在于本版本源码:openEuler-20.03-LTS-SP4 携带的 PyJWT 1.7.1 中,prepare_key 仅做字节转换与 PEM/SSH 格式检查,不含补丁所修复的 raw-JWK 检测逻辑,自有补丁判定为 NOT_APPLICABLE,无需修复。

分支状态:

  • openEuler-20.03-LTS-SP4(1.7.1):不受影响(漏洞代码不存在,补丁 NOT_APPLICABLE)

是否有修复补丁:有

上游补丁:https://github.com/jpadilla/pyjwt/commit/180783930de91876bc0d601f826a1f2956057291.patch

补丁适配情况:无适配

该补丁经源码影响性分析判定为 NOT_APPLICABLE:其修复的 raw-JWK 检测代码块在 1.7.1 源码中不存在,补丁上下文无法锚定,属漏洞代码不在本版本,无需进行适配。

是否提交 PR:无 PR。本分支不受影响、无需修复,故未提交 PR。

──────── 复制以下内容回填 issue ────────
受影响版本排查(受影响/不受影响):
1.openEuler-20.03-LTS-SP4(1.7.1): 不受影响
ABI 变化:否
原因说明:
1.不受影响-漏洞代码不存在
────────────────────────────────────────

likedislike
infra_team
29 days ago Comments:

✅ CVE 修复已由现有 PR 覆盖(同一方案)

CVE: CVE-2026-102272

针对分支: master

修复 PR: https://gitcode.com/src-openeuler/python-jwt/merge_requests/98

说明:

  • 本仓库当期已有同方案的修复 PR,本 CVE 的修复已包含其中,无需重复提交
  • 此结论仅针对上述分支;其他分支是否受影响请维护者结合各分支实际情况判断

此评论由 Claude Agent Team 自动生成

likedislike
yixiangzhike
27 days ago Comments:

/branches master /name yixiangzhike /email yixiangzhike007@163.com

likedislike
xiaoo_robot
xiaoo_robot
27 days ago Comments:

正在自动化处理任务,任务编号:TASK-gitcode__python-jwt-30-20261012103046,指定分支:master

⏳ 进度更新 (13:57): 已运行 206 分钟 | 当前阶段: Step 8/8 生成评论

✅ 任务结束 (用时: 208分钟)

likedislike
xiaoo_robotxiaoo_robot
27 days ago Associated pull request
xiaoo_robot
xiaoo_robot
27 days ago Comments:

【任务 #30 · master】CVE-2026-102272

1. 是否受影响

结论:受影响

漏洞本质:HMACAlgorithm.prepare_key 的 raw-JWK 检测可被编码 JWK 绕过。Step 4 源码影响性分析定位成功:CVE 点名的 HMACAlgorithm.prepare_key 位于 pyjwt-2.13.0/jwt/algorithms.py:346-382,其 raw-JWK 检测块(369-380 行)与漏洞模式完全吻合——先以 stripped.startswith(b"{") 门卫,再 json.loads(key_bytes) 且仅捕获 ValueError,全仓库无 RecursionError 处理、无 json.detect_encoding/surrogatepass 归一化,编码/BOM/代理 JWK 可绕过检测直接用作 HMAC 密钥。补丁确认未应用(RecursionError/detect_encoding/surrogatepass 及新测试名全仓库零匹配),漏洞代码存在于本版本源码,需要修复。

分支状态:

  • master(2.13.0):受影响

2. 修复补丁

已找到上游修复补丁:https://github.com/jpadilla/pyjwt/commit/180783930de91876bc0d601f826a1f2956057291.patch

3. 补丁适配情况

存在适配([原补丁] backport-CVE-2026-102272.patch,状态 adapted,置信度 high),无前置补丁。

  • 冲突原因:基线 2.13.0 将 JWK 检查包在 stripped = key_bytes.lstrip() / if stripped.startswith(b"{") 守卫块内(try 为 12 空格缩进),而上游补丁上下文中 try 位于方法顶层(8 空格),core hunk pre-image 与源码结构不一致;且 BOM 前缀的编码 JWK(utf-8-sig/utf-16/utf-32 等)不以 b"{" 开头,若将 except RecursionError 分支留在守卫块内,深层嵌套 JWK 会绕过检查被接受为 HMAC 密钥,修复语义不完整。tests/test_algorithms.py 锚点测试位于基线 197 行(补丁假设 176 行),后随锚点也不同。
  • 适配内容:按上游 18078393 修复后结构对齐——移除守卫、try/except 提升至方法顶层,14 行核心修复代码与原补丁字节一致;既有 isinstance/raise 块仅随结构变化重缩进(内容字节一致)。41 行新增测试按实际基线上下文插入,字节一致,核心修复逻辑保真。
  • 落地验证:pytest -k deep 全部 10 个用例通过;全量 tests/ 238 passed / 154 skipped(cryptography 缺失导致的正常跳过),较基线净增 10 个测试、零回归;适配补丁在干净基线通过 git apply --check;已作为 commit 71880d5 应用于源码目录,git diff HEAD~1 --stat 确认 2 files changed, 60 insertions, 7 deletions。

4. PR

已提交 PR(master 分支):https://gitcode.com/src-openeuler/python-jwt/merge_requests/140

──────── 复制以下内容回填 issue ────────
受影响版本排查(受影响/不受影响):
1.master(2.13.0): 受影响
ABI 变化:否
原因说明:
1.正常修复
────────────────────────────────────────

likedislike
xiaoo_robot
xiaoo_robot
27 days ago Comments:

正在自动化处理任务,任务编号:TASK-gitcode__python-jwt-30-20261012143201,指定分支:master,使用指定补丁(4个)

⏳ 进度更新 (15:42): 已运行 70 分钟 | 当前阶段: Step 5/8 适配补丁

likedislike
Yyixiangzhike
27 days ago Associated pull request
yixiangzhike
27 days ago Comments:

影响性分析说明:PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, HMACAlgorithm.prepare_key in jwt/algorithms.py is affected because raw-JWK detector does not normalize accepted Unicode byte-order marks before checking for JSON. This occurs when a public JWK is prefixed with a UTF-8 BOM and used in a mixed-algorithm verification path. As a result, public JWK bypasses asymmetric-key detection and becomes the HMAC secret. Consequently, an attacker who knows the public key can forge authenticated tokens. This issue is fixed in version 2.14.0.

openEuler评分:7.4 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N

受影响版本排查(受影响/不受影响):
1.master(2.13.0):受影响
2.openEuler-20.03-LTS-SP4(1.7.1):不受影响
3.openEuler-22.03-LTS-SP4(2.3.0):不受影响
4.openEuler-24.03-LTS-Next(2.8.0):不受影响
5.openEuler-24.03-LTS-SP1(2.8.0):不受影响
6.openEuler-24.03-LTS-SP3(2.8.0):不受影响
7.openEuler-24.03-LTS-SP4(2.8.0):不受影响

修复是否涉及abi变化(是/否):
1.master(2.13.0):否
2.openEuler-20.03-LTS-SP4(1.7.1):否
3.openEuler-22.03-LTS-SP4(2.3.0):否
4.openEuler-24.03-LTS-Next(2.8.0):否
5.openEuler-24.03-LTS-SP1(2.8.0):否
6.openEuler-24.03-LTS-SP3(2.8.0):否
7.openEuler-24.03-LTS-SP4(2.8.0):否

原因说明:
1.master(2.13.0):正常修复
2.openEuler-20.03-LTS-SP4(1.7.1):不受影响-漏洞代码不存在
3.openEuler-22.03-LTS-SP4(2.3.0):不受影响-漏洞代码不存在
4.openEuler-24.03-LTS-Next(2.8.0):不受影响-漏洞代码不存在
5.openEuler-24.03-LTS-SP1(2.8.0):不受影响-漏洞代码不存在
6.openEuler-24.03-LTS-SP3(2.8.0):不受影响-漏洞代码不存在
7.openEuler-24.03-LTS-SP4(2.8.0):不受影响-漏洞代码不存在

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
27 days ago Modify description of issue
openeuler-ci-bot
openeuler-ci-botCollaborators
27 days ago Comments:

@openeuler-ci-bot 经过 cve-manager 解析, 已分析的内容如下表所示:

状态 分析项目 内容
已分析 1.影响性分析说明 PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, HMACAlgorithm.prepare_key in jwt/algorithms.py is affected because raw-JWK detector does not normalize accepted Unicode byte-order marks before checking for JSON. This occurs when a public JWK is prefixed with a UTF-8 BOM and used in a mixed-algorithm verification path. As a result, public JWK bypasses asymmetric-key detection and becomes the HMAC secret. Consequently, an attacker who knows the public key can forge authenticated tokens. This issue is fixed in version 2.14.0.
已分析 2.openEulerScore 7.4
已分析 3.openEulerVector AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
已分析 4.受影响版本排查 master:受影响,openEuler-20.03-LTS-SP4:不受影响,openEuler-22.03-LTS-SP4:不受影响,openEuler-24.03-LTS-Next:不受影响,openEuler-24.03-LTS-SP1:不受影响,openEuler-24.03-LTS-SP3:不受影响,openEuler-24.03-LTS-SP4:不受影响
已分析 5.是否涉及abi变化 master:否,openEuler-20.03-LTS-SP4:否,openEuler-22.03-LTS-SP4:否,openEuler-24.03-LTS-Next:否,openEuler-24.03-LTS-SP1:否,openEuler-24.03-LTS-SP3:否,openEuler-24.03-LTS-SP4:否
已分析 6.原因说明 master:正常修复,openEuler-20.03-LTS-SP4:不受影响-漏洞代码不存在,openEuler-22.03-LTS-SP4:不受影响-漏洞代码不存在,openEuler-24.03-LTS-Next:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP1:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP3:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP4:不受影响-漏洞代码不存在

请确认分析内容的准确性, 确认无误后, 您可以进行后续步骤, 否则您可以继续分析.

likedislike
openeuler-ci-bot
openeuler-ci-botCollaborators
27 days ago Comments:

经过cve-manager解析,部分分支PR未合入,如红色字体所示:

原因说明:
1.master:正常修复(PR未合入)
2.openEuler-20.03-LTS-SP4:不受影响-漏洞代码不存在
3.openEuler-22.03-LTS-SP4:不受影响-漏洞代码不存在
4.openEuler-24.03-LTS-Next:不受影响-漏洞代码不存在
5.openEuler-24.03-LTS-SP1:不受影响-漏洞代码不存在
6.openEuler-24.03-LTS-SP3:不受影响-漏洞代码不存在
7.openEuler-24.03-LTS-SP4:不受影响-漏洞代码不存在

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
27 days ago changed custom state from 待办的 to 进行中
xiaoo_robotxiaoo_robot
27 days ago Associated pull request
xiaoo_robot
xiaoo_robot
27 days ago Comments:

【任务 #30 · master】CVE-2026-102272

1. 是否受影响:受影响

漏洞代码存在于本版本源码:HMACAlgorithm.prepare_key(jwt/algorithms.py:346)在 raw-JWK 检测前缺少 BOM 归一化——369-370 行 stripped = key_bytes.lstrip() 后直接 if stripped.startswith(b"{")。Step 4 源码影响性分析判定补丁 APPLICABLE:补丁修改的 2 个文件(jwt/algorithms.py、tests/test_algorithms.py)均精确命中,补丁上下文与源码逐行一致(仅行号偏移 +25),全源码 grep 确认无任何 BOM 剥离逻辑(修复尚未预应用),git apply --check 对原始源码直接通过。

  • master(2.13.0):受影响

2. 修复补丁(上游社区)

3. 补丁适配情况

  • backport-CVE-2026-102272-1.patch:直接应用(confidence high)
  • backport-CVE-2026-102272-2.patch:直接应用(confidence high)
  • backport-CVE-2026-102272-3.patch:直接应用(confidence high)
  • backport-CVE-2026-102272-4.patch:适配后应用(confidence high)

backport-CVE-2026-102272-4.patch 适配要点(唯一冲突 hunk:tests/test_algorithms.py @@ -176,6 +176,47):

  • 冲突原因:baseline 已含 CVE-2026-102266/102267/102268/102271 及本系列 -1/-2/-3 前置补丁,其中 CVE-2026-102271 在锚点测试 test_hmac_prepare_key_accepts_json_without_kty 之后插入了 3 个测试,使原 hunk 尾部上下文不再紧跟锚点,git apply 失败。
  • 适配内容:纯上下文调整,偏离度 0——41 行新测试按原补丁相对位置语义插入锚点测试之后,仅调整 hunk 头行号(@@ -176,6 +176,47 → @@ -223,6 +223,47)并替换尾部 2 行上下文;jwt/algorithms.py 的 14 行核心修复代码按 +25 行偏移自动应用、原样保留,全部 55 行核心 "+" 变更与原补丁逐字节一致,修复逻辑完全保真。
  • 落地验证:已真实应用到源码(commit bf094a3,parent 49eedbb,git diff --stat HEAD~1 = 2 files changed, 55 insertions(+));前向 git apply --check(baseline 49eedbb)与反向 git apply --check -R(HEAD)均通过;10 个新增测试全部通过(tests/test_algorithms.py 65 passed / 90 skipped,skip 均为 crypto 门控)。

前置补丁:无独立前置补丁(本系列 -1/-2/-3 即 -4 的共同前置,已全部应用)。

4. PR 提交情况

已提交 PR(master):https://gitcode.com/src-openeuler/python-jwt/merge_requests/142

──────── 复制以下内容回填 issue ────────
受影响版本排查(受影响/不受影响):
1.master(2.13.0): 受影响
ABI 变化:N/A
原因说明:
1.正常修复
────────────────────────────────────────

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago Associated pull request
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago Associated pull request
yixiangzhike
26 days ago Comments:

/check-issue

likedislike
openeuler-ci-bot
openeuler-ci-botCollaborators
26 days ago Comments:

@openeuler-ci-bot 经过 cve-manager 解析, 已分析的内容如下表所示:

状态 分析项目 内容
已分析 1.影响性分析说明 PyJWT is a Python implementation of JSON Web Token standards. From 2.13.0 until 2.14.0, HMACAlgorithm.prepare_key in jwt/algorithms.py is affected because raw-JWK detector does not normalize accepted Unicode byte-order marks before checking for JSON. This occurs when a public JWK is prefixed with a UTF-8 BOM and used in a mixed-algorithm verification path. As a result, public JWK bypasses asymmetric-key detection and becomes the HMAC secret. Consequently, an attacker who knows the public key can forge authenticated tokens. This issue is fixed in version 2.14.0.
已分析 2.openEulerScore 7.4
已分析 3.openEulerVector AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N
已分析 4.受影响版本排查 master:受影响,openEuler-20.03-LTS-SP4:不受影响,openEuler-22.03-LTS-SP4:不受影响,openEuler-24.03-LTS-Next:不受影响,openEuler-24.03-LTS-SP1:不受影响,openEuler-24.03-LTS-SP3:不受影响,openEuler-24.03-LTS-SP4:不受影响
已分析 5.是否涉及abi变化 master:否,openEuler-20.03-LTS-SP4:否,openEuler-22.03-LTS-SP4:否,openEuler-24.03-LTS-Next:否,openEuler-24.03-LTS-SP1:否,openEuler-24.03-LTS-SP3:否,openEuler-24.03-LTS-SP4:否
已分析 6.原因说明 master:正常修复,openEuler-20.03-LTS-SP4:不受影响-漏洞代码不存在,openEuler-22.03-LTS-SP4:不受影响-漏洞代码不存在,openEuler-24.03-LTS-Next:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP1:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP3:不受影响-漏洞代码不存在,openEuler-24.03-LTS-SP4:不受影响-漏洞代码不存在

请确认分析内容的准确性, 确认无误后, 您可以进行后续步骤, 否则您可以继续分析.

likedislike
openeuler-ci-bot
openeuler-ci-botCollaborators
26 days ago Comments:

经过cve-manager解析,(所有PR均已合入)

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago changed custom state from 进行中 to 已完成
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago Close issue
openeuler-ci-bot
openeuler-ci-botCollaborators
26 days ago Comments:

经过cve-manager解析,(所有PR均已合入)

likedislike
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago Removed label: CVE/UNFIXED
openeuler-ci-botopeneuler-ci-botCollaborators
26 days ago Added label: CVE/FIXED