Files
wolfssl/IDE/INTIME-RTOS
Tobias Frauenschläger fb6b62dd8e Rename Dilithium to canonical ML-DSA (FIPS 204) names
NIST standardized the pre-standardization Dilithium signature scheme as
ML-DSA in FIPS 204. Migrate the provider's user-visible surface to
canonical spellings, with a temporary shim that preserves source-level
backward compatibility for existing consumers.

Renames
-------
* File: wolfcrypt/src/dilithium.c -> wolfcrypt/src/wc_mldsa.c
* New canonical header: wolfssl/wolfcrypt/wc_mldsa.h
* Types: dilithium_key -> MlDsaKey, wc_dilithium_params -> MlDsaParams
* Functions: wc_dilithium_* / wc_Dilithium_* -> wc_MlDsaKey_*
* Build gates: HAVE_DILITHIUM -> WOLFSSL_HAVE_MLDSA,
  WOLFSSL_DILITHIUM_* / WC_DILITHIUM_* -> WOLFSSL_MLDSA_* / WC_MLDSA_*
* Configure flag: --enable-mldsa (legacy --enable-dilithium still works)
* CMake option: WOLFSSL_MLDSA (legacy WOLFSSL_DILITHIUM emits a
  DEPRECATION message)

Backward compatibility
----------------------
wolfssl/wolfcrypt/dilithium.h is now a temporary compatibility shim:
* Forward-translates legacy build gates to canonical (the two sub-gates
  read by certs_test.h are translated in settings.h so the auto-generated
  header is reachable without including dilithium.h; the remainder lives
  in dilithium.h itself).
* Reverse-translates canonical gates back to legacy so unmigrated
  consumer code keying off HAVE_DILITHIUM / WOLFSSL_DILITHIUM_* keeps
  compiling.
* Provides macro / static-inline aliases for the legacy type and
  function names so source-level callers compile unchanged. Sets
  WC_DILITHIUMKEY_TYPE_DEFINED to suppress strict-C99 typedef
  redefinition in asn_public.h.

Two opt-outs are honored: WOLFSSL_NO_DILITHIUM_LEGACY_GATES disables
build-gate translation; WOLFSSL_NO_DILITHIUM_LEGACY_NAMES disables the
symbol aliases. Both are temporary and the shim will be removed in a
future release. doc/dilithium-to-mldsa-migration.md describes the
migration path for downstream consumers.

ABI note
--------
The library now exports wc_MlDsaKey_* instead of wc_dilithium_*.
Pre-built binaries that linked against the legacy symbols need to
recompile against the shim header (which resolves to the new symbols at
compile time) or migrate to the canonical names directly. Source code
keeps building unchanged.

Other changes
-------------
* wolfssl/wolfcrypt/memory.h: drop ML-DSA sub-gate branching for static
  memory pool sizing; WOLFSSL_HAVE_MLDSA builds now pick the larger
  LARGEST_MEM_BUCKET / WOLFMEM_BUCKETS / WOLFMEM_DIST unconditionally.
  Override these macros for small-mem builds.
* gencertbuf.pl + wolfssl/certs_test.h: outer guards migrated to the
  canonical WOLFSSL_HAVE_MLDSA spelling.
* tests/api/test_mldsa.c: adds compile-time API surface validators
  (canonical wc_MlDsaKey_* surface plus legacy alias surface) so
  signature drift produces a build error during make check.
* IDE files (Xcode, INTIME-RTOS, WIN10, VS2022, CSharp wrapper), Zephyr
  CMakeLists.txt, and autotools include.am updated for the rename.
* DYNAMIC_TYPE_DILITHIUM and ML_DSA_PCT_E retained as internal symbols;
  scheduled to be renamed alongside the eventual shim removal.
2026-05-16 09:48:35 -05:00
..
2025-09-09 11:56:10 -05:00
2025-09-08 13:20:13 -05:00
2025-09-08 13:20:13 -05:00
2025-09-05 16:23:26 -05:00

tenAsys INtime RTOS Port

Overview

This port is for the tenAsys INtime RTOS available here.

To enable use the define INTIME_RTOS.

Usage

The wolfExamples.sln is a Visual Studio 2015 project. You must have the INtime SDK installed and an INtime RTOS agent running.

The default configuration is set inside the IDE/INTIME-RTOS/user_settings.h file.

The example application provides a simple menu interface to select difference application functions to test.

wolfExamples started
wolfExamples finished initialization

                                MENU

        t. WolfCrypt Test
        b. WolfCrypt Benchmark
        c. WolfSSL Client Example
        s. WolfSSL Server Example
        l. WolfSSL Localhost Client/Server Example
Please select one of the above options:

