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

com.dyadicsec.pkcs11.Slot 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.pkcs11;

import com.unbound.client.Partition;
import com.unbound.client.pkcs11.PKCS11Partition;

import java.security.ProviderException;

public class Slot
{
  final Partition partition;

  private Slot(Partition partition)
  {
    this.partition = partition;
  }

  static public Slot find(String partitionName)
  {
    return new Slot(Partition.get(partitionName));
  }

  public int getID()
  {
    if (partition instanceof PKCS11Partition) return ((PKCS11Partition)partition).getSlotId();
    throw new ProviderException("Not implemented");
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy