3.6.3 Ed25519
All Application Manual Name SummaryHelp

  • Documentation
    • Reference manual
    • Packages
      • SWI-Prolog SSL Interface
        • library(crypto): Cryptography and authentication library
          • Digital signatures
            • Ed25519
              • ed25519_new_keypair/1
              • ed25519_seed_keypair/2
              • ed25519_keypair_public_key/2
              • ed25519_sign/4
              • ed25519_verify/4
Availability::- use_module(library(crypto)).(can be autoloaded)
Source[det]ed25519_seed_keypair(+Seed, -KeyPair)
Deterministically derive an Ed25519 key pair from Seed, 32 arbitrary bytes. Seed can be chosen at random using crypto_n_random_bytes/2 or derived from input keying material using crypto_data_hkdf/4.

KeyPair is a hexadecimal atom denoting the key pair in PKCS#8 v2 format (RFC 5958, RFC 8410), the format also used by openssl genpkey -algorithm ed25519. It contains the private key and must be kept absolutely secret. It can be used for signing with ed25519_sign/4, and its public key is obtained with ed25519_keypair_public_key/2.