Skip to content

Algo examples - #610

Open
aidankeefe2022 wants to merge 16 commits into
wolfSSL:masterfrom
aidankeefe2022:algo_examples
Open

Algo examples#610
aidankeefe2022 wants to merge 16 commits into
wolfSSL:masterfrom
aidankeefe2022:algo_examples

Conversation

@aidankeefe2022

@aidankeefe2022 aidankeefe2022 commented Jul 29, 2026

Copy link
Copy Markdown
Member

New Examples

  • SLH-DSA
  • SM2/SM3/SM4
  • Blake2b/Blake2s
  • KDF
  • HPKE seal/open example
  • SRP-6a SHA-256 example
  • ECCSI + SAKKE example

Revisions on the AI generated examples

Changed the peer to peer/ client server examples to represent the different actors as structs ie. Alice struct and Bob struct to show how data moves and what information is used for each task.

Also added comments to spell out each step using boxing style for the more complex examples
Example:

/* --- Thing is happening --- *
{
      Thing happens
}
/* ---Thing is happening --- */

anhu and others added 15 commits July 29, 2026 13:38
Key generation, signing and verification for all SHAKE and SHA2
parameter sets, with corrupted-signature rejection.
wolfCrypt-level ShangMi examples: SM3 hash (GB/T 32905 known answer),
SM4-GCM with tamper detection, SM2 sign/verify including the ZA digest
step, and SM2 ECDH. Requires the wolfSSL/wolfsm overlay.
Incremental hashing checked against the RFC 7693 known-answer vectors,
plus BLAKE2b's native keyed mode used as a MAC.
SipHash-2-4 one-shot 64/128-bit MACs and the incremental API, checked
against the reference implementation's test vector.
HKDF (RFC 5869), PBKDF2 (RFC 2898) and scrypt (RFC 7914), each
verified against its RFC known-answer test vector.
One KEM encapsulation protecting an ordered message sequence via
wc_HpkeInitSealContext()/wc_HpkeContextSealBase() and the open
equivalents, with out-of-order rejection.
Full exchange (enrollment through mutual proof verification) using
SHA-256 and the RFC 5054 2048-bit group.
Identity-based key exchange per RFC 6507-6509: KMS provisions user key
material, ECCSI signs the SAKKE-encapsulated SSV, receiver verifies
and derives the shared secret.
Add check entries for slh_dsa, blake2, siphash, kdf and mikey-sakke;
extend the crypto, pq and pk profiles with their configure flags.
crypto/sm is a documented skip: it needs the wolfsm overlay patched
into the wolfSSL tree before configure.
@aidankeefe2022 aidankeefe2022 self-assigned this Jul 29, 2026
@aidankeefe2022
aidankeefe2022 marked this pull request as ready for review July 30, 2026 16:30

@wolfSSL-Fenrir-bot wolfSSL-Fenrir-bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fenrir Automated Review — PR #610

Scan targets checked: wolfssl-examples-bugs, wolfssl-examples-src

Findings: 3
3 finding(s) posted as inline comments (see file-level comments below)

This review was generated automatically by Fenrir. Findings are non-blocking.

Comment thread pq/slh_dsa/slh_dsa.c Outdated
Comment thread hash/blake2/blake2-keyed-mac.c
Comment thread pk/srp/srp_sha256.c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants