Files
huangxt 21e7e65b32 添加 GitHub Pages 文档与 CI 修复
新增功能:
- docs/ 目录:GitHub Pages 静态页面
  - index.html:项目主页
  - og-image.png/svg:社交分享图片
- tests/rustls_provider.rs:rustls CryptoProvider 集成测试
- rustls_provider 模块增强:
  - hash.rs:新增测试和文档
  - hmac.rs:新增测试和文档
  - kx.rs:新增测试和文档
  - sign.rs:新增测试和文档
  - verify.rs:新增测试和文档

CI 修复:
- rustls 依赖改为 git 源,避免本地路径依赖问题
- 简化 SM3 HMAC 流式测试,移除 alloc 依赖
- 移除未使用的 extern crate alloc
- 代码格式化

文档更新:
- README.md:添加 GitHub Pages 链接
- CHANGELOG.md:更新变更记录
- Cargo.toml:添加 dev-dependencies
2026-03-09 18:51:40 +08:00

165 lines
8.3 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="630" viewBox="0 0 1200 630">
<defs>
<!-- Background gradient -->
<linearGradient id="bg" x1="0" y1="0" x2="1" y2="1">
<stop offset="0%" stop-color="#0f172a"/>
<stop offset="100%" stop-color="#1e293b"/>
</linearGradient>
<!-- Brand accent glow -->
<radialGradient id="glow" cx="0.25" cy="0.5" r="0.5">
<stop offset="0%" stop-color="#dea584" stop-opacity="0.12"/>
<stop offset="100%" stop-color="#dea584" stop-opacity="0"/>
</radialGradient>
<!-- Green glow -->
<radialGradient id="glowGreen" cx="0.75" cy="0.6" r="0.4">
<stop offset="0%" stop-color="#10b981" stop-opacity="0.08"/>
<stop offset="100%" stop-color="#10b981" stop-opacity="0"/>
</radialGradient>
</defs>
<!-- Background -->
<rect width="1200" height="630" fill="url(#bg)"/>
<rect width="1200" height="630" fill="url(#glow)"/>
<rect width="1200" height="630" fill="url(#glowGreen)"/>
<!-- Subtle grid pattern -->
<g opacity="0.03" stroke="#ffffff" stroke-width="0.5">
<line x1="0" y1="0" x2="0" y2="630" transform="translate(60,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(120,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(180,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(240,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(300,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(360,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(420,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(480,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(540,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(600,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(660,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(720,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(780,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(840,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(900,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(960,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(1020,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(1080,0)"/>
<line x1="0" y1="0" x2="0" y2="630" transform="translate(1140,0)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,60)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,120)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,180)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,240)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,300)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,360)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,420)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,480)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,540)"/>
<line x1="0" y1="0" x2="1200" y2="0" transform="translate(0,600)"/>
</g>
<!-- ========== PANDA (right side) ========== -->
<g transform="translate(880, 200)">
<!-- Left ear (black) -->
<ellipse cx="60" cy="30" rx="52" ry="48" fill="#1a1a2e"/>
<ellipse cx="60" cy="30" rx="42" ry="38" fill="#2d2d44"/>
<!-- Right ear (black) -->
<ellipse cx="220" cy="30" rx="52" ry="48" fill="#1a1a2e"/>
<ellipse cx="220" cy="30" rx="42" ry="38" fill="#2d2d44"/>
<!-- Head (white/light) -->
<ellipse cx="140" cy="120" rx="120" ry="110" fill="#e8e8ef"/>
<ellipse cx="140" cy="120" rx="120" ry="110" fill="none" stroke="#d0d0dd" stroke-width="1"/>
<!-- Left eye patch (dark) -->
<ellipse cx="90" cy="105" rx="42" ry="35" fill="#1a1a2e" transform="rotate(-10, 90, 105)"/>
<!-- Right eye patch (dark) -->
<ellipse cx="190" cy="105" rx="42" ry="35" fill="#1a1a2e" transform="rotate(10, 190, 105)"/>
<!-- Left eye (white + pupil) -->
<ellipse cx="92" cy="108" rx="16" ry="18" fill="#ffffff"/>
<ellipse cx="95" cy="110" rx="9" ry="10" fill="#1a1a2e"/>
<ellipse cx="97" cy="107" rx="3" ry="3.5" fill="#ffffff"/>
<!-- Right eye (white + pupil) -->
<ellipse cx="188" cy="108" rx="16" ry="18" fill="#ffffff"/>
<ellipse cx="185" cy="110" rx="9" ry="10" fill="#1a1a2e"/>
<ellipse cx="183" cy="107" rx="3" ry="3.5" fill="#ffffff"/>
<!-- Nose -->
<ellipse cx="140" cy="140" rx="12" ry="8" fill="#2d2d44"/>
<!-- Mouth -->
<path d="M 128 150 Q 134 160 140 152 Q 146 160 152 150" fill="none" stroke="#2d2d44" stroke-width="2.5" stroke-linecap="round"/>
<!-- Blush (brand color) -->
<ellipse cx="72" cy="135" rx="18" ry="11" fill="#dea584" opacity="0.3"/>
<ellipse cx="208" cy="135" rx="18" ry="11" fill="#dea584" opacity="0.3"/>
<!-- Shield body (panda is holding a shield) -->
<g transform="translate(85, 175)">
<!-- Shield shape -->
<path d="M 55 0 L 105 12 L 105 60 Q 105 100 55 115 Q 5 100 5 60 L 5 12 Z" fill="#1e293b" stroke="#dea584" stroke-width="2.5"/>
<!-- Lock icon on shield -->
<rect x="38" y="42" width="34" height="28" rx="4" fill="#dea584" opacity="0.9"/>
<path d="M 45 42 L 45 34 Q 45 22 55 22 Q 65 22 65 34 L 65 42" fill="none" stroke="#dea584" stroke-width="3" stroke-linecap="round" opacity="0.9"/>
<circle cx="55" cy="54" r="4" fill="#0f172a"/>
<rect x="53" y="56" width="4" height="8" rx="1" fill="#0f172a"/>
</g>
<!-- Paws holding shield -->
<ellipse cx="72" cy="210" rx="22" ry="16" fill="#1a1a2e"/>
<ellipse cx="208" cy="210" rx="22" ry="16" fill="#1a1a2e"/>
</g>
<!-- ========== TEXT (left side) ========== -->
<!-- Brand name -->
<text x="80" y="175" font-family="monospace, 'Courier New'" font-size="72" font-weight="900" fill="#ffffff" letter-spacing="-2">
<tspan fill="#dea584">&lt;/&gt;</tspan> libsmx
</text>
<!-- Tagline -->
<text x="80" y="230" font-family="sans-serif, Arial, Helvetica" font-size="28" fill="#94a3b8" letter-spacing="0.5">
Pure-Rust Chinese Cryptography
</text>
<!-- Feature badges -->
<!-- Badge: Zero unsafe -->
<g transform="translate(80, 270)">
<rect width="180" height="40" rx="20" fill="#ef4444" fill-opacity="0.12" stroke="#ef4444" stroke-opacity="0.3" stroke-width="1"/>
<text x="90" y="26" font-family="monospace, 'Courier New'" font-size="15" fill="#fca5a5" text-anchor="middle" font-weight="600">Zero unsafe</text>
</g>
<!-- Badge: Constant-time -->
<g transform="translate(280, 270)">
<rect width="200" height="40" rx="20" fill="#10b981" fill-opacity="0.12" stroke="#10b981" stroke-opacity="0.3" stroke-width="1"/>
<text x="100" y="26" font-family="monospace, 'Courier New'" font-size="15" fill="#6ee7b7" text-anchor="middle" font-weight="600">Constant-time</text>
</g>
<!-- Badge: #![no_std] -->
<g transform="translate(500, 270)">
<rect width="170" height="40" rx="20" fill="#3b82f6" fill-opacity="0.12" stroke="#3b82f6" stroke-opacity="0.3" stroke-width="1"/>
<text x="85" y="26" font-family="monospace, 'Courier New'" font-size="15" fill="#93c5fd" text-anchor="middle" font-weight="600">#![no_std]</text>
</g>
<!-- Algorithm list -->
<text x="80" y="365" font-family="monospace, 'Courier New'" font-size="20" fill="#64748b">
<tspan fill="#dea584">SM2</tspan> · <tspan fill="#dea584">SM3</tspan> · <tspan fill="#dea584">SM4</tspan> · <tspan fill="#dea584">SM9</tspan> · <tspan fill="#dea584">BLS</tspan> · <tspan fill="#dea584">FPE</tspan>
</text>
<!-- Performance highlights -->
<g transform="translate(80, 400)">
<text font-family="sans-serif, Arial, Helvetica" font-size="16" fill="#64748b">
<tspan x="0" dy="0">SM3 <tspan fill="#10b981" font-weight="700">374 MiB/s</tspan></tspan>
<tspan x="200" dy="0">SM2 Sign <tspan fill="#10b981" font-weight="700">258 µs</tspan></tspan>
<tspan x="430" dy="0">SM4 <tspan fill="#10b981" font-weight="700">27 MiB/s</tspan></tspan>
</text>
</g>
<!-- Decorative bottom line -->
<rect x="0" y="625" width="1200" height="5" fill="url(#bg)"/>
<line x1="0" y1="626" x2="1200" y2="626" stroke="#dea584" stroke-opacity="0.3" stroke-width="1"/>
<!-- Bottom bar: URL -->
<text x="80" y="580" font-family="monospace, 'Courier New'" font-size="16" fill="#475569">
github.com/kintaiW/libsmx
</text>
</svg>