twolfCrypt Test

Performs testing of all crypto algorithms.

Crypt Test
error    test passed!
base64   test passed!
base64   test passed!
MD5      test passed!
SHA      test passed!
SHA-256  test passed!
SHA-384  test passed!
SHA-512  test passed!
Hash     test passed!
HMAC-MD5 test passed!
HMAC-SHA test passed!
HMAC-SHA256 test passed!
HMAC-SHA384 test passed!
HMAC-SHA512 test passed!
HMAC-KDF    test passed!
X963-KDF    test passed!
GMAC     test passed!
Chacha   test passed!
POLY1305 test passed!
ChaCha20-Poly1305 AEAD test passed!
DES      test passed!
DES3     test passed!
AES      test passed!
AES-GCM  test passed!
AES-CCM  test passed!
AES Key Wrap test passed!
RANDOM   test passed!
RSA      test passed!
DH       test passed!
DSA      test passed!
SRP      test passed!
PWDBASED test passed!
openSSL extra test
OPENSSL  test passed!
ECC      test passed!
ECC Enc  test passed!
ECC buffer test passed!
CURVE25519 test passed!
ED25519  test passed!
CMAC     test passed!
PKCS7enveloped test passed!
PKCS7signed    test passed!
PKCS7encrypted test passed!
mutex    test passed!
memcb    test passed!
Crypt Test: Return code 0

b wolfCrypt Benchmark

Performs benchmark of crypto algorithms.

Benchmark Test
RNG      25 kB took 0.002 seconds,   11.017 MB/s
AES enc  25 kB took 0.002 seconds,   15.090 MB/s
AES dec  25 kB took 0.002 seconds,   15.119 MB/s
AES-GCM  25 kB took 0.003 seconds,    9.433 MB/s
AES-CTR  25 kB took 0.001 seconds,   22.378 MB/s
AES-CCM  25 kB took 0.002 seconds,   15.306 MB/s
CHACHA   25 kB took 0.002 seconds,   16.063 MB/s
CHA-POLY 25 kB took 0.001 seconds,   20.447 MB/s
3DES     25 kB took 0.002 seconds,   10.717 MB/s

MD5      25 kB took  0.00 seconds,   31.576 MB/s
POLY1305 25 kB took 0.000 seconds,  201.575 MB/s
SHA      25 kB took  0.00 seconds,   43.761 MB/s
SHA-256  25 kB took 0.001 seconds,   19.299 MB/s
SHA-384  25 kB took 0.002 seconds,   14.577 MB/s
SHA-512  25 kB took 0.001 seconds,   21.718 MB/s
AES-CMAC 25 kB took  0.00 seconds,   34.925 MB/s

RSA 2048 public           2.445 milliseconds, avg over 1 iterations
RSA 2048 private         64.711 milliseconds, avg over 1 iterations

RSA 1024 key generation  318.755 milliseconds, avg over 5 iterations
RSA 2048 key generation  22648.396 milliseconds, avg over 5 iterations
DH  2048 key generation  23.119 milliseconds, avg over 1 iterations
DH  2048 key agreement   26.756 milliseconds, avg over 1 iterations

ECC  256 key generation   2.984 milliseconds, avg over 5 iterations
EC-DHE   key agreement    2.967 milliseconds, avg over 5 iterations
EC-DSA   sign   time      1.448 milliseconds, avg over 5 iterations
EC-DSA   verify time      3.304 milliseconds, avg over 5 iterations
ECC      encrypt          5.860 milliseconds, avg over 1 iterations
ECC      decrypt          6.360 milliseconds, avg over 1 iterations

CURVE25519 256 key generation  1.416 milliseconds, avg over 5 iterations
CURVE25519 key agreement       1.332 milliseconds, avg over 5 iterations

ED25519  key generation   0.320 milliseconds, avg over 5 iterations
ED25519  sign   time      0.595 milliseconds, avg over 5 iterations
ED25519  verify time      1.310 milliseconds, avg over 5 iterations
Benchmark Test: Return code 0

c wolfSSL Client

To configure the host address and port modify the TLS_HOST_REMOTE and TLS_PORT macros at top of wolfExamples.c. This example uses TLS 1.2 to connect to a remote host.

s wolfSSL Server

To configure the port to listen on modify TLS_PORT at top of wolfExamples.c.

l wolfSSL Localhost Server/Client

Starts a TLS server thread listening on localhost. Starts the TLS client and performs connect, exchanges some data and disconnects.

Waiting for a connection...
Client connected successfully
Using Non-Blocking I/O: 0
Message for server:     Client:

Received:       I hear ya fa shizzle!

The client has closed the connection.

References

For more information please contact info@wolfssl.com.