Repository navigation
[UTXO-BUG] Critical Security Vulnerabilities - Genesis Race & Integer Overflow - #2165
Merged
Merged
Conversation
- test_genesis_race.py: Race condition in genesis migration (100 RTC) * Demonstrates fund duplication via concurrent migration * Vulnerability: check_existing_genesis() outside transaction - test_integer_overflow.py: Integer overflow DoS (50 RTC) * Tests fee_nrtc overflow * Tests timestamp overflow * Tests negative fee (fund creation) Total bounty: 150 RTC (100 + 50)
Contributor
|
Welcome to RustChain! Thanks for your first pull request. Before we review, please make sure:
Bounty tiers: Micro (1-10 RTC) | Standard (20-50) | Major (75-100) | Critical (100-150) A maintainer will review your PR soon. Thanks for contributing! |
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.
漏洞摘要
本PR包含2个关键安全漏洞的失败测试用例:
🔴 漏洞 #1: 创世迁移竞态条件 (100 RTC)
严重程度: Critical
文件:
node/utxo_genesis_migration.py问题:
check_existing_genesis()在事务外调用,可导致资金复制攻击向量:
测试文件:
node/test_genesis_race.py修复建议: 将检查移到事务内
🟠 漏洞 #2: 整数溢出DoS (50 RTC)
严重程度: High
文件:
node/utxo_db.py问题: 缺少
fee_nrtc和timestamp范围检查攻击向量:
测试文件:
node/test_integer_overflow.py修复建议: 添加整数范围验证
📊 总计
漏洞数量: 2
总赏金: 150 RTC (100 + 50)
测试状态: 失败(需要修复)
🔍 运行测试
cd node python3 test_genesis_race.py python3 test_integer_overflow.py📝 相关 Issue
联系方式
审计者: 小米辣 🌶️
审计日期: 2026-04-07
报告: 见测试文件详细文档