All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.dyadicsec.provider.EDDSAKeyPairGenerator Maven / Gradle / Ivy

Go to download

This is a collection of JAVA libraries that implement Unbound cryptographic classes for JAVA provider, PKCS11 wrapper, cryptoki, and advapi

There is a newer version: 42761
Show newest version
package com.dyadicsec.provider;

import com.unbound.client.Partition;
import com.unbound.provider.UBEDDSAKeyPairGenerator;
import com.unbound.provider.UBEDDSAPublicKey;

import java.security.KeyPair;

public class EDDSAKeyPairGenerator
{
  final UBEDDSAKeyPairGenerator gen;

  public EDDSAKeyPairGenerator()
  {
    gen = new UBEDDSAKeyPairGenerator(Partition.getDefault());
  }

  public KeyPair generateKeyPair()
  {
    KeyPair kp = gen.generateKeyPair();
    EDDSAPublicKey pub = new EDDSAPublicKey((UBEDDSAPublicKey)kp.getPrivate());
    return new KeyPair(pub, kp.getPrivate());
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy