Botan  2.7.0
Crypto and TLS for C++11
Classes | Typedefs | Enumerations | Functions | Variables
Botan::PKCS11 Namespace Reference

Classes

class  AttributeContainer
 Helper class to build the Attribute / CK_ATTRIBUTE structures. More...
 
class  CertificateProperties
 Common attributes of all certificate objects. More...
 
class  DataObjectProperties
 Common attributes of all data objects. More...
 
class  DomainParameterProperties
 Common attributes of domain parameter. More...
 
class  KeyProperties
 Common attributes of all key objects. More...
 
class  LowLevel
 Provides access to all PKCS#11 functions. More...
 
class  MechanismWrapper
 
class  Module
 
class  Object
 
class  ObjectFinder
 Manages calls to C_FindObjects* functions (C_FindObjectsInit -> C_FindObjects -> C_FindObjectsFinal) More...
 
class  ObjectProperties
 Common attributes of all objects. More...
 
class  PKCS11_Error
 
class  PKCS11_ReturnError
 
class  PKCS11_RNG
 A random generator that only fetches random from the PKCS#11 RNG. More...
 
class  PrivateKeyProperties
 Common attributes of all private keys. More...
 
class  PublicKeyProperties
 Common attributes of all public key objects. More...
 
class  SecretKeyProperties
 Common attributes of all secret (symmetric) keys. More...
 
class  Session
 Represents a PKCS#11 session. More...
 
class  Slot
 Represents a PKCS#11 Slot, i.e., a card reader. More...
 
class  StorageObjectProperties
 Common attributes of all storage objects. More...
 

Typedefs

using Attribute = CK_ATTRIBUTE
 
using Bbool = CK_BBOOL
 
using Byte = CK_BYTE
 
using C_InitializeArgs = CK_C_INITIALIZE_ARGS
 
using CreateMutex = CK_CREATEMUTEX
 
using Date = CK_DATE
 
using DestroyMutex = CK_DESTROYMUTEX
 
using Ecdh1DeriveParams = CK_ECDH1_DERIVE_PARAMS
 
using Flags = CK_FLAGS
 
using FunctionListPtr = CK_FUNCTION_LIST_PTR
 
using Info = CK_INFO
 
using LockMutex = CK_LOCKMUTEX
 
using Mechanism = CK_MECHANISM
 
using MechanismInfo = CK_MECHANISM_INFO
 
using Notify = CK_NOTIFY
 
using ObjectHandle = CK_OBJECT_HANDLE
 
using RsaPkcsOaepParams = CK_RSA_PKCS_OAEP_PARAMS
 
using RsaPkcsPssParams = CK_RSA_PKCS_PSS_PARAMS
 
using secure_string = secure_vector< uint8_t >
 
using SessionHandle = CK_SESSION_HANDLE
 
using SessionInfo = CK_SESSION_INFO
 
using SlotId = CK_SLOT_ID
 
using SlotInfo = CK_SLOT_INFO
 
using TokenInfo = CK_TOKEN_INFO
 
using Ulong = CK_ULONG
 
using UnlockMutex = CK_UNLOCKMUTEX
 
using Utf8Char = CK_UTF8CHAR
 
using VoidPtr = CK_VOID_PTR
 

Enumerations

enum  AttributeType : CK_ATTRIBUTE_TYPE {
  AttributeType::Class = 0x00000000UL, AttributeType::Token = 0x00000001UL, AttributeType::Private = 0x00000002UL, AttributeType::Label = 0x00000003UL,
  AttributeType::Application = 0x00000010UL, AttributeType::Value = 0x00000011UL, AttributeType::ObjectId = 0x00000012UL, AttributeType::CertificateType = 0x00000080UL,
  AttributeType::Issuer = 0x00000081UL, AttributeType::SerialNumber = 0x00000082UL, AttributeType::AcIssuer = 0x00000083UL, AttributeType::Owner = 0x00000084UL,
  AttributeType::AttrTypes = 0x00000085UL, AttributeType::Trusted = 0x00000086UL, AttributeType::CertificateCategory = 0x00000087UL, AttributeType::JavaMidpSecurityDomain = 0x00000088UL,
  AttributeType::Url = 0x00000089UL, AttributeType::HashOfSubjectPublicKey = 0x0000008AUL, AttributeType::HashOfIssuerPublicKey = 0x0000008BUL, AttributeType::NameHashAlgorithm = 0x0000008CUL,
  AttributeType::CheckValue = 0x00000090UL, AttributeType::KeyType = 0x00000100UL, AttributeType::Subject = 0x00000101UL, AttributeType::Id = 0x00000102UL,
  AttributeType::Sensitive = 0x00000103UL, AttributeType::Encrypt = 0x00000104UL, AttributeType::Decrypt = 0x00000105UL, AttributeType::Wrap = 0x00000106UL,
  AttributeType::Unwrap = 0x00000107UL, AttributeType::Sign = 0x00000108UL, AttributeType::SignRecover = 0x00000109UL, AttributeType::Verify = 0x0000010AUL,
  AttributeType::VerifyRecover = 0x0000010BUL, AttributeType::Derive = 0x0000010CUL, AttributeType::StartDate = 0x00000110UL, AttributeType::EndDate = 0x00000111UL,
  AttributeType::Modulus = 0x00000120UL, AttributeType::ModulusBits = 0x00000121UL, AttributeType::PublicExponent = 0x00000122UL, AttributeType::PrivateExponent = 0x00000123UL,
  AttributeType::Prime1 = 0x00000124UL, AttributeType::Prime2 = 0x00000125UL, AttributeType::Exponent1 = 0x00000126UL, AttributeType::Exponent2 = 0x00000127UL,
  AttributeType::Coefficient = 0x00000128UL, AttributeType::PublicKeyInfo = 0x00000129UL, AttributeType::Prime = 0x00000130UL, AttributeType::Subprime = 0x00000131UL,
  AttributeType::Base = 0x00000132UL, AttributeType::PrimeBits = 0x00000133UL, AttributeType::SubprimeBits = 0x00000134UL, AttributeType::SubPrimeBits = 0x00000134UL,
  AttributeType::ValueBits = 0x00000160UL, AttributeType::ValueLen = 0x00000161UL, AttributeType::Extractable = 0x00000162UL, AttributeType::Local = 0x00000163UL,
  AttributeType::NeverExtractable = 0x00000164UL, AttributeType::AlwaysSensitive = 0x00000165UL, AttributeType::KeyGenMechanism = 0x00000166UL, AttributeType::Modifiable = 0x00000170UL,
  AttributeType::Copyable = 0x00000171UL, AttributeType::Destroyable = 0x00000172UL, AttributeType::EcdsaParams = 0x00000180UL, AttributeType::EcParams = 0x00000180UL,
  AttributeType::EcPoint = 0x00000181UL, AttributeType::SecondaryAuth = 0x00000200UL, AttributeType::AuthPinFlags = 0x00000201UL, AttributeType::AlwaysAuthenticate = 0x00000202UL,
  AttributeType::WrapWithTrusted = 0x00000210UL, AttributeType::WrapTemplate = ( 0x40000000UL |0x00000211UL), AttributeType::UnwrapTemplate = ( 0x40000000UL |0x00000212UL), AttributeType::DeriveTemplate = ( 0x40000000UL |0x00000213UL),
  AttributeType::OtpFormat = 0x00000220UL, AttributeType::OtpLength = 0x00000221UL, AttributeType::OtpTimeInterval = 0x00000222UL, AttributeType::OtpUserFriendlyMode = 0x00000223UL,
  AttributeType::OtpChallengeRequirement = 0x00000224UL, AttributeType::OtpTimeRequirement = 0x00000225UL, AttributeType::OtpCounterRequirement = 0x00000226UL, AttributeType::OtpPinRequirement = 0x00000227UL,
  AttributeType::OtpCounter = 0x0000022EUL, AttributeType::OtpTime = 0x0000022FUL, AttributeType::OtpUserIdentifier = 0x0000022AUL, AttributeType::OtpServiceIdentifier = 0x0000022BUL,
  AttributeType::OtpServiceLogo = 0x0000022CUL, AttributeType::OtpServiceLogoType = 0x0000022DUL, AttributeType::Gostr3410Params = 0x00000250UL, AttributeType::Gostr3411Params = 0x00000251UL,
  AttributeType::Gost28147Params = 0x00000252UL, AttributeType::HwFeatureType = 0x00000300UL, AttributeType::ResetOnInit = 0x00000301UL, AttributeType::HasReset = 0x00000302UL,
  AttributeType::PixelX = 0x00000400UL, AttributeType::PixelY = 0x00000401UL, AttributeType::Resolution = 0x00000402UL, AttributeType::CharRows = 0x00000403UL,
  AttributeType::CharColumns = 0x00000404UL, AttributeType::Color = 0x00000405UL, AttributeType::BitsPerPixel = 0x00000406UL, AttributeType::CharSets = 0x00000480UL,
  AttributeType::EncodingMethods = 0x00000481UL, AttributeType::MimeTypes = 0x00000482UL, AttributeType::MechanismType = 0x00000500UL, AttributeType::RequiredCmsAttributes = 0x00000501UL,
  AttributeType::DefaultCmsAttributes = 0x00000502UL, AttributeType::SupportedCmsAttributes = 0x00000503UL, AttributeType::AllowedMechanisms = ( 0x40000000UL |0x00000600UL), AttributeType::VendorDefined = 0x80000000UL
}
 
enum  CertificateCategory : CK_ULONG { CertificateCategory::Unspecified = 0UL, CertificateCategory::TokenUser = 1UL, CertificateCategory::Authority = 2UL, CertificateCategory::OtherEntity = 3UL }
 
enum  CertificateType : CK_CERTIFICATE_TYPE { CertificateType::X509 = 0x00000000UL, CertificateType::X509AttrCert = 0x00000001UL, CertificateType::Wtls = 0x00000002UL, CertificateType::VendorDefined = 0x80000000UL }
 
enum  Flag : CK_FLAGS {
  Flag::None = 0, Flag::TokenPresent = 0x00000001UL, Flag::RemovableDevice = 0x00000002UL, Flag::HwSlot = 0x00000004UL,
  Flag::Rng = 0x00000001UL, Flag::WriteProtected = 0x00000002UL, Flag::LoginRequired = 0x00000004UL, Flag::UserPinInitialized = 0x00000008UL,
  Flag::RestoreKeyNotNeeded = 0x00000020UL, Flag::ClockOnToken = 0x00000040UL, Flag::ProtectedAuthenticationPath = 0x00000100UL, Flag::DualCryptoOperations = 0x00000200UL,
  Flag::TokenInitialized = 0x00000400UL, Flag::SecondaryAuthentication = 0x00000800UL, Flag::UserPinCountLow = 0x00010000UL, Flag::UserPinFinalTry = 0x00020000UL,
  Flag::UserPinLocked = 0x00040000UL, Flag::UserPinToBeChanged = 0x00080000UL, Flag::SoPinCountLow = 0x00100000UL, Flag::SoPinFinalTry = 0x00200000UL,
  Flag::SoPinLocked = 0x00400000UL, Flag::SoPinToBeChanged = 0x00800000UL, Flag::ErrorState = 0x01000000UL, Flag::RwSession = 0x00000002UL,
  Flag::SerialSession = 0x00000004UL, Flag::ArrayAttribute = 0x40000000UL, Flag::Hw = 0x00000001UL, Flag::Encrypt = 0x00000100UL,
  Flag::Decrypt = 0x00000200UL, Flag::Digest = 0x00000400UL, Flag::Sign = 0x00000800UL, Flag::SignRecover = 0x00001000UL,
  Flag::Verify = 0x00002000UL, Flag::VerifyRecover = 0x00004000UL, Flag::Generate = 0x00008000UL, Flag::GenerateKeyPair = 0x00010000UL,
  Flag::Wrap = 0x00020000UL, Flag::Unwrap = 0x00040000UL, Flag::Derive = 0x00080000UL, Flag::EcFP = 0x00100000UL,
  Flag::EcF2m = 0x00200000UL, Flag::EcEcparameters = 0x00400000UL, Flag::EcNamedcurve = 0x00800000UL, Flag::EcUncompress = 0x01000000UL,
  Flag::EcCompress = 0x02000000UL, Flag::Extension = 0x80000000UL, Flag::LibraryCantCreateOsThreads = 0x00000001UL, Flag::OsLockingOk = 0x00000002UL,
  Flag::DontBlock = 1, Flag::NextOtp = 0x00000001UL, Flag::ExcludeTime = 0x00000002UL, Flag::ExcludeCounter = 0x00000004UL,
  Flag::ExcludeChallenge = 0x00000008UL, Flag::ExcludePin = 0x00000010UL, Flag::UserFriendlyOtp = 0x00000020UL
}
 
enum  HardwareType : CK_HW_FEATURE_TYPE { HardwareType::MonotonicCounter = 0x00000001UL, HardwareType::Clock = 0x00000002UL, HardwareType::UserInterface = 0x00000003UL, HardwareType::VendorDefined = 0x80000000UL }
 
enum  KeyDerivation : CK_ULONG {
  KeyDerivation::Null = 0x00000001UL, KeyDerivation::Sha1Kdf = 0x00000002UL, KeyDerivation::Sha1KdfAsn1 = 0x00000003UL, KeyDerivation::Sha1KdfConcatenate = 0x00000004UL,
  KeyDerivation::Sha224Kdf = 0x00000005UL, KeyDerivation::Sha256Kdf = 0x00000006UL, KeyDerivation::Sha384Kdf = 0x00000007UL, KeyDerivation::Sha512Kdf = 0x00000008UL,
  KeyDerivation::CpdiversifyKdf = 0x00000009UL
}
 
enum  KeyType : CK_KEY_TYPE {
  KeyType::Rsa = 0x00000000UL, KeyType::Dsa = 0x00000001UL, KeyType::Dh = 0x00000002UL, KeyType::Ecdsa = 0x00000003UL,
  KeyType::Ec = 0x00000003UL, KeyType::X942Dh = 0x00000004UL, KeyType::Kea = 0x00000005UL, KeyType::GenericSecret = 0x00000010UL,
  KeyType::Rc2 = 0x00000011UL, KeyType::Rc4 = 0x00000012UL, KeyType::Des = 0x00000013UL, KeyType::Des2 = 0x00000014UL,
  KeyType::Des3 = 0x00000015UL, KeyType::Cast = 0x00000016UL, KeyType::Cast3 = 0x00000017UL, KeyType::Cast5 = 0x00000018UL,
  KeyType::Cast128 = 0x00000018UL, KeyType::Rc5 = 0x00000019UL, KeyType::Idea = 0x0000001AUL, KeyType::Skipjack = 0x0000001BUL,
  KeyType::Baton = 0x0000001CUL, KeyType::Juniper = 0x0000001DUL, KeyType::Cdmf = 0x0000001EUL, KeyType::Aes = 0x0000001FUL,
  KeyType::Blowfish = 0x00000020UL, KeyType::Twofish = 0x00000021UL, KeyType::Securid = 0x00000022UL, KeyType::Hotp = 0x00000023UL,
  KeyType::Acti = 0x00000024UL, KeyType::Camellia = 0x00000025UL, KeyType::Aria = 0x00000026UL, KeyType::Md5Hmac = 0x00000027UL,
  KeyType::Sha1Hmac = 0x00000028UL, KeyType::Ripemd128Hmac = 0x00000029UL, KeyType::Ripemd160Hmac = 0x0000002AUL, KeyType::Sha256Hmac = 0x0000002BUL,
  KeyType::Sha384Hmac = 0x0000002CUL, KeyType::Sha512Hmac = 0x0000002DUL, KeyType::Sha224Hmac = 0x0000002EUL, KeyType::Seed = 0x0000002FUL,
  KeyType::Gostr3410 = 0x00000030UL, KeyType::Gostr3411 = 0x00000031UL, KeyType::Gost28147 = 0x00000032UL, KeyType::VendorDefined = 0x80000000UL
}
 
enum  MechanismType : CK_MECHANISM_TYPE {
  MechanismType::RsaPkcsKeyPairGen = 0x00000000UL, MechanismType::RsaPkcs = 0x00000001UL, MechanismType::Rsa9796 = 0x00000002UL, MechanismType::RsaX509 = 0x00000003UL,
  MechanismType::Md2RsaPkcs = 0x00000004UL, MechanismType::Md5RsaPkcs = 0x00000005UL, MechanismType::Sha1RsaPkcs = 0x00000006UL, MechanismType::Ripemd128RsaPkcs = 0x00000007UL,
  MechanismType::Ripemd160RsaPkcs = 0x00000008UL, MechanismType::RsaPkcsOaep = 0x00000009UL, MechanismType::RsaX931KeyPairGen = 0x0000000AUL, MechanismType::RsaX931 = 0x0000000BUL,
  MechanismType::Sha1RsaX931 = 0x0000000CUL, MechanismType::RsaPkcsPss = 0x0000000DUL, MechanismType::Sha1RsaPkcsPss = 0x0000000EUL, MechanismType::DsaKeyPairGen = 0x00000010UL,
  MechanismType::Dsa = 0x00000011UL, MechanismType::DsaSha1 = 0x00000012UL, MechanismType::DsaSha224 = 0x00000013UL, MechanismType::DsaSha256 = 0x00000014UL,
  MechanismType::DsaSha384 = 0x00000015UL, MechanismType::DsaSha512 = 0x00000016UL, MechanismType::DhPkcsKeyPairGen = 0x00000020UL, MechanismType::DhPkcsDerive = 0x00000021UL,
  MechanismType::X942DhKeyPairGen = 0x00000030UL, MechanismType::X942DhDerive = 0x00000031UL, MechanismType::X942DhHybridDerive = 0x00000032UL, MechanismType::X942MqvDerive = 0x00000033UL,
  MechanismType::Sha256RsaPkcs = 0x00000040UL, MechanismType::Sha384RsaPkcs = 0x00000041UL, MechanismType::Sha512RsaPkcs = 0x00000042UL, MechanismType::Sha256RsaPkcsPss = 0x00000043UL,
  MechanismType::Sha384RsaPkcsPss = 0x00000044UL, MechanismType::Sha512RsaPkcsPss = 0x00000045UL, MechanismType::Sha224RsaPkcs = 0x00000046UL, MechanismType::Sha224RsaPkcsPss = 0x00000047UL,
  MechanismType::Sha512224 = 0x00000048UL, MechanismType::Sha512224Hmac = 0x00000049UL, MechanismType::Sha512224HmacGeneral = 0x0000004AUL, MechanismType::Sha512224KeyDerivation = 0x0000004BUL,
  MechanismType::Sha512256 = 0x0000004CUL, MechanismType::Sha512256Hmac = 0x0000004DUL, MechanismType::Sha512256HmacGeneral = 0x0000004EUL, MechanismType::Sha512256KeyDerivation = 0x0000004FUL,
  MechanismType::Sha512T = 0x00000050UL, MechanismType::Sha512THmac = 0x00000051UL, MechanismType::Sha512THmacGeneral = 0x00000052UL, MechanismType::Sha512TKeyDerivation = 0x00000053UL,
  MechanismType::Rc2KeyGen = 0x00000100UL, MechanismType::Rc2Ecb = 0x00000101UL, MechanismType::Rc2Cbc = 0x00000102UL, MechanismType::Rc2Mac = 0x00000103UL,
  MechanismType::Rc2MacGeneral = 0x00000104UL, MechanismType::Rc2CbcPad = 0x00000105UL, MechanismType::Rc4KeyGen = 0x00000110UL, MechanismType::Rc4 = 0x00000111UL,
  MechanismType::DesKeyGen = 0x00000120UL, MechanismType::DesEcb = 0x00000121UL, MechanismType::DesCbc = 0x00000122UL, MechanismType::DesMac = 0x00000123UL,
  MechanismType::DesMacGeneral = 0x00000124UL, MechanismType::DesCbcPad = 0x00000125UL, MechanismType::Des2KeyGen = 0x00000130UL, MechanismType::Des3KeyGen = 0x00000131UL,
  MechanismType::Des3Ecb = 0x00000132UL, MechanismType::Des3Cbc = 0x00000133UL, MechanismType::Des3Mac = 0x00000134UL, MechanismType::Des3MacGeneral = 0x00000135UL,
  MechanismType::Des3CbcPad = 0x00000136UL, MechanismType::Des3CmacGeneral = 0x00000137UL, MechanismType::Des3Cmac = 0x00000138UL, MechanismType::CdmfKeyGen = 0x00000140UL,
  MechanismType::CdmfEcb = 0x00000141UL, MechanismType::CdmfCbc = 0x00000142UL, MechanismType::CdmfMac = 0x00000143UL, MechanismType::CdmfMacGeneral = 0x00000144UL,
  MechanismType::CdmfCbcPad = 0x00000145UL, MechanismType::DesOfb64 = 0x00000150UL, MechanismType::DesOfb8 = 0x00000151UL, MechanismType::DesCfb64 = 0x00000152UL,
  MechanismType::DesCfb8 = 0x00000153UL, MechanismType::Md2 = 0x00000200UL, MechanismType::Md2Hmac = 0x00000201UL, MechanismType::Md2HmacGeneral = 0x00000202UL,
  MechanismType::Md5 = 0x00000210UL, MechanismType::Md5Hmac = 0x00000211UL, MechanismType::Md5HmacGeneral = 0x00000212UL, MechanismType::Sha1 = 0x00000220UL,
  MechanismType::Sha1Hmac = 0x00000221UL, MechanismType::Sha1HmacGeneral = 0x00000222UL, MechanismType::Ripemd128 = 0x00000230UL, MechanismType::Ripemd128Hmac = 0x00000231UL,
  MechanismType::Ripemd128HmacGeneral = 0x00000232UL, MechanismType::Ripemd160 = 0x00000240UL, MechanismType::Ripemd160Hmac = 0x00000241UL, MechanismType::Ripemd160HmacGeneral = 0x00000242UL,
  MechanismType::Sha256 = 0x00000250UL, MechanismType::Sha256Hmac = 0x00000251UL, MechanismType::Sha256HmacGeneral = 0x00000252UL, MechanismType::Sha224 = 0x00000255UL,
  MechanismType::Sha224Hmac = 0x00000256UL, MechanismType::Sha224HmacGeneral = 0x00000257UL, MechanismType::Sha384 = 0x00000260UL, MechanismType::Sha384Hmac = 0x00000261UL,
  MechanismType::Sha384HmacGeneral = 0x00000262UL, MechanismType::Sha512 = 0x00000270UL, MechanismType::Sha512Hmac = 0x00000271UL, MechanismType::Sha512HmacGeneral = 0x00000272UL,
  MechanismType::SecuridKeyGen = 0x00000280UL, MechanismType::Securid = 0x00000282UL, MechanismType::HotpKeyGen = 0x00000290UL, MechanismType::Hotp = 0x00000291UL,
  MechanismType::Acti = 0x000002A0UL, MechanismType::ActiKeyGen = 0x000002A1UL, MechanismType::CastKeyGen = 0x00000300UL, MechanismType::CastEcb = 0x00000301UL,
  MechanismType::CastCbc = 0x00000302UL, MechanismType::CastMac = 0x00000303UL, MechanismType::CastMacGeneral = 0x00000304UL, MechanismType::CastCbcPad = 0x00000305UL,
  MechanismType::Cast3KeyGen = 0x00000310UL, MechanismType::Cast3Ecb = 0x00000311UL, MechanismType::Cast3Cbc = 0x00000312UL, MechanismType::Cast3Mac = 0x00000313UL,
  MechanismType::Cast3MacGeneral = 0x00000314UL, MechanismType::Cast3CbcPad = 0x00000315UL, MechanismType::Cast5KeyGen = 0x00000320UL, MechanismType::Cast128KeyGen = 0x00000320UL,
  MechanismType::Cast5Ecb = 0x00000321UL, MechanismType::Cast128Ecb = 0x00000321UL, MechanismType::Cast5Cbc = 0x00000322UL, MechanismType::Cast128Cbc = 0x00000322UL,
  MechanismType::Cast5Mac = 0x00000323UL, MechanismType::Cast128Mac = 0x00000323UL, MechanismType::Cast5MacGeneral = 0x00000324UL, MechanismType::Cast128MacGeneral = 0x00000324UL,
  MechanismType::Cast5CbcPad = 0x00000325UL, MechanismType::Cast128CbcPad = 0x00000325UL, MechanismType::Rc5KeyGen = 0x00000330UL, MechanismType::Rc5Ecb = 0x00000331UL,
  MechanismType::Rc5Cbc = 0x00000332UL, MechanismType::Rc5Mac = 0x00000333UL, MechanismType::Rc5MacGeneral = 0x00000334UL, MechanismType::Rc5CbcPad = 0x00000335UL,
  MechanismType::IdeaKeyGen = 0x00000340UL, MechanismType::IdeaEcb = 0x00000341UL, MechanismType::IdeaCbc = 0x00000342UL, MechanismType::IdeaMac = 0x00000343UL,
  MechanismType::IdeaMacGeneral = 0x00000344UL, MechanismType::IdeaCbcPad = 0x00000345UL, MechanismType::GenericSecretKeyGen = 0x00000350UL, MechanismType::ConcatenateBaseAndKey = 0x00000360UL,
  MechanismType::ConcatenateBaseAndData = 0x00000362UL, MechanismType::ConcatenateDataAndBase = 0x00000363UL, MechanismType::XorBaseAndData = 0x00000364UL, MechanismType::ExtractKeyFromKey = 0x00000365UL,
  MechanismType::Ssl3PreMasterKeyGen = 0x00000370UL, MechanismType::Ssl3MasterKeyDerive = 0x00000371UL, MechanismType::Ssl3KeyAndMacDerive = 0x00000372UL, MechanismType::Ssl3MasterKeyDeriveDh = 0x00000373UL,
  MechanismType::TlsPreMasterKeyGen = 0x00000374UL, MechanismType::TlsMasterKeyDerive = 0x00000375UL, MechanismType::TlsKeyAndMacDerive = 0x00000376UL, MechanismType::TlsMasterKeyDeriveDh = 0x00000377UL,
  MechanismType::TlsPrf = 0x00000378UL, MechanismType::Ssl3Md5Mac = 0x00000380UL, MechanismType::Ssl3Sha1Mac = 0x00000381UL, MechanismType::Md5KeyDerivation = 0x00000390UL,
  MechanismType::Md2KeyDerivation = 0x00000391UL, MechanismType::Sha1KeyDerivation = 0x00000392UL, MechanismType::Sha256KeyDerivation = 0x00000393UL, MechanismType::Sha384KeyDerivation = 0x00000394UL,
  MechanismType::Sha512KeyDerivation = 0x00000395UL, MechanismType::Sha224KeyDerivation = 0x00000396UL, MechanismType::PbeMd2DesCbc = 0x000003A0UL, MechanismType::PbeMd5DesCbc = 0x000003A1UL,
  MechanismType::PbeMd5CastCbc = 0x000003A2UL, MechanismType::PbeMd5Cast3Cbc = 0x000003A3UL, MechanismType::PbeMd5Cast5Cbc = 0x000003A4UL, MechanismType::PbeMd5Cast128Cbc = 0x000003A4UL,
  MechanismType::PbeSha1Cast5Cbc = 0x000003A5UL, MechanismType::PbeSha1Cast128Cbc = 0x000003A5UL, MechanismType::PbeSha1Rc4128 = 0x000003A6UL, MechanismType::PbeSha1Rc440 = 0x000003A7UL,
  MechanismType::PbeSha1Des3EdeCbc = 0x000003A8UL, MechanismType::PbeSha1Des2EdeCbc = 0x000003A9UL, MechanismType::PbeSha1Rc2128Cbc = 0x000003AAUL, MechanismType::PbeSha1Rc240Cbc = 0x000003ABUL,
  MechanismType::Pkcs5Pbkd2 = 0x000003B0UL, MechanismType::PbaSha1WithSha1Hmac = 0x000003C0UL, MechanismType::WtlsPreMasterKeyGen = 0x000003D0UL, MechanismType::WtlsMasterKeyDerive = 0x000003D1UL,
  MechanismType::WtlsMasterKeyDeriveDhEcc = 0x000003D2UL, MechanismType::WtlsPrf = 0x000003D3UL, MechanismType::WtlsServerKeyAndMacDerive = 0x000003D4UL, MechanismType::WtlsClientKeyAndMacDerive = 0x000003D5UL,
  MechanismType::Tls10MacServer = 0x000003D6UL, MechanismType::Tls10MacClient = 0x000003D7UL, MechanismType::Tls12Mac = 0x000003D8UL, MechanismType::Tls12Kdf = 0x000003D9UL,
  MechanismType::Tls12MasterKeyDerive = 0x000003E0UL, MechanismType::Tls12KeyAndMacDerive = 0x000003E1UL, MechanismType::Tls12MasterKeyDeriveDh = 0x000003E2UL, MechanismType::Tls12KeySafeDerive = 0x000003E3UL,
  MechanismType::TlsMac = 0x000003E4UL, MechanismType::TlsKdf = 0x000003E5UL, MechanismType::KeyWrapLynks = 0x00000400UL, MechanismType::KeyWrapSetOaep = 0x00000401UL,
  MechanismType::CmsSig = 0x00000500UL, MechanismType::KipDerive = 0x00000510UL, MechanismType::KipWrap = 0x00000511UL, MechanismType::KipMac = 0x00000512UL,
  MechanismType::CamelliaKeyGen = 0x00000550UL, MechanismType::CamelliaEcb = 0x00000551UL, MechanismType::CamelliaCbc = 0x00000552UL, MechanismType::CamelliaMac = 0x00000553UL,
  MechanismType::CamelliaMacGeneral = 0x00000554UL, MechanismType::CamelliaCbcPad = 0x00000555UL, MechanismType::CamelliaEcbEncryptData = 0x00000556UL, MechanismType::CamelliaCbcEncryptData = 0x00000557UL,
  MechanismType::CamelliaCtr = 0x00000558UL, MechanismType::AriaKeyGen = 0x00000560UL, MechanismType::AriaEcb = 0x00000561UL, MechanismType::AriaCbc = 0x00000562UL,
  MechanismType::AriaMac = 0x00000563UL, MechanismType::AriaMacGeneral = 0x00000564UL, MechanismType::AriaCbcPad = 0x00000565UL, MechanismType::AriaEcbEncryptData = 0x00000566UL,
  MechanismType::AriaCbcEncryptData = 0x00000567UL, MechanismType::SeedKeyGen = 0x00000650UL, MechanismType::SeedEcb = 0x00000651UL, MechanismType::SeedCbc = 0x00000652UL,
  MechanismType::SeedMac = 0x00000653UL, MechanismType::SeedMacGeneral = 0x00000654UL, MechanismType::SeedCbcPad = 0x00000655UL, MechanismType::SeedEcbEncryptData = 0x00000656UL,
  MechanismType::SeedCbcEncryptData = 0x00000657UL, MechanismType::SkipjackKeyGen = 0x00001000UL, MechanismType::SkipjackEcb64 = 0x00001001UL, MechanismType::SkipjackCbc64 = 0x00001002UL,
  MechanismType::SkipjackOfb64 = 0x00001003UL, MechanismType::SkipjackCfb64 = 0x00001004UL, MechanismType::SkipjackCfb32 = 0x00001005UL, MechanismType::SkipjackCfb16 = 0x00001006UL,
  MechanismType::SkipjackCfb8 = 0x00001007UL, MechanismType::SkipjackWrap = 0x00001008UL, MechanismType::SkipjackPrivateWrap = 0x00001009UL, MechanismType::SkipjackRelayx = 0x0000100aUL,
  MechanismType::KeaKeyPairGen = 0x00001010UL, MechanismType::KeaKeyDerive = 0x00001011UL, MechanismType::KeaDerive = 0x00001012UL, MechanismType::FortezzaTimestamp = 0x00001020UL,
  MechanismType::BatonKeyGen = 0x00001030UL, MechanismType::BatonEcb128 = 0x00001031UL, MechanismType::BatonEcb96 = 0x00001032UL, MechanismType::BatonCbc128 = 0x00001033UL,
  MechanismType::BatonCounter = 0x00001034UL, MechanismType::BatonShuffle = 0x00001035UL, MechanismType::BatonWrap = 0x00001036UL, MechanismType::EcdsaKeyPairGen = 0x00001040UL,
  MechanismType::EcKeyPairGen = 0x00001040UL, MechanismType::Ecdsa = 0x00001041UL, MechanismType::EcdsaSha1 = 0x00001042UL, MechanismType::EcdsaSha224 = 0x00001043UL,
  MechanismType::EcdsaSha256 = 0x00001044UL, MechanismType::EcdsaSha384 = 0x00001045UL, MechanismType::EcdsaSha512 = 0x00001046UL, MechanismType::Ecdh1Derive = 0x00001050UL,
  MechanismType::Ecdh1CofactorDerive = 0x00001051UL, MechanismType::EcmqvDerive = 0x00001052UL, MechanismType::EcdhAesKeyWrap = 0x00001053UL, MechanismType::RsaAesKeyWrap = 0x00001054UL,
  MechanismType::JuniperKeyGen = 0x00001060UL, MechanismType::JuniperEcb128 = 0x00001061UL, MechanismType::JuniperCbc128 = 0x00001062UL, MechanismType::JuniperCounter = 0x00001063UL,
  MechanismType::JuniperShuffle = 0x00001064UL, MechanismType::JuniperWrap = 0x00001065UL, MechanismType::Fasthash = 0x00001070UL, MechanismType::AesKeyGen = 0x00001080UL,
  MechanismType::AesEcb = 0x00001081UL, MechanismType::AesCbc = 0x00001082UL, MechanismType::AesMac = 0x00001083UL, MechanismType::AesMacGeneral = 0x00001084UL,
  MechanismType::AesCbcPad = 0x00001085UL, MechanismType::AesCtr = 0x00001086UL, MechanismType::AesGcm = 0x00001087UL, MechanismType::AesCcm = 0x00001088UL,
  MechanismType::AesCts = 0x00001089UL, MechanismType::AesCmac = 0x0000108AUL, MechanismType::AesCmacGeneral = 0x0000108BUL, MechanismType::AesXcbcMac = 0x0000108CUL,
  MechanismType::AesXcbcMac96 = 0x0000108DUL, MechanismType::AesGmac = 0x0000108EUL, MechanismType::BlowfishKeyGen = 0x00001090UL, MechanismType::BlowfishCbc = 0x00001091UL,
  MechanismType::TwofishKeyGen = 0x00001092UL, MechanismType::TwofishCbc = 0x00001093UL, MechanismType::BlowfishCbcPad = 0x00001094UL, MechanismType::TwofishCbcPad = 0x00001095UL,
  MechanismType::DesEcbEncryptData = 0x00001100UL, MechanismType::DesCbcEncryptData = 0x00001101UL, MechanismType::Des3EcbEncryptData = 0x00001102UL, MechanismType::Des3CbcEncryptData = 0x00001103UL,
  MechanismType::AesEcbEncryptData = 0x00001104UL, MechanismType::AesCbcEncryptData = 0x00001105UL, MechanismType::Gostr3410KeyPairGen = 0x00001200UL, MechanismType::Gostr3410 = 0x00001201UL,
  MechanismType::Gostr3410WithGostr3411 = 0x00001202UL, MechanismType::Gostr3410KeyWrap = 0x00001203UL, MechanismType::Gostr3410Derive = 0x00001204UL, MechanismType::Gostr3411 = 0x00001210UL,
  MechanismType::Gostr3411Hmac = 0x00001211UL, MechanismType::Gost28147KeyGen = 0x00001220UL, MechanismType::Gost28147Ecb = 0x00001221UL, MechanismType::Gost28147 = 0x00001222UL,
  MechanismType::Gost28147Mac = 0x00001223UL, MechanismType::Gost28147KeyWrap = 0x00001224UL, MechanismType::DsaParameterGen = 0x00002000UL, MechanismType::DhPkcsParameterGen = 0x00002001UL,
  MechanismType::X942DhParameterGen = 0x00002002UL, MechanismType::DsaProbablisticParameterGen = 0x00002003UL, MechanismType::DsaShaweTaylorParameterGen = 0x00002004UL, MechanismType::AesOfb = 0x00002104UL,
  MechanismType::AesCfb64 = 0x00002105UL, MechanismType::AesCfb8 = 0x00002106UL, MechanismType::AesCfb128 = 0x00002107UL, MechanismType::AesCfb1 = 0x00002108UL,
  MechanismType::AesKeyWrap = 0x00002109UL, MechanismType::AesKeyWrapPad = 0x0000210AUL, MechanismType::RsaPkcsTpm11 = 0x00004001UL, MechanismType::RsaPkcsOaepTpm11 = 0x00004002UL,
  MechanismType::VendorDefined = 0x80000000UL
}
 
enum  MGF : CK_RSA_PKCS_MGF_TYPE {
  MGF::Mgf1Sha1 = 0x00000001UL, MGF::Mgf1Sha256 = 0x00000002UL, MGF::Mgf1Sha384 = 0x00000003UL, MGF::Mgf1Sha512 = 0x00000004UL,
  MGF::Mgf1Sha224 = 0x00000005UL
}
 
enum  Notification : CK_NOTIFICATION { Notification::Surrender = 0UL, Notification::OtpChanged = 1UL }
 
enum  ObjectClass : CK_OBJECT_CLASS {
  ObjectClass::Data = 0x00000000UL, ObjectClass::Certificate = 0x00000001UL, ObjectClass::PublicKey = 0x00000002UL, ObjectClass::PrivateKey = 0x00000003UL,
  ObjectClass::SecretKey = 0x00000004UL, ObjectClass::HwFeature = 0x00000005UL, ObjectClass::DomainParameters = 0x00000006UL, ObjectClass::Mechanism = 0x00000007UL,
  ObjectClass::OtpKey = 0x00000008UL, ObjectClass::VendorDefined = 0x80000000UL
}
 
enum  PseudoRandom : CK_PKCS5_PBKD2_PSEUDO_RANDOM_FUNCTION_TYPE {
  PseudoRandom::Pkcs5Pbkd2HmacSha1 = 0x00000001UL, PseudoRandom::Pkcs5Pbkd2HmacGostr3411 = 0x00000002UL, PseudoRandom::Pkcs5Pbkd2HmacSha224 = 0x00000003UL, PseudoRandom::Pkcs5Pbkd2HmacSha256 = 0x00000004UL,
  PseudoRandom::Pkcs5Pbkd2HmacSha384 = 0x00000005UL, PseudoRandom::Pkcs5Pbkd2HmacSha512 = 0x00000006UL, PseudoRandom::Pkcs5Pbkd2HmacSha512224 = 0x00000007UL, PseudoRandom::Pkcs5Pbkd2HmacSha512256 = 0x00000008UL
}
 
enum  PublicPointEncoding : uint32_t { PublicPointEncoding::Raw, PublicPointEncoding::Der }
 
enum  ReturnValue : CK_RV {
  ReturnValue::OK = 0x00000000UL, ReturnValue::Cancel = 0x00000001UL, ReturnValue::HostMemory = 0x00000002UL, ReturnValue::SlotIdInvalid = 0x00000003UL,
  ReturnValue::GeneralError = 0x00000005UL, ReturnValue::FunctionFailed = 0x00000006UL, ReturnValue::ArgumentsBad = 0x00000007UL, ReturnValue::NoEvent = 0x00000008UL,
  ReturnValue::NeedToCreateThreads = 0x00000009UL, ReturnValue::CantLock = 0x0000000AUL, ReturnValue::AttributeReadOnly = 0x00000010UL, ReturnValue::AttributeSensitive = 0x00000011UL,
  ReturnValue::AttributeTypeInvalid = 0x00000012UL, ReturnValue::AttributeValueInvalid = 0x00000013UL, ReturnValue::ActionProhibited = 0x0000001BUL, ReturnValue::DataInvalid = 0x00000020UL,
  ReturnValue::DataLenRange = 0x00000021UL, ReturnValue::DeviceError = 0x00000030UL, ReturnValue::DeviceMemory = 0x00000031UL, ReturnValue::DeviceRemoved = 0x00000032UL,
  ReturnValue::EncryptedDataInvalid = 0x00000040UL, ReturnValue::EncryptedDataLenRange = 0x00000041UL, ReturnValue::FunctionCanceled = 0x00000050UL, ReturnValue::FunctionNotParallel = 0x00000051UL,
  ReturnValue::FunctionNotSupported = 0x00000054UL, ReturnValue::KeyHandleInvalid = 0x00000060UL, ReturnValue::KeySizeRange = 0x00000062UL, ReturnValue::KeyTypeInconsistent = 0x00000063UL,
  ReturnValue::KeyNotNeeded = 0x00000064UL, ReturnValue::KeyChanged = 0x00000065UL, ReturnValue::KeyNeeded = 0x00000066UL, ReturnValue::KeyIndigestible = 0x00000067UL,
  ReturnValue::KeyFunctionNotPermitted = 0x00000068UL, ReturnValue::KeyNotWrappable = 0x00000069UL, ReturnValue::KeyUnextractable = 0x0000006AUL, ReturnValue::MechanismInvalid = 0x00000070UL,
  ReturnValue::MechanismParamInvalid = 0x00000071UL, ReturnValue::ObjectHandleInvalid = 0x00000082UL, ReturnValue::OperationActive = 0x00000090UL, ReturnValue::OperationNotInitialized = 0x00000091UL,
  ReturnValue::PinIncorrect = 0x000000A0UL, ReturnValue::PinInvalid = 0x000000A1UL, ReturnValue::PinLenRange = 0x000000A2UL, ReturnValue::PinExpired = 0x000000A3UL,
  ReturnValue::PinLocked = 0x000000A4UL, ReturnValue::SessionClosed = 0x000000B0UL, ReturnValue::SessionCount = 0x000000B1UL, ReturnValue::SessionHandleInvalid = 0x000000B3UL,
  ReturnValue::SessionParallelNotSupported = 0x000000B4UL, ReturnValue::SessionReadOnly = 0x000000B5UL, ReturnValue::SessionExists = 0x000000B6UL, ReturnValue::SessionReadOnlyExists = 0x000000B7UL,
  ReturnValue::SessionReadWriteSoExists = 0x000000B8UL, ReturnValue::SignatureInvalid = 0x000000C0UL, ReturnValue::SignatureLenRange = 0x000000C1UL, ReturnValue::TemplateIncomplete = 0x000000D0UL,
  ReturnValue::TemplateInconsistent = 0x000000D1UL, ReturnValue::TokenNotPresent = 0x000000E0UL, ReturnValue::TokenNotRecognized = 0x000000E1UL, ReturnValue::TokenWriteProtected = 0x000000E2UL,
  ReturnValue::UnwrappingKeyHandleInvalid = 0x000000F0UL, ReturnValue::UnwrappingKeySizeRange = 0x000000F1UL, ReturnValue::UnwrappingKeyTypeInconsistent = 0x000000F2UL, ReturnValue::UserAlreadyLoggedIn = 0x00000100UL,
  ReturnValue::UserNotLoggedIn = 0x00000101UL, ReturnValue::UserPinNotInitialized = 0x00000102UL, ReturnValue::UserTypeInvalid = 0x00000103UL, ReturnValue::UserAnotherAlreadyLoggedIn = 0x00000104UL,
  ReturnValue::UserTooManyTypes = 0x00000105UL, ReturnValue::WrappedKeyInvalid = 0x00000110UL, ReturnValue::WrappedKeyLenRange = 0x00000112UL, ReturnValue::WrappingKeyHandleInvalid = 0x00000113UL,
  ReturnValue::WrappingKeySizeRange = 0x00000114UL, ReturnValue::WrappingKeyTypeInconsistent = 0x00000115UL, ReturnValue::RandomSeedNotSupported = 0x00000120UL, ReturnValue::RandomNoRng = 0x00000121UL,
  ReturnValue::DomainParamsInvalid = 0x00000130UL, ReturnValue::CurveNotSupported = 0x00000140UL, ReturnValue::BufferTooSmall = 0x00000150UL, ReturnValue::SavedStateInvalid = 0x00000160UL,
  ReturnValue::InformationSensitive = 0x00000170UL, ReturnValue::StateUnsaveable = 0x00000180UL, ReturnValue::CryptokiNotInitialized = 0x00000190UL, ReturnValue::CryptokiAlreadyInitialized = 0x00000191UL,
  ReturnValue::MutexBad = 0x000001A0UL, ReturnValue::MutexNotLocked = 0x000001A1UL, ReturnValue::NewPinMode = 0x000001B0UL, ReturnValue::NextOtp = 0x000001B1UL,
  ReturnValue::ExceededMaxIterations = 0x000001B5UL, ReturnValue::FipsSelfTestFailed = 0x000001B6UL, ReturnValue::LibraryLoadFailed = 0x000001B7UL, ReturnValue::PinTooWeak = 0x000001B8UL,
  ReturnValue::PublicKeyInvalid = 0x000001B9UL, ReturnValue::FunctionRejected = 0x00000200UL, ReturnValue::VendorDefined = 0x80000000UL
}
 
enum  SessionState : CK_STATE {
  SessionState::RoPublicSession = 0UL, SessionState::RoUserFunctions = 1UL, SessionState::RwPublicSession = 2UL, SessionState::RwUserFunctions = 3UL,
  SessionState::RwSoFunctions = 4UL
}
 
enum  UserType : CK_USER_TYPE { UserType::SO = 0UL, UserType::User = 1UL, UserType::ContextSpecific = 2UL }
 

Functions

void change_pin (Slot &slot, const secure_string &old_pin, const secure_string &new_pin)
 
void change_so_pin (Slot &slot, const secure_string &old_so_pin, const secure_string &new_so_pin)
 
Flags flags (Flag flags)
 
void initialize_token (Slot &slot, const std::string &label, const secure_string &so_pin, const secure_string &pin)
 
Flag operator| (Flag a, Flag b)
 
void set_pin (Slot &slot, const secure_string &so_pin, const secure_string &pin)
 

Variables

const Bbool False = 0
 
ReturnValueThrowException = reinterpret_cast< ReturnValue* >(-1)
 
const Bbool True = 1
 

Typedef Documentation

◆ Attribute

Definition at line 845 of file p11.h.

◆ Bbool

using Botan::PKCS11::Bbool = typedef CK_BBOOL

Definition at line 834 of file p11.h.

◆ Byte

using Botan::PKCS11::Byte = typedef CK_BYTE

Definition at line 847 of file p11.h.

◆ C_InitializeArgs

Definition at line 827 of file p11.h.

◆ CreateMutex

using Botan::PKCS11::CreateMutex = typedef CK_CREATEMUTEX

Definition at line 828 of file p11.h.

◆ Date

using Botan::PKCS11::Date = typedef CK_DATE

Definition at line 851 of file p11.h.

◆ DestroyMutex

using Botan::PKCS11::DestroyMutex = typedef CK_DESTROYMUTEX

Definition at line 829 of file p11.h.

◆ Ecdh1DeriveParams

Definition at line 850 of file p11.h.

◆ Flags

using Botan::PKCS11::Flags = typedef CK_FLAGS

Definition at line 832 of file p11.h.

◆ FunctionListPtr

Definition at line 825 of file p11.h.

◆ Info

using Botan::PKCS11::Info = typedef CK_INFO

Definition at line 833 of file p11.h.

◆ LockMutex

using Botan::PKCS11::LockMutex = typedef CK_LOCKMUTEX

Definition at line 830 of file p11.h.

◆ Mechanism

Definition at line 839 of file p11.h.

◆ MechanismInfo

Definition at line 840 of file p11.h.

◆ Notify

using Botan::PKCS11::Notify = typedef CK_NOTIFY

Definition at line 842 of file p11.h.

◆ ObjectHandle

Definition at line 846 of file p11.h.

◆ RsaPkcsOaepParams

Definition at line 848 of file p11.h.

◆ RsaPkcsPssParams

Definition at line 849 of file p11.h.

◆ secure_string

using Botan::PKCS11::secure_string = typedef secure_vector<uint8_t>

Definition at line 61 of file p11.h.

◆ SessionHandle

Definition at line 843 of file p11.h.

◆ SessionInfo

Definition at line 844 of file p11.h.

◆ SlotId

Definition at line 835 of file p11.h.

◆ SlotInfo

Definition at line 837 of file p11.h.

◆ TokenInfo

Definition at line 838 of file p11.h.

◆ Ulong

using Botan::PKCS11::Ulong = typedef CK_ULONG

Definition at line 836 of file p11.h.

◆ UnlockMutex

using Botan::PKCS11::UnlockMutex = typedef CK_UNLOCKMUTEX

Definition at line 831 of file p11.h.

◆ Utf8Char

Definition at line 841 of file p11.h.

◆ VoidPtr

Definition at line 826 of file p11.h.

Enumeration Type Documentation

◆ AttributeType

Enumerator
Class 
Token 
Private 
Label 
Application 
Value 
ObjectId 
CertificateType 
Issuer 
SerialNumber 
AcIssuer 
Owner 
AttrTypes 
Trusted 
CertificateCategory 
JavaMidpSecurityDomain 
Url 
HashOfSubjectPublicKey 
HashOfIssuerPublicKey 
NameHashAlgorithm 
CheckValue 
KeyType 
Subject 
Id 
Sensitive 
Encrypt 
Decrypt 
Wrap 
Unwrap 
Sign 
SignRecover 
Verify 
VerifyRecover 
Derive 
StartDate 
EndDate 
Modulus 
ModulusBits 
PublicExponent 
PrivateExponent 
Prime1 
Prime2 
Exponent1 
Exponent2 
Coefficient 
PublicKeyInfo 
Prime 
Subprime 
Base 
PrimeBits 
SubprimeBits 
SubPrimeBits 
ValueBits 
ValueLen 
Extractable 
Local 
NeverExtractable 
AlwaysSensitive 
KeyGenMechanism 
Modifiable 
Copyable 
Destroyable 
EcdsaParams 
EcParams 
EcPoint 
SecondaryAuth 
AuthPinFlags 
AlwaysAuthenticate 
WrapWithTrusted 
WrapTemplate 
UnwrapTemplate 
DeriveTemplate 
OtpFormat 
OtpLength 
OtpTimeInterval 
OtpUserFriendlyMode 
OtpChallengeRequirement 
OtpTimeRequirement 
OtpCounterRequirement 
OtpPinRequirement 
OtpCounter 
OtpTime 
OtpUserIdentifier 
OtpServiceIdentifier 
OtpServiceLogo 
OtpServiceLogoType 
Gostr3410Params 
Gostr3411Params 
Gost28147Params 
HwFeatureType 
ResetOnInit 
HasReset 
PixelX 
PixelY 
Resolution 
CharRows 
CharColumns 
Color 
BitsPerPixel 
CharSets 
EncodingMethods 
MimeTypes 
MechanismType 
RequiredCmsAttributes 
DefaultCmsAttributes 
SupportedCmsAttributes 
AllowedMechanisms 
VendorDefined 

Definition at line 63 of file p11.h.

64  {
65  Class = CKA_CLASS,
66  Token = CKA_TOKEN,
68  Label = CKA_LABEL,
70  Value = CKA_VALUE,
76  Owner = CKA_OWNER,
81  Url = CKA_URL,
88  Id = CKA_ID,
92  Wrap = CKA_WRAP,
94  Sign = CKA_SIGN,
111  Prime = CKA_PRIME,
113  Base = CKA_BASE,
120  Local = CKA_LOCAL,
162  Color = CKA_COLOR,
173  };
#define CKA_CHAR_ROWS
Definition: pkcs11t.h:546
#define CKA_HW_FEATURE_TYPE
Definition: pkcs11t.h:539
#define CKA_TRUSTED
Definition: pkcs11t.h:450
#define CKA_ENCODING_METHODS
Definition: pkcs11t.h:551
#define CKA_PRIME_1
Definition: pkcs11t.h:478
#define CKA_WRAP_WITH_TRUSTED
Definition: pkcs11t.h:515
#define CKA_PRIVATE_EXPONENT
Definition: pkcs11t.h:477
#define CKA_UNWRAP_TEMPLATE
Definition: pkcs11t.h:517
#define CKA_SUBJECT
Definition: pkcs11t.h:460
#define CKA_EC_PARAMS
Definition: pkcs11t.h:506
#define CKA_OTP_SERVICE_LOGO_TYPE
Definition: pkcs11t.h:533
#define CKA_CHAR_COLUMNS
Definition: pkcs11t.h:547
#define CKA_LABEL
Definition: pkcs11t.h:440
#define CKA_ISSUER
Definition: pkcs11t.h:445
#define CKA_ATTR_TYPES
Definition: pkcs11t.h:449
#define CKA_MIME_TYPES
Definition: pkcs11t.h:552
CertificateType
Definition: p11.h:175
#define CKA_OTP_COUNTER_REQUIREMENT
Definition: pkcs11t.h:526
#define CKA_REQUIRED_CMS_ATTRIBUTES
Definition: pkcs11t.h:554
#define CKA_EXTRACTABLE
Definition: pkcs11t.h:494
#define CKA_EC_POINT
Definition: pkcs11t.h:508
#define CKA_COEFFICIENT
Definition: pkcs11t.h:482
#define CKA_SERIAL_NUMBER
Definition: pkcs11t.h:446
#define CKA_PUBLIC_KEY_INFO
Definition: pkcs11t.h:483
#define CKA_VALUE
Definition: pkcs11t.h:442
#define CKA_KEY_TYPE
Definition: pkcs11t.h:459
#define CKA_ID
Definition: pkcs11t.h:461
#define CKA_OTP_COUNTER
Definition: pkcs11t.h:528
#define CKA_OBJECT_ID
Definition: pkcs11t.h:443
#define CKA_WRAP
Definition: pkcs11t.h:465
#define CKA_GOST28147_PARAMS
Definition: pkcs11t.h:537
#define CKA_PIXEL_X
Definition: pkcs11t.h:543
#define CKA_ALWAYS_AUTHENTICATE
Definition: pkcs11t.h:513
#define CKA_DERIVE
Definition: pkcs11t.h:471
#define CKA_OTP_FORMAT
Definition: pkcs11t.h:520
#define CKA_OTP_TIME_REQUIREMENT
Definition: pkcs11t.h:525
CK_ULONG CK_ATTRIBUTE_TYPE
Definition: pkcs11t.h:416
#define CKA_PRIVATE
Definition: pkcs11t.h:439
#define CKA_OTP_PIN_REQUIREMENT
Definition: pkcs11t.h:527
#define CKA_ALWAYS_SENSITIVE
Definition: pkcs11t.h:497
#define CKA_END_DATE
Definition: pkcs11t.h:473
#define CKA_OTP_LENGTH
Definition: pkcs11t.h:521
#define CKA_SIGN
Definition: pkcs11t.h:467
#define CKA_VENDOR_DEFINED
Definition: pkcs11t.h:559
#define CKA_ECDSA_PARAMS
Definition: pkcs11t.h:505
#define CKA_CERTIFICATE_CATEGORY
Definition: pkcs11t.h:451
#define CKA_LOCAL
Definition: pkcs11t.h:495
#define CKA_EXPONENT_1
Definition: pkcs11t.h:480
#define CKA_HAS_RESET
Definition: pkcs11t.h:541
#define CKA_OTP_SERVICE_LOGO
Definition: pkcs11t.h:532
#define CKA_SECONDARY_AUTH
Definition: pkcs11t.h:510
#define CKA_CHAR_SETS
Definition: pkcs11t.h:550
#define CKA_ALLOWED_MECHANISMS
Definition: pkcs11t.h:557
#define CKA_ENCRYPT
Definition: pkcs11t.h:463
#define CKA_MODULUS
Definition: pkcs11t.h:474
#define CKA_OTP_USER_IDENTIFIER
Definition: pkcs11t.h:530
#define CKA_SENSITIVE
Definition: pkcs11t.h:462
#define CKA_PUBLIC_EXPONENT
Definition: pkcs11t.h:476
#define CKA_OWNER
Definition: pkcs11t.h:448
#define CKA_COPYABLE
Definition: pkcs11t.h:501
#define CKA_PRIME
Definition: pkcs11t.h:484
#define CKA_GOSTR3410_PARAMS
Definition: pkcs11t.h:535
#define CKA_NAME_HASH_ALGORITHM
Definition: pkcs11t.h:456
#define CKA_MECHANISM_TYPE
Definition: pkcs11t.h:553
#define CKA_SUBPRIME_BITS
Definition: pkcs11t.h:489
#define CKA_DERIVE_TEMPLATE
Definition: pkcs11t.h:518
#define CKA_PIXEL_Y
Definition: pkcs11t.h:544
#define CKA_TOKEN
Definition: pkcs11t.h:438
#define CKA_GOSTR3411_PARAMS
Definition: pkcs11t.h:536
#define CKA_APPLICATION
Definition: pkcs11t.h:441
#define CKA_OTP_USER_FRIENDLY_MODE
Definition: pkcs11t.h:523
#define CKA_SUPPORTED_CMS_ATTRIBUTES
Definition: pkcs11t.h:556
#define CKA_URL
Definition: pkcs11t.h:453
#define CKA_NEVER_EXTRACTABLE
Definition: pkcs11t.h:496
#define CKA_CLASS
Definition: pkcs11t.h:437
#define CKA_AC_ISSUER
Definition: pkcs11t.h:447
#define CKA_CHECK_VALUE
Definition: pkcs11t.h:457
#define CKA_VERIFY_RECOVER
Definition: pkcs11t.h:470
#define CKA_RESET_ON_INIT
Definition: pkcs11t.h:540
#define CKA_BASE
Definition: pkcs11t.h:486
#define CKA_OTP_TIME
Definition: pkcs11t.h:529
#define CKA_VERIFY
Definition: pkcs11t.h:469
#define CKA_BITS_PER_PIXEL
Definition: pkcs11t.h:549
#define CKA_SUBPRIME
Definition: pkcs11t.h:485
MechanismType
Definition: p11.h:335
#define CKA_COLOR
Definition: pkcs11t.h:548
#define CKA_SIGN_RECOVER
Definition: pkcs11t.h:468
#define CKA_DEFAULT_CMS_ATTRIBUTES
Definition: pkcs11t.h:555
#define CKA_KEY_GEN_MECHANISM
Definition: pkcs11t.h:498
#define CKA_DECRYPT
Definition: pkcs11t.h:464
#define CKA_OTP_TIME_INTERVAL
Definition: pkcs11t.h:522
#define CKA_EXPONENT_2
Definition: pkcs11t.h:481
#define CKA_VALUE_BITS
Definition: pkcs11t.h:492
#define CKA_DESTROYABLE
Definition: pkcs11t.h:503
#define CKA_HASH_OF_SUBJECT_PUBLIC_KEY
Definition: pkcs11t.h:454
#define CKA_PRIME_2
Definition: pkcs11t.h:479
#define CKA_MODIFIABLE
Definition: pkcs11t.h:500
#define CKA_WRAP_TEMPLATE
Definition: pkcs11t.h:516
#define CKA_OTP_SERVICE_IDENTIFIER
Definition: pkcs11t.h:531
#define CKA_AUTH_PIN_FLAGS
Definition: pkcs11t.h:511
#define CKA_PRIME_BITS
Definition: pkcs11t.h:488
#define CKA_START_DATE
Definition: pkcs11t.h:472
CertificateCategory
Definition: p11.h:185
#define CKA_OTP_CHALLENGE_REQUIREMENT
Definition: pkcs11t.h:524
#define CKA_VALUE_LEN
Definition: pkcs11t.h:493
#define CKA_MODULUS_BITS
Definition: pkcs11t.h:475
#define CKA_SUB_PRIME_BITS
Definition: pkcs11t.h:490
#define CKA_UNWRAP
Definition: pkcs11t.h:466
#define CKA_JAVA_MIDP_SECURITY_DOMAIN
Definition: pkcs11t.h:452
#define CKA_HASH_OF_ISSUER_PUBLIC_KEY
Definition: pkcs11t.h:455
#define CKA_CERTIFICATE_TYPE
Definition: pkcs11t.h:444
#define CKA_RESOLUTION
Definition: pkcs11t.h:545

◆ CertificateCategory

Indicates if a stored certificate is a user certificate for which the corresponding private key is available on the token ("token user"), a CA certificate ("authority"), or another end-entity certificate ("other entity").

Enumerator
Unspecified 
TokenUser 
Authority 
OtherEntity 

Definition at line 185 of file p11.h.

◆ CertificateType

Enumerator
X509 
X509AttrCert 
Wtls 
VendorDefined 

Definition at line 175 of file p11.h.

◆ Flag

Enumerator
None 
TokenPresent 
RemovableDevice 
HwSlot 
Rng 
WriteProtected 
LoginRequired 
UserPinInitialized 
RestoreKeyNotNeeded 
ClockOnToken 
ProtectedAuthenticationPath 
DualCryptoOperations 
TokenInitialized 
SecondaryAuthentication 
UserPinCountLow 
UserPinFinalTry 
UserPinLocked 
UserPinToBeChanged 
SoPinCountLow 
SoPinFinalTry 
SoPinLocked 
SoPinToBeChanged 
ErrorState 
RwSession 
SerialSession 
ArrayAttribute 
Hw 
Encrypt 
Decrypt 
Digest 
Sign 
SignRecover 
Verify 
VerifyRecover 
Generate 
GenerateKeyPair 
Wrap 
Unwrap 
Derive 
EcFP 
EcF2m 
EcEcparameters 
EcNamedcurve 
EcUncompress 
EcCompress 
Extension 
LibraryCantCreateOsThreads 
OsLockingOk 
DontBlock 
NextOtp 
ExcludeTime 
ExcludeCounter 
ExcludeChallenge 
ExcludePin 
UserFriendlyOtp 

Definition at line 206 of file p11.h.

206  : CK_FLAGS
207  {
208  None = 0,
212  Rng = CKF_RNG,
234  Hw = CKF_HW,
237  Digest = CKF_DIGEST,
238  Sign = CKF_SIGN,
240  Verify = CKF_VERIFY,
244  Wrap = CKF_WRAP,
245  Unwrap = CKF_UNWRAP,
246  Derive = CKF_DERIVE,
247  EcFP = CKF_EC_F_P,
248  EcF2m = CKF_EC_F_2M,
263  };
#define CKF_EXCLUDE_COUNTER
Definition: pkcs11t.h:1811
#define CKF_EC_NAMEDCURVE
Definition: pkcs11t.h:1025
#define CKF_USER_PIN_INITIALIZED
Definition: pkcs11t.h:158
#define CKF_SIGN
Definition: pkcs11t.h:1009
#define CKF_TOKEN_PRESENT
Definition: pkcs11t.h:122
#define CKF_EC_ECPARAMETERS
Definition: pkcs11t.h:1024
#define CKF_PROTECTED_AUTHENTICATION_PATH
Definition: pkcs11t.h:177
#define CKF_GENERATE_KEY_PAIR
Definition: pkcs11t.h:1014
#define CKF_LIBRARY_CANT_CREATE_OS_THREADS
Definition: pkcs11t.h:1225
#define CKF_ERROR_STATE
Definition: pkcs11t.h:248
#define CKF_SO_PIN_COUNT_LOW
Definition: pkcs11t.h:229
#define CKF_GENERATE
Definition: pkcs11t.h:1013
#define CKF_WRITE_PROTECTED
Definition: pkcs11t.h:156
#define CKF_USER_FRIENDLY_OTP
Definition: pkcs11t.h:1814
#define CKF_HW_SLOT
Definition: pkcs11t.h:124
#define CKF_REMOVABLE_DEVICE
Definition: pkcs11t.h:123
#define CKF_WRAP
Definition: pkcs11t.h:1015
#define CKF_LOGIN_REQUIRED
Definition: pkcs11t.h:157
#define CKF_NEXT_OTP
Definition: pkcs11t.h:1809
#define CKF_VERIFY_RECOVER
Definition: pkcs11t.h:1012
#define CKF_EXTENSION
Definition: pkcs11t.h:1029
#define CKF_HW
Definition: pkcs11t.h:1003
#define CKF_EC_UNCOMPRESS
Definition: pkcs11t.h:1026
#define CKF_OS_LOCKING_OK
Definition: pkcs11t.h:1226
#define CKF_DERIVE
Definition: pkcs11t.h:1017
#define CKF_EC_F_P
Definition: pkcs11t.h:1022
#define CKF_UNWRAP
Definition: pkcs11t.h:1016
#define CKF_RESTORE_KEY_NOT_NEEDED
Definition: pkcs11t.h:165
#define CKF_CLOCK_ON_TOKEN
Definition: pkcs11t.h:171
#define CKF_EC_COMPRESS
Definition: pkcs11t.h:1027
#define CKF_SECONDARY_AUTHENTICATION
Definition: pkcs11t.h:199
#define CKF_DUAL_CRYPTO_OPERATIONS
Definition: pkcs11t.h:185
#define CKF_SO_PIN_LOCKED
Definition: pkcs11t.h:239
#define CKF_USER_PIN_LOCKED
Definition: pkcs11t.h:216
#define CKF_USER_PIN_COUNT_LOW
Definition: pkcs11t.h:205
#define CKF_RW_SESSION
Definition: pkcs11t.h:289
#define CKF_SO_PIN_TO_BE_CHANGED
Definition: pkcs11t.h:246
#define CKF_VERIFY
Definition: pkcs11t.h:1011
#define CKF_SIGN_RECOVER
Definition: pkcs11t.h:1010
#define CKF_DECRYPT
Definition: pkcs11t.h:1007
#define CKF_SO_PIN_FINAL_TRY
Definition: pkcs11t.h:234
#define CKF_DONT_BLOCK
Definition: pkcs11t.h:1234
CK_ULONG CK_FLAGS
Definition: pkcs11t.h:54
#define CKF_DIGEST
Definition: pkcs11t.h:1008
#define CKF_ENCRYPT
Definition: pkcs11t.h:1006
#define CKF_RNG
Definition: pkcs11t.h:155
#define CKF_SERIAL_SESSION
Definition: pkcs11t.h:290
#define CKF_USER_PIN_TO_BE_CHANGED
Definition: pkcs11t.h:223
#define CKF_EXCLUDE_TIME
Definition: pkcs11t.h:1810
#define CKF_TOKEN_INITIALIZED
Definition: pkcs11t.h:193
#define CKF_EXCLUDE_PIN
Definition: pkcs11t.h:1813
#define CKF_EC_F_2M
Definition: pkcs11t.h:1023
#define CKF_ARRAY_ATTRIBUTE
Definition: pkcs11t.h:421
#define CKF_EXCLUDE_CHALLENGE
Definition: pkcs11t.h:1812
#define CKF_USER_PIN_FINAL_TRY
Definition: pkcs11t.h:210

◆ HardwareType

Enumerator
MonotonicCounter 
Clock 
UserInterface 
VendorDefined 

Definition at line 279 of file p11.h.

◆ KeyDerivation

Enumerator
Null 
Sha1Kdf 
Sha1KdfAsn1 
Sha1KdfConcatenate 
Sha224Kdf 
Sha256Kdf 
Sha384Kdf 
Sha512Kdf 
CpdiversifyKdf 

Definition at line 193 of file p11.h.

◆ KeyType

Enumerator
Rsa 
Dsa 
Dh 
Ecdsa 
Ec 
X942Dh 
Kea 
GenericSecret 
Rc2 
Rc4 
Des 
Des2 
Des3 
Cast 
Cast3 
Cast5 
Cast128 
Rc5 
Idea 
Skipjack 
Baton 
Juniper 
Cdmf 
Aes 
Blowfish 
Twofish 
Securid 
Hotp 
Acti 
Camellia 
Aria 
Md5Hmac 
Sha1Hmac 
Ripemd128Hmac 
Ripemd160Hmac 
Sha256Hmac 
Sha384Hmac 
Sha512Hmac 
Sha224Hmac 
Seed 
Gostr3410 
Gostr3411 
Gost28147 
VendorDefined 

Definition at line 287 of file p11.h.

287  : CK_KEY_TYPE
288  {
289  Rsa = CKK_RSA,
290  Dsa = CKK_DSA,
291  Dh = CKK_DH,
292  Ecdsa = CKK_ECDSA,
293  Ec = CKK_EC,
295  Kea = CKK_KEA,
297  Rc2 = CKK_RC2,
298  Rc4 = CKK_RC4,
299  Des = CKK_DES,
300  Des2 = CKK_DES2,
301  Des3 = CKK_DES3,
302  Cast = CKK_CAST,
303  Cast3 = CKK_CAST3,
304  Cast5 = CKK_CAST5,
306  Rc5 = CKK_RC5,
307  Idea = CKK_IDEA,
309  Baton = CKK_BATON,
311  Cdmf = CKK_CDMF,
312  Aes = CKK_AES,
316  Hotp = CKK_HOTP,
317  Acti = CKK_ACTI,
319  Aria = CKK_ARIA,
328  Seed = CKK_SEED,
333  };
#define CKK_RC2
Definition: pkcs11t.h:347
#define CKK_CAST128
Definition: pkcs11t.h:355
#define CKK_VENDOR_DEFINED
Definition: pkcs11t.h:387
#define CKK_SHA224_HMAC
Definition: pkcs11t.h:378
#define CKK_ARIA
Definition: pkcs11t.h:369
#define CKK_HOTP
Definition: pkcs11t.h:366
#define CKK_SHA256_HMAC
Definition: pkcs11t.h:375
#define CKK_CAST
Definition: pkcs11t.h:352
#define CKK_EC
Definition: pkcs11t.h:343
#define CKK_CAMELLIA
Definition: pkcs11t.h:368
#define CKK_SEED
Definition: pkcs11t.h:380
#define CKK_X9_42_DH
Definition: pkcs11t.h:344
#define CKK_MD5_HMAC
Definition: pkcs11t.h:371
#define CKK_DES2
Definition: pkcs11t.h:350
#define CKK_RC5
Definition: pkcs11t.h:356
#define CKK_ACTI
Definition: pkcs11t.h:367
#define CKK_GOSTR3410
Definition: pkcs11t.h:381
#define CKK_GENERIC_SECRET
Definition: pkcs11t.h:346
#define CKK_KEA
Definition: pkcs11t.h:345
#define CKK_CDMF
Definition: pkcs11t.h:361
CK_ULONG CK_KEY_TYPE
Definition: pkcs11t.h:336
#define CKK_SECURID
Definition: pkcs11t.h:365
#define CKK_AES
Definition: pkcs11t.h:362
#define CKK_JUNIPER
Definition: pkcs11t.h:360
#define CKK_SKIPJACK
Definition: pkcs11t.h:358
#define CKK_ECDSA
Definition: pkcs11t.h:342
#define CKK_GOST28147
Definition: pkcs11t.h:383
#define CKK_RIPEMD160_HMAC
Definition: pkcs11t.h:374
#define CKK_RSA
Definition: pkcs11t.h:339
#define CKK_RC4
Definition: pkcs11t.h:348
#define CKK_DES3
Definition: pkcs11t.h:351
#define CKK_TWOFISH
Definition: pkcs11t.h:364
#define CKK_SHA_1_HMAC
Definition: pkcs11t.h:372
#define CKK_CAST5
Definition: pkcs11t.h:354
#define CKK_BLOWFISH
Definition: pkcs11t.h:363
#define CKK_SHA384_HMAC
Definition: pkcs11t.h:376
#define CKK_DES
Definition: pkcs11t.h:349
#define CKK_CAST3
Definition: pkcs11t.h:353
#define CKK_SHA512_HMAC
Definition: pkcs11t.h:377
#define CKK_DH
Definition: pkcs11t.h:341
#define CKK_DSA
Definition: pkcs11t.h:340
#define CKK_RIPEMD128_HMAC
Definition: pkcs11t.h:373
#define CKK_IDEA
Definition: pkcs11t.h:357
#define CKK_GOSTR3411
Definition: pkcs11t.h:382
#define CKK_BATON
Definition: pkcs11t.h:359

◆ MechanismType

Enumerator
RsaPkcsKeyPairGen 
RsaPkcs 
Rsa9796 
RsaX509 
Md2RsaPkcs 
Md5RsaPkcs 
Sha1RsaPkcs 
Ripemd128RsaPkcs 
Ripemd160RsaPkcs 
RsaPkcsOaep 
RsaX931KeyPairGen 
RsaX931 
Sha1RsaX931 
RsaPkcsPss 
Sha1RsaPkcsPss 
DsaKeyPairGen 
Dsa 
DsaSha1 
DsaSha224 
DsaSha256 
DsaSha384 
DsaSha512 
DhPkcsKeyPairGen 
DhPkcsDerive 
X942DhKeyPairGen 
X942DhDerive 
X942DhHybridDerive 
X942MqvDerive 
Sha256RsaPkcs 
Sha384RsaPkcs 
Sha512RsaPkcs 
Sha256RsaPkcsPss 
Sha384RsaPkcsPss 
Sha512RsaPkcsPss 
Sha224RsaPkcs 
Sha224RsaPkcsPss 
Sha512224 
Sha512224Hmac 
Sha512224HmacGeneral 
Sha512224KeyDerivation 
Sha512256 
Sha512256Hmac 
Sha512256HmacGeneral 
Sha512256KeyDerivation 
Sha512T 
Sha512THmac 
Sha512THmacGeneral 
Sha512TKeyDerivation 
Rc2KeyGen 
Rc2Ecb 
Rc2Cbc 
Rc2Mac 
Rc2MacGeneral 
Rc2CbcPad 
Rc4KeyGen 
Rc4 
DesKeyGen 
DesEcb 
DesCbc 
DesMac 
DesMacGeneral 
DesCbcPad 
Des2KeyGen 
Des3KeyGen 
Des3Ecb 
Des3Cbc 
Des3Mac 
Des3MacGeneral 
Des3CbcPad 
Des3CmacGeneral 
Des3Cmac 
CdmfKeyGen 
CdmfEcb 
CdmfCbc 
CdmfMac 
CdmfMacGeneral 
CdmfCbcPad 
DesOfb64 
DesOfb8 
DesCfb64 
DesCfb8 
Md2 
Md2Hmac 
Md2HmacGeneral 
Md5 
Md5Hmac 
Md5HmacGeneral 
Sha1 
Sha1Hmac 
Sha1HmacGeneral 
Ripemd128 
Ripemd128Hmac 
Ripemd128HmacGeneral 
Ripemd160 
Ripemd160Hmac 
Ripemd160HmacGeneral 
Sha256 
Sha256Hmac 
Sha256HmacGeneral 
Sha224 
Sha224Hmac 
Sha224HmacGeneral 
Sha384 
Sha384Hmac 
Sha384HmacGeneral 
Sha512 
Sha512Hmac 
Sha512HmacGeneral 
SecuridKeyGen 
Securid 
HotpKeyGen 
Hotp 
Acti 
ActiKeyGen 
CastKeyGen 
CastEcb 
CastCbc 
CastMac 
CastMacGeneral 
CastCbcPad 
Cast3KeyGen 
Cast3Ecb 
Cast3Cbc 
Cast3Mac 
Cast3MacGeneral 
Cast3CbcPad 
Cast5KeyGen 
Cast128KeyGen 
Cast5Ecb 
Cast128Ecb 
Cast5Cbc 
Cast128Cbc 
Cast5Mac 
Cast128Mac 
Cast5MacGeneral 
Cast128MacGeneral 
Cast5CbcPad 
Cast128CbcPad 
Rc5KeyGen 
Rc5Ecb 
Rc5Cbc 
Rc5Mac 
Rc5MacGeneral 
Rc5CbcPad 
IdeaKeyGen 
IdeaEcb 
IdeaCbc 
IdeaMac 
IdeaMacGeneral 
IdeaCbcPad 
GenericSecretKeyGen 
ConcatenateBaseAndKey 
ConcatenateBaseAndData 
ConcatenateDataAndBase 
XorBaseAndData 
ExtractKeyFromKey 
Ssl3PreMasterKeyGen 
Ssl3MasterKeyDerive 
Ssl3KeyAndMacDerive 
Ssl3MasterKeyDeriveDh 
TlsPreMasterKeyGen 
TlsMasterKeyDerive 
TlsKeyAndMacDerive 
TlsMasterKeyDeriveDh 
TlsPrf 
Ssl3Md5Mac 
Ssl3Sha1Mac 
Md5KeyDerivation 
Md2KeyDerivation 
Sha1KeyDerivation 
Sha256KeyDerivation 
Sha384KeyDerivation 
Sha512KeyDerivation 
Sha224KeyDerivation 
PbeMd2DesCbc 
PbeMd5DesCbc 
PbeMd5CastCbc 
PbeMd5Cast3Cbc 
PbeMd5Cast5Cbc 
PbeMd5Cast128Cbc 
PbeSha1Cast5Cbc 
PbeSha1Cast128Cbc 
PbeSha1Rc4128 
PbeSha1Rc440 
PbeSha1Des3EdeCbc 
PbeSha1Des2EdeCbc 
PbeSha1Rc2128Cbc 
PbeSha1Rc240Cbc 
Pkcs5Pbkd2 
PbaSha1WithSha1Hmac 
WtlsPreMasterKeyGen 
WtlsMasterKeyDerive 
WtlsMasterKeyDeriveDhEcc 
WtlsPrf 
WtlsServerKeyAndMacDerive 
WtlsClientKeyAndMacDerive 
Tls10MacServer 
Tls10MacClient 
Tls12Mac 
Tls12Kdf 
Tls12MasterKeyDerive 
Tls12KeyAndMacDerive 
Tls12MasterKeyDeriveDh 
Tls12KeySafeDerive 
TlsMac 
TlsKdf 
KeyWrapLynks 
KeyWrapSetOaep 
CmsSig 
KipDerive 
KipWrap 
KipMac 
CamelliaKeyGen 
CamelliaEcb 
CamelliaCbc 
CamelliaMac 
CamelliaMacGeneral 
CamelliaCbcPad 
CamelliaEcbEncryptData 
CamelliaCbcEncryptData 
CamelliaCtr 
AriaKeyGen 
AriaEcb 
AriaCbc 
AriaMac 
AriaMacGeneral 
AriaCbcPad 
AriaEcbEncryptData 
AriaCbcEncryptData 
SeedKeyGen 
SeedEcb 
SeedCbc 
SeedMac 
SeedMacGeneral 
SeedCbcPad 
SeedEcbEncryptData 
SeedCbcEncryptData 
SkipjackKeyGen 
SkipjackEcb64 
SkipjackCbc64 
SkipjackOfb64 
SkipjackCfb64 
SkipjackCfb32 
SkipjackCfb16 
SkipjackCfb8 
SkipjackWrap 
SkipjackPrivateWrap 
SkipjackRelayx 
KeaKeyPairGen 
KeaKeyDerive 
KeaDerive 
FortezzaTimestamp 
BatonKeyGen 
BatonEcb128 
BatonEcb96 
BatonCbc128 
BatonCounter 
BatonShuffle 
BatonWrap 
EcdsaKeyPairGen 
EcKeyPairGen 
Ecdsa 
EcdsaSha1 
EcdsaSha224 
EcdsaSha256 
EcdsaSha384 
EcdsaSha512 
Ecdh1Derive 
Ecdh1CofactorDerive 
EcmqvDerive 
EcdhAesKeyWrap 
RsaAesKeyWrap 
JuniperKeyGen 
JuniperEcb128 
JuniperCbc128 
JuniperCounter 
JuniperShuffle 
JuniperWrap 
Fasthash 
AesKeyGen 
AesEcb 
AesCbc 
AesMac 
AesMacGeneral 
AesCbcPad 
AesCtr 
AesGcm 
AesCcm 
AesCts 
AesCmac 
AesCmacGeneral 
AesXcbcMac 
AesXcbcMac96 
AesGmac 
BlowfishKeyGen 
BlowfishCbc 
TwofishKeyGen 
TwofishCbc 
BlowfishCbcPad 
TwofishCbcPad 
DesEcbEncryptData 
DesCbcEncryptData 
Des3EcbEncryptData 
Des3CbcEncryptData 
AesEcbEncryptData 
AesCbcEncryptData 
Gostr3410KeyPairGen 
Gostr3410 
Gostr3410WithGostr3411 
Gostr3410KeyWrap 
Gostr3410Derive 
Gostr3411 
Gostr3411Hmac 
Gost28147KeyGen 
Gost28147Ecb 
Gost28147 
Gost28147Mac 
Gost28147KeyWrap 
DsaParameterGen 
DhPkcsParameterGen 
X942DhParameterGen 
DsaProbablisticParameterGen 
DsaShaweTaylorParameterGen 
AesOfb 
AesCfb64 
AesCfb8 
AesCfb128 
AesCfb1 
AesKeyWrap 
AesKeyWrapPad 
RsaPkcsTpm11 
RsaPkcsOaepTpm11 
VendorDefined 

Definition at line 335 of file p11.h.

336  {
353  Dsa = CKM_DSA,
392  Rc4 = CKM_RC4,
418  Md2 = CKM_MD2,
421  Md5 = CKM_MD5,
424  Sha1 = CKM_SHA_1,
433  Sha256 = CKM_SHA256,
436  Sha224 = CKM_SHA224,
439  Sha384 = CKM_SHA384,
442  Sha512 = CKM_SHA512,
448  Hotp = CKM_HOTP,
449  Acti = CKM_ACTI,
598  Ecdsa = CKM_ECDSA,
670  };
#define CKM_DES3_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:940
#define CKM_HOTP_KEY_GEN
Definition: pkcs11t.h:721
#define CKM_AES_CFB64
Definition: pkcs11t.h:964
#define CKM_CAST128_CBC
Definition: pkcs11t.h:744
#define CKM_SHA512_RSA_PKCS_PSS
Definition: pkcs11t.h:626
#define CKM_DSA_PARAMETER_GEN
Definition: pkcs11t.h:957
#define CKM_AES_CMAC_GENERAL
Definition: pkcs11t.h:924
#define CKM_SHA_1_HMAC_GENERAL
Definition: pkcs11t.h:698
#define CKM_XOR_BASE_AND_DATA
Definition: pkcs11t.h:767
#define CKM_SHA384_KEY_DERIVATION
Definition: pkcs11t.h:788
#define CKM_KEA_DERIVE
Definition: pkcs11t.h:878
#define CKM_TLS_PRE_MASTER_KEY_GEN
Definition: pkcs11t.h:774
#define CKM_RIPEMD128_HMAC_GENERAL
Definition: pkcs11t.h:702
#define CKM_PBE_MD5_CAST_CBC
Definition: pkcs11t.h:794
#define CKM_RSA_X_509
Definition: pkcs11t.h:589
#define CKM_DES_CFB8
Definition: pkcs11t.h:683
#define CKM_WTLS_MASTER_KEY_DERIVE_DH_ECC
Definition: pkcs11t.h:813
#define CKM_KEY_WRAP_LYNKS
Definition: pkcs11t.h:829
#define CKM_CAST_KEY_GEN
Definition: pkcs11t.h:726
#define CKM_SHA512_RSA_PKCS
Definition: pkcs11t.h:623
#define CKM_IDEA_KEY_GEN
Definition: pkcs11t.h:757
#define CKM_SHA224_RSA_PKCS
Definition: pkcs11t.h:628
#define CKM_SEED_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:863
#define CKM_GOSTR3410_WITH_GOSTR3411
Definition: pkcs11t.h:946
#define CKM_SHA256_HMAC
Definition: pkcs11t.h:708
#define CKM_CAMELLIA_MAC_GENERAL
Definition: pkcs11t.h:841
#define CKM_PBE_SHA1_RC2_128_CBC
Definition: pkcs11t.h:804
#define CKM_DES3_CMAC_GENERAL
Definition: pkcs11t.h:671
#define CKM_CDMF_CBC
Definition: pkcs11t.h:675
#define CKM_CAST5_CBC
Definition: pkcs11t.h:743
#define CKM_RC2_ECB
Definition: pkcs11t.h:646
#define CKM_SHA512_HMAC
Definition: pkcs11t.h:717
#define CKM_TLS_KDF
Definition: pkcs11t.h:827
CK_ULONG CK_MECHANISM_TYPE
Definition: pkcs11t.h:583
#define CKM_ARIA_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:853
#define CKM_PBE_MD5_CAST5_CBC
Definition: pkcs11t.h:796
#define CKM_BATON_WRAP
Definition: pkcs11t.h:886
#define CKM_SEED_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:862
#define CKM_SKIPJACK_CFB8
Definition: pkcs11t.h:872
#define CKM_ECDSA_SHA256
Definition: pkcs11t.h:894
#define CKM_ECDSA_SHA224
Definition: pkcs11t.h:893
#define CKM_PBA_SHA1_WITH_SHA1_HMAC
Definition: pkcs11t.h:809
#define CKM_JUNIPER_COUNTER
Definition: pkcs11t.h:908
#define CKM_DSA_SHA512
Definition: pkcs11t.h:611
#define CKM_CAMELLIA_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:844
#define CKM_CAST5_ECB
Definition: pkcs11t.h:741
#define CKM_CAST3_KEY_GEN
Definition: pkcs11t.h:732
#define CKM_WTLS_SERVER_KEY_AND_MAC_DERIVE
Definition: pkcs11t.h:815
#define CKM_CDMF_CBC_PAD
Definition: pkcs11t.h:678
#define CKM_DES3_CMAC
Definition: pkcs11t.h:672
#define CKM_SKIPJACK_WRAP
Definition: pkcs11t.h:873
#define CKM_RC2_KEY_GEN
Definition: pkcs11t.h:645
#define CKM_RSA_PKCS_TPM_1_1
Definition: pkcs11t.h:972
#define CKM_RSA_PKCS
Definition: pkcs11t.h:587
#define CKM_CDMF_MAC
Definition: pkcs11t.h:676
#define CKM_RSA_PKCS_KEY_PAIR_GEN
Definition: pkcs11t.h:586
#define CKM_SKIPJACK_KEY_GEN
Definition: pkcs11t.h:865
#define CKM_CAMELLIA_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:843
#define CKM_AES_KEY_WRAP
Definition: pkcs11t.h:969
#define CKM_CAST_MAC_GENERAL
Definition: pkcs11t.h:730
#define CKM_RC5_CBC_PAD
Definition: pkcs11t.h:756
#define CKM_IDEA_CBC
Definition: pkcs11t.h:759
#define CKM_MD5_RSA_PKCS
Definition: pkcs11t.h:592
#define CKM_SHA512_224_KEY_DERIVATION
Definition: pkcs11t.h:634
#define CKM_SKIPJACK_CFB32
Definition: pkcs11t.h:870
#define CKM_SHA512_HMAC_GENERAL
Definition: pkcs11t.h:718
#define CKM_AES_CFB128
Definition: pkcs11t.h:966
#define CKM_CAMELLIA_CBC_PAD
Definition: pkcs11t.h:842
#define CKM_DES3_CBC
Definition: pkcs11t.h:666
#define CKM_DES_CFB64
Definition: pkcs11t.h:682
#define CKM_TLS12_MAC
Definition: pkcs11t.h:820
#define CKM_SSL3_MASTER_KEY_DERIVE
Definition: pkcs11t.h:770
#define CKM_AES_KEY_GEN
Definition: pkcs11t.h:913
#define CKM_CONCATENATE_BASE_AND_DATA
Definition: pkcs11t.h:765
#define CKM_CAST128_MAC_GENERAL
Definition: pkcs11t.h:748
#define CKM_KEA_KEY_DERIVE
Definition: pkcs11t.h:877
#define CKM_TLS10_MAC_CLIENT
Definition: pkcs11t.h:819
#define CKM_PBE_SHA1_RC4_40
Definition: pkcs11t.h:801
#define CKM_CAST3_CBC_PAD
Definition: pkcs11t.h:737
#define CKM_RIPEMD128_RSA_PKCS
Definition: pkcs11t.h:595
#define CKM_RC2_CBC
Definition: pkcs11t.h:647
#define CKM_TLS_MASTER_KEY_DERIVE_DH
Definition: pkcs11t.h:777
#define CKM_TWOFISH_CBC_PAD
Definition: pkcs11t.h:935
#define CKM_KIP_WRAP
Definition: pkcs11t.h:834
#define CKM_SSL3_MD5_MAC
Definition: pkcs11t.h:781
#define CKM_BATON_COUNTER
Definition: pkcs11t.h:884
#define CKM_BATON_ECB96
Definition: pkcs11t.h:882
#define CKM_GOSTR3410
Definition: pkcs11t.h:945
#define CKM_PBE_SHA1_DES3_EDE_CBC
Definition: pkcs11t.h:802
#define CKM_SHA512_224
Definition: pkcs11t.h:631
#define CKM_TWOFISH_KEY_GEN
Definition: pkcs11t.h:932
#define CKM_SHA224
Definition: pkcs11t.h:710
#define CKM_RC5_MAC_GENERAL
Definition: pkcs11t.h:755
#define CKM_BLOWFISH_KEY_GEN
Definition: pkcs11t.h:930
#define CKM_SEED_MAC
Definition: pkcs11t.h:859
#define CKM_RSA_9796
Definition: pkcs11t.h:588
#define CKM_PBE_SHA1_RC2_40_CBC
Definition: pkcs11t.h:805
#define CKM_DES3_CBC_PAD
Definition: pkcs11t.h:670
#define CKM_RC4
Definition: pkcs11t.h:654
#define CKM_DES_OFB64
Definition: pkcs11t.h:680
#define CKM_AES_CTR
Definition: pkcs11t.h:919
#define CKM_ECDSA_SHA1
Definition: pkcs11t.h:892
#define CKM_CAST128_ECB
Definition: pkcs11t.h:742
#define CKM_SSL3_PRE_MASTER_KEY_GEN
Definition: pkcs11t.h:769
#define CKM_SHA512_T_HMAC_GENERAL
Definition: pkcs11t.h:642
#define CKM_MD2_HMAC
Definition: pkcs11t.h:687
#define CKM_AES_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:941
#define CKM_AES_XCBC_MAC_96
Definition: pkcs11t.h:927
#define CKM_ACTI_KEY_GEN
Definition: pkcs11t.h:724
#define CKM_SHA1_RSA_X9_31
Definition: pkcs11t.h:601
#define CKM_AES_CCM
Definition: pkcs11t.h:921
#define CKM_TLS12_KDF
Definition: pkcs11t.h:821
#define CKM_DH_PKCS_PARAMETER_GEN
Definition: pkcs11t.h:958
#define CKM_SHA1_RSA_PKCS_PSS
Definition: pkcs11t.h:603
#define CKM_TLS10_MAC_SERVER
Definition: pkcs11t.h:818
#define CKM_VENDOR_DEFINED
Definition: pkcs11t.h:975
#define CKM_PBE_SHA1_DES2_EDE_CBC
Definition: pkcs11t.h:803
#define CKM_PBE_MD5_DES_CBC
Definition: pkcs11t.h:793
#define CKM_SHA256
Definition: pkcs11t.h:707
#define CKM_RC2_MAC
Definition: pkcs11t.h:648
#define CKM_TLS_PRF
Definition: pkcs11t.h:779
#define CKM_X9_42_MQV_DERIVE
Definition: pkcs11t.h:619
#define CKM_RIPEMD128
Definition: pkcs11t.h:700
#define CKM_MD5_KEY_DERIVATION
Definition: pkcs11t.h:783
#define CKM_ECDSA_SHA384
Definition: pkcs11t.h:895
#define CKM_SHA1_KEY_DERIVATION
Definition: pkcs11t.h:785
#define CKM_DSA_SHA224
Definition: pkcs11t.h:608
#define CKM_SHA1_RSA_PKCS
Definition: pkcs11t.h:593
#define CKM_AES_CFB1
Definition: pkcs11t.h:968
#define CKM_MD2_KEY_DERIVATION
Definition: pkcs11t.h:784
#define CKM_DES_CBC
Definition: pkcs11t.h:657
#define CKM_SHA384_HMAC
Definition: pkcs11t.h:714
#define CKM_SHA512_224_HMAC_GENERAL
Definition: pkcs11t.h:633
#define CKM_DES_CBC_PAD
Definition: pkcs11t.h:661
#define CKM_RSA_AES_KEY_WRAP
Definition: pkcs11t.h:903
#define CKM_FASTHASH
Definition: pkcs11t.h:911
#define CKM_CONCATENATE_BASE_AND_KEY
Definition: pkcs11t.h:764
#define CKM_ECDSA
Definition: pkcs11t.h:891
#define CKM_BATON_ECB128
Definition: pkcs11t.h:881
#define CKM_SHA512_T_KEY_DERIVATION
Definition: pkcs11t.h:643
#define CKM_AES_CBC_PAD
Definition: pkcs11t.h:918
#define CKM_ARIA_ECB
Definition: pkcs11t.h:848
#define CKM_AES_GCM
Definition: pkcs11t.h:920
#define CKM_KEY_WRAP_SET_OAEP
Definition: pkcs11t.h:830
#define CKM_SEED_MAC_GENERAL
Definition: pkcs11t.h:860
#define CKM_AES_CMAC
Definition: pkcs11t.h:923
#define CKM_FORTEZZA_TIMESTAMP
Definition: pkcs11t.h:879
#define CKM_JUNIPER_KEY_GEN
Definition: pkcs11t.h:905
#define CKM_SHA384_RSA_PKCS
Definition: pkcs11t.h:622
#define CKM_SEED_CBC
Definition: pkcs11t.h:858
#define CKM_AES_OFB
Definition: pkcs11t.h:963
#define CKM_GOST28147_KEY_GEN
Definition: pkcs11t.h:951
#define CKM_ECDSA_SHA512
Definition: pkcs11t.h:896
#define CKM_AES_MAC
Definition: pkcs11t.h:916
#define CKM_AES_MAC_GENERAL
Definition: pkcs11t.h:917
#define CKM_GENERIC_SECRET_KEY_GEN
Definition: pkcs11t.h:763
#define CKM_SHA256_HMAC_GENERAL
Definition: pkcs11t.h:709
#define CKM_BATON_SHUFFLE
Definition: pkcs11t.h:885
#define CKM_DSA_PROBABLISTIC_PARAMETER_GEN
Definition: pkcs11t.h:960
#define CKM_DES_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:937
#define CKM_BATON_KEY_GEN
Definition: pkcs11t.h:880
#define CKM_TLS12_KEY_AND_MAC_DERIVE
Definition: pkcs11t.h:823
#define CKM_GOSTR3410_KEY_PAIR_GEN
Definition: pkcs11t.h:944
#define CKM_RIPEMD128_HMAC
Definition: pkcs11t.h:701
#define CKM_X9_42_DH_HYBRID_DERIVE
Definition: pkcs11t.h:618
#define CKM_JUNIPER_ECB128
Definition: pkcs11t.h:906
#define CKM_PBE_SHA1_CAST128_CBC
Definition: pkcs11t.h:799
#define CKM_DES3_ECB
Definition: pkcs11t.h:665
#define CKM_GOSTR3411
Definition: pkcs11t.h:949
#define CKM_SECURID_KEY_GEN
Definition: pkcs11t.h:719
#define CKM_ARIA_MAC
Definition: pkcs11t.h:850
#define CKM_WTLS_CLIENT_KEY_AND_MAC_DERIVE
Definition: pkcs11t.h:816
#define CKM_MD5_HMAC
Definition: pkcs11t.h:692
#define CKM_CAST_CBC
Definition: pkcs11t.h:728
#define CKM_PBE_SHA1_CAST5_CBC
Definition: pkcs11t.h:798
#define CKM_KIP_MAC
Definition: pkcs11t.h:835
#define CKM_SHA384_HMAC_GENERAL
Definition: pkcs11t.h:715
#define CKM_SHA512_KEY_DERIVATION
Definition: pkcs11t.h:789
#define CKM_IDEA_ECB
Definition: pkcs11t.h:758
#define CKM_ECDSA_KEY_PAIR_GEN
Definition: pkcs11t.h:888
#define CKM_TLS12_KEY_SAFE_DERIVE
Definition: pkcs11t.h:825
#define CKM_RC5_CBC
Definition: pkcs11t.h:753
#define CKM_ECDH1_DERIVE
Definition: pkcs11t.h:898
#define CKM_DES_ECB
Definition: pkcs11t.h:656
#define CKM_DES3_KEY_GEN
Definition: pkcs11t.h:664
#define CKM_CAST3_CBC
Definition: pkcs11t.h:734
#define CKM_AES_CTS
Definition: pkcs11t.h:922
#define CKM_AES_CFB8
Definition: pkcs11t.h:965
#define CKM_MD5
Definition: pkcs11t.h:690
#define CKM_CAMELLIA_ECB
Definition: pkcs11t.h:838
#define CKM_EC_KEY_PAIR_GEN
Definition: pkcs11t.h:889
#define CKM_RC5_KEY_GEN
Definition: pkcs11t.h:751
#define CKM_MD5_HMAC_GENERAL
Definition: pkcs11t.h:693
#define CKM_GOST28147
Definition: pkcs11t.h:953
#define CKM_CONCATENATE_DATA_AND_BASE
Definition: pkcs11t.h:766
#define CKM_SKIPJACK_RELAYX
Definition: pkcs11t.h:875
#define CKM_WTLS_MASTER_KEY_DERIVE
Definition: pkcs11t.h:812
#define CKM_SHA512
Definition: pkcs11t.h:716
#define CKM_JUNIPER_CBC128
Definition: pkcs11t.h:907
#define CKM_CAMELLIA_CTR
Definition: pkcs11t.h:845
#define CKM_SHA512_256
Definition: pkcs11t.h:635
#define CKM_GOSTR3410_DERIVE
Definition: pkcs11t.h:948
#define CKM_MD2_RSA_PKCS
Definition: pkcs11t.h:591
#define CKM_RSA_PKCS_PSS
Definition: pkcs11t.h:602
#define CKM_CMS_SIG
Definition: pkcs11t.h:832
#define CKM_MD2_HMAC_GENERAL
Definition: pkcs11t.h:688
#define CKM_SHA384_RSA_PKCS_PSS
Definition: pkcs11t.h:625
#define CKM_DES_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:938
#define CKM_DES_KEY_GEN
Definition: pkcs11t.h:655
#define CKM_TLS_MASTER_KEY_DERIVE
Definition: pkcs11t.h:775
#define CKM_WTLS_PRF
Definition: pkcs11t.h:814
#define CKM_AES_ECB
Definition: pkcs11t.h:914
#define CKM_CAST3_MAC
Definition: pkcs11t.h:735
#define CKM_JUNIPER_SHUFFLE
Definition: pkcs11t.h:909
#define CKM_RIPEMD160_HMAC
Definition: pkcs11t.h:704
#define CKM_SKIPJACK_OFB64
Definition: pkcs11t.h:868
#define CKM_CAST_ECB
Definition: pkcs11t.h:727
#define CKM_SKIPJACK_CBC64
Definition: pkcs11t.h:867
#define CKM_RC5_MAC
Definition: pkcs11t.h:754
#define CKM_CAST5_CBC_PAD
Definition: pkcs11t.h:749
#define CKM_CAST5_MAC_GENERAL
Definition: pkcs11t.h:747
#define CKM_ECDH1_COFACTOR_DERIVE
Definition: pkcs11t.h:899
#define CKM_CDMF_KEY_GEN
Definition: pkcs11t.h:673
#define CKM_CAMELLIA_CBC
Definition: pkcs11t.h:839
#define CKM_SHA224_HMAC_GENERAL
Definition: pkcs11t.h:712
#define CKM_JUNIPER_WRAP
Definition: pkcs11t.h:910
#define CKM_SHA512_256_HMAC_GENERAL
Definition: pkcs11t.h:637
#define CKM_AES_KEY_WRAP_PAD
Definition: pkcs11t.h:970
#define CKM_TLS12_MASTER_KEY_DERIVE_DH
Definition: pkcs11t.h:824
#define CKM_CAST128_MAC
Definition: pkcs11t.h:746
#define CKM_CAST_MAC
Definition: pkcs11t.h:729
#define CKM_DES3_MAC_GENERAL
Definition: pkcs11t.h:669
#define CKM_PKCS5_PBKD2
Definition: pkcs11t.h:807
#define CKM_X9_42_DH_PARAMETER_GEN
Definition: pkcs11t.h:959
#define CKM_KIP_DERIVE
Definition: pkcs11t.h:833
#define CKM_AES_XCBC_MAC
Definition: pkcs11t.h:926
#define CKM_RIPEMD160_HMAC_GENERAL
Definition: pkcs11t.h:705
#define CKM_SKIPJACK_ECB64
Definition: pkcs11t.h:866
#define CKM_SSL3_KEY_AND_MAC_DERIVE
Definition: pkcs11t.h:771
#define CKM_RC2_CBC_PAD
Definition: pkcs11t.h:651
#define CKM_ARIA_MAC_GENERAL
Definition: pkcs11t.h:851
#define CKM_EXTRACT_KEY_FROM_KEY
Definition: pkcs11t.h:768
#define CKM_BATON_CBC128
Definition: pkcs11t.h:883
#define CKM_RSA_PKCS_OAEP_TPM_1_1
Definition: pkcs11t.h:973
#define CKM_CAST3_ECB
Definition: pkcs11t.h:733
#define CKM_IDEA_MAC
Definition: pkcs11t.h:760
#define CKM_KEA_KEY_PAIR_GEN
Definition: pkcs11t.h:876
#define CKM_GOST28147_KEY_WRAP
Definition: pkcs11t.h:955
#define CKM_TLS_MAC
Definition: pkcs11t.h:826
#define CKM_AES_CBC
Definition: pkcs11t.h:915
#define CKM_DES_OFB8
Definition: pkcs11t.h:681
#define CKM_PBE_MD2_DES_CBC
Definition: pkcs11t.h:792
#define CKM_CDMF_ECB
Definition: pkcs11t.h:674
#define CKM_SHA512_T
Definition: pkcs11t.h:640
#define CKM_DSA_KEY_PAIR_GEN
Definition: pkcs11t.h:605
#define CKM_ARIA_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:854
#define CKM_DES3_MAC
Definition: pkcs11t.h:667
#define CKM_DSA_SHA1
Definition: pkcs11t.h:607
#define CKM_GOST28147_MAC
Definition: pkcs11t.h:954
#define CKM_WTLS_PRE_MASTER_KEY_GEN
Definition: pkcs11t.h:811
#define CKM_GOSTR3411_HMAC
Definition: pkcs11t.h:950
#define CKM_DES3_ECB_ENCRYPT_DATA
Definition: pkcs11t.h:939
#define CKM_ECDH_AES_KEY_WRAP
Definition: pkcs11t.h:902
#define CKM_PBE_SHA1_RC4_128
Definition: pkcs11t.h:800
#define CKM_SHA224_KEY_DERIVATION
Definition: pkcs11t.h:790
#define CKM_CAST3_MAC_GENERAL
Definition: pkcs11t.h:736
#define CKM_GOSTR3410_KEY_WRAP
Definition: pkcs11t.h:947
#define CKM_AES_GMAC
Definition: pkcs11t.h:928
#define CKM_RIPEMD160
Definition: pkcs11t.h:703
#define CKM_DSA_SHAWE_TAYLOR_PARAMETER_GEN
Definition: pkcs11t.h:961
#define CKM_CAST_CBC_PAD
Definition: pkcs11t.h:731
#define CKM_SHA512_256_HMAC
Definition: pkcs11t.h:636
#define CKM_PBE_MD5_CAST3_CBC
Definition: pkcs11t.h:795
#define CKM_SHA512_256_KEY_DERIVATION
Definition: pkcs11t.h:638
#define CKM_SKIPJACK_PRIVATE_WRAP
Definition: pkcs11t.h:874
#define CKM_RC4_KEY_GEN
Definition: pkcs11t.h:653
#define CKM_ACTI
Definition: pkcs11t.h:723
#define CKM_SHA224_HMAC
Definition: pkcs11t.h:711
#define CKM_SEED_KEY_GEN
Definition: pkcs11t.h:856
#define CKM_RSA_PKCS_OAEP
Definition: pkcs11t.h:597
#define CKM_SEED_ECB
Definition: pkcs11t.h:857
#define CKM_ARIA_KEY_GEN
Definition: pkcs11t.h:847
#define CKM_CAMELLIA_KEY_GEN
Definition: pkcs11t.h:837
#define CKM_SHA512_T_HMAC
Definition: pkcs11t.h:641
#define CKM_CAST5_MAC
Definition: pkcs11t.h:745
#define CKM_DH_PKCS_KEY_PAIR_GEN
Definition: pkcs11t.h:613
#define CKM_CAST128_CBC_PAD
Definition: pkcs11t.h:750
#define CKM_RIPEMD160_RSA_PKCS
Definition: pkcs11t.h:596
#define CKM_CAMELLIA_MAC
Definition: pkcs11t.h:840
#define CKM_RC5_ECB
Definition: pkcs11t.h:752
#define CKM_DSA
Definition: pkcs11t.h:606
#define CKM_TWOFISH_CBC
Definition: pkcs11t.h:933
#define CKM_RSA_X9_31
Definition: pkcs11t.h:600
#define CKM_SHA224_RSA_PKCS_PSS
Definition: pkcs11t.h:629
#define CKM_SHA512_224_HMAC
Definition: pkcs11t.h:632
#define CKM_SHA384
Definition: pkcs11t.h:713
#define CKM_SKIPJACK_CFB16
Definition: pkcs11t.h:871
#define CKM_DES2_KEY_GEN
Definition: pkcs11t.h:663
#define CKM_AES_CBC_ENCRYPT_DATA
Definition: pkcs11t.h:942
#define CKM_SHA256_RSA_PKCS
Definition: pkcs11t.h:621
#define CKM_CDMF_MAC_GENERAL
Definition: pkcs11t.h:677
#define CKM_RSA_X9_31_KEY_PAIR_GEN
Definition: pkcs11t.h:599
#define CKM_MD2
Definition: pkcs11t.h:685
#define CKM_BLOWFISH_CBC
Definition: pkcs11t.h:931
#define CKM_DES_MAC
Definition: pkcs11t.h:658
#define CKM_ARIA_CBC_PAD
Definition: pkcs11t.h:852
#define CKM_SECURID
Definition: pkcs11t.h:720
#define CKM_ARIA_CBC
Definition: pkcs11t.h:849
#define CKM_SEED_CBC_PAD
Definition: pkcs11t.h:861
#define CKM_RC2_MAC_GENERAL
Definition: pkcs11t.h:650
#define CKM_X9_42_DH_DERIVE
Definition: pkcs11t.h:617
#define CKM_ECMQV_DERIVE
Definition: pkcs11t.h:900
#define CKM_SSL3_SHA1_MAC
Definition: pkcs11t.h:782
#define CKM_SHA256_KEY_DERIVATION
Definition: pkcs11t.h:787
#define CKM_DES_MAC_GENERAL
Definition: pkcs11t.h:660
#define CKM_X9_42_DH_KEY_PAIR_GEN
Definition: pkcs11t.h:616
#define CKM_TLS_KEY_AND_MAC_DERIVE
Definition: pkcs11t.h:776
#define CKM_DSA_SHA256
Definition: pkcs11t.h:609
#define CKM_DH_PKCS_DERIVE
Definition: pkcs11t.h:614
#define CKM_TLS12_MASTER_KEY_DERIVE
Definition: pkcs11t.h:822
#define CKM_HOTP
Definition: pkcs11t.h:722
#define CKM_PBE_MD5_CAST128_CBC
Definition: pkcs11t.h:797
#define CKM_IDEA_MAC_GENERAL
Definition: pkcs11t.h:761
#define CKM_BLOWFISH_CBC_PAD
Definition: pkcs11t.h:934
#define CKM_SHA_1_HMAC
Definition: pkcs11t.h:697
#define CKM_SHA_1
Definition: pkcs11t.h:695
#define CKM_DSA_SHA384
Definition: pkcs11t.h:610
#define CKM_SSL3_MASTER_KEY_DERIVE_DH
Definition: pkcs11t.h:773
#define CKM_GOST28147_ECB
Definition: pkcs11t.h:952
#define CKM_CAST128_KEY_GEN
Definition: pkcs11t.h:740
#define CKM_CAST5_KEY_GEN
Definition: pkcs11t.h:739
#define CKM_SKIPJACK_CFB64
Definition: pkcs11t.h:869
#define CKM_SHA256_RSA_PKCS_PSS
Definition: pkcs11t.h:624
#define CKM_IDEA_CBC_PAD
Definition: pkcs11t.h:762

◆ MGF

Enumerator
Mgf1Sha1 
Mgf1Sha256 
Mgf1Sha384 
Mgf1Sha512 
Mgf1Sha224 

Definition at line 270 of file p11.h.

◆ Notification

Enumerator
Surrender 
OtpChanged 

Definition at line 672 of file p11.h.

673  {
676  };
CK_ULONG CK_NOTIFICATION
Definition: pkcs11t.h:100
#define CKN_OTP_CHANGED
Definition: pkcs11t.h:102
#define CKN_SURRENDER
Definition: pkcs11t.h:101

◆ ObjectClass

Enumerator
Data 
Certificate 
PublicKey 
PrivateKey 
SecretKey 
HwFeature 
DomainParameters 
Mechanism 
OtpKey 
VendorDefined 

Definition at line 678 of file p11.h.

◆ PseudoRandom

Enumerator
Pkcs5Pbkd2HmacSha1 
Pkcs5Pbkd2HmacGostr3411 
Pkcs5Pbkd2HmacSha224 
Pkcs5Pbkd2HmacSha256 
Pkcs5Pbkd2HmacSha384 
Pkcs5Pbkd2HmacSha512 
Pkcs5Pbkd2HmacSha512224 
Pkcs5Pbkd2HmacSha512256 

Definition at line 692 of file p11.h.

693  {
702  };
#define CKP_PKCS5_PBKD2_HMAC_SHA512
Definition: pkcs11t.h:1724
#define CKP_PKCS5_PBKD2_HMAC_SHA512_224
Definition: pkcs11t.h:1725
#define CKP_PKCS5_PBKD2_HMAC_GOSTR3411
Definition: pkcs11t.h:1720
#define CKP_PKCS5_PBKD2_HMAC_SHA1
Definition: pkcs11t.h:1719
#define CKP_PKCS5_PBKD2_HMAC_SHA256
Definition: pkcs11t.h:1722
#define CKP_PKCS5_PBKD2_HMAC_SHA224
Definition: pkcs11t.h:1721
#define CKP_PKCS5_PBKD2_HMAC_SHA512_256
Definition: pkcs11t.h:1726
#define CKP_PKCS5_PBKD2_HMAC_SHA384
Definition: pkcs11t.h:1723
CK_ULONG CK_PKCS5_PBKD2_PSEUDO_RANDOM_FUNCTION_TYPE
Definition: pkcs11t.h:1714

◆ PublicPointEncoding

enum Botan::PKCS11::PublicPointEncoding : uint32_t
strong
Enumerator
Raw 
Der 

Definition at line 819 of file p11.h.

◆ ReturnValue

Enumerator
OK 
Cancel 
HostMemory 
SlotIdInvalid 
GeneralError 
FunctionFailed 
ArgumentsBad 
NoEvent 
NeedToCreateThreads 
CantLock 
AttributeReadOnly 
AttributeSensitive 
AttributeTypeInvalid 
AttributeValueInvalid 
ActionProhibited 
DataInvalid 
DataLenRange 
DeviceError 
DeviceMemory 
DeviceRemoved 
EncryptedDataInvalid 
EncryptedDataLenRange 
FunctionCanceled 
FunctionNotParallel 
FunctionNotSupported 
KeyHandleInvalid 
KeySizeRange 
KeyTypeInconsistent 
KeyNotNeeded 
KeyChanged 
KeyNeeded 
KeyIndigestible 
KeyFunctionNotPermitted 
KeyNotWrappable 
KeyUnextractable 
MechanismInvalid 
MechanismParamInvalid 
ObjectHandleInvalid 
OperationActive 
OperationNotInitialized 
PinIncorrect 
PinInvalid 
PinLenRange 
PinExpired 
PinLocked 
SessionClosed 
SessionCount 
SessionHandleInvalid 
SessionParallelNotSupported 
SessionReadOnly 
SessionExists 
SessionReadOnlyExists 
SessionReadWriteSoExists 
SignatureInvalid 
SignatureLenRange 
TemplateIncomplete 
TemplateInconsistent 
TokenNotPresent 
TokenNotRecognized 
TokenWriteProtected 
UnwrappingKeyHandleInvalid 
UnwrappingKeySizeRange 
UnwrappingKeyTypeInconsistent 
UserAlreadyLoggedIn 
UserNotLoggedIn 
UserPinNotInitialized 
UserTypeInvalid 
UserAnotherAlreadyLoggedIn 
UserTooManyTypes 
WrappedKeyInvalid 
WrappedKeyLenRange 
WrappingKeyHandleInvalid 
WrappingKeySizeRange 
WrappingKeyTypeInconsistent 
RandomSeedNotSupported 
RandomNoRng 
DomainParamsInvalid 
CurveNotSupported 
BufferTooSmall 
SavedStateInvalid 
InformationSensitive 
StateUnsaveable 
CryptokiNotInitialized 
CryptokiAlreadyInitialized 
MutexBad 
MutexNotLocked 
NewPinMode 
NextOtp 
ExceededMaxIterations 
FipsSelfTestFailed 
LibraryLoadFailed 
PinTooWeak 
PublicKeyInvalid 
FunctionRejected 
VendorDefined 

Definition at line 713 of file p11.h.

713  : CK_RV
714  {
715  OK = CKR_OK,
716  Cancel = CKR_CANCEL,
810  };
#define CKR_RANDOM_SEED_NOT_SUPPORTED
Definition: pkcs11t.h:1129
#define CKR_DEVICE_REMOVED
Definition: pkcs11t.h:1062
#define CKR_FIPS_SELF_TEST_FAILED
Definition: pkcs11t.h:1151
#define CKR_ENCRYPTED_DATA_INVALID
Definition: pkcs11t.h:1063
#define CKR_PIN_EXPIRED
Definition: pkcs11t.h:1093
#define CKR_KEY_NEEDED
Definition: pkcs11t.h:1077
#define CKR_SAVED_STATE_INVALID
Definition: pkcs11t.h:1138
#define CKR_CANCEL
Definition: pkcs11t.h:1039
#define CKR_UNWRAPPING_KEY_TYPE_INCONSISTENT
Definition: pkcs11t.h:1115
#define CKR_DEVICE_ERROR
Definition: pkcs11t.h:1060
#define CKR_SIGNATURE_INVALID
Definition: pkcs11t.h:1106
#define CKR_FUNCTION_CANCELED
Definition: pkcs11t.h:1065
#define CKR_ATTRIBUTE_SENSITIVE
Definition: pkcs11t.h:1052
#define CKR_NO_EVENT
Definition: pkcs11t.h:1047
#define CKR_GENERAL_ERROR
Definition: pkcs11t.h:1043
#define CKR_OK
Definition: pkcs11t.h:1038
#define CKR_WRAPPING_KEY_SIZE_RANGE
Definition: pkcs11t.h:1127
#define CKR_OBJECT_HANDLE_INVALID
Definition: pkcs11t.h:1086
#define CKR_MUTEX_BAD
Definition: pkcs11t.h:1144
#define CKR_RANDOM_NO_RNG
Definition: pkcs11t.h:1131
#define CKR_WRAPPING_KEY_TYPE_INCONSISTENT
Definition: pkcs11t.h:1128
#define CKR_ATTRIBUTE_READ_ONLY
Definition: pkcs11t.h:1051
#define CKR_SESSION_EXISTS
Definition: pkcs11t.h:1101
#define CKR_MUTEX_NOT_LOCKED
Definition: pkcs11t.h:1145
#define CKR_NEXT_OTP
Definition: pkcs11t.h:1148
#define CKR_TOKEN_WRITE_PROTECTED
Definition: pkcs11t.h:1112
#define CKR_DEVICE_MEMORY
Definition: pkcs11t.h:1061
#define CKR_INFORMATION_SENSITIVE
Definition: pkcs11t.h:1139
#define CKR_EXCEEDED_MAX_ITERATIONS
Definition: pkcs11t.h:1150
#define CKR_PIN_INVALID
Definition: pkcs11t.h:1090
#define CKR_LIBRARY_LOAD_FAILED
Definition: pkcs11t.h:1152
#define CKR_PIN_TOO_WEAK
Definition: pkcs11t.h:1153
#define CKR_DATA_INVALID
Definition: pkcs11t.h:1058
#define CKR_ATTRIBUTE_TYPE_INVALID
Definition: pkcs11t.h:1053
#define CKR_PIN_INCORRECT
Definition: pkcs11t.h:1089
#define CKR_PUBLIC_KEY_INVALID
Definition: pkcs11t.h:1154
#define CKR_STATE_UNSAVEABLE
Definition: pkcs11t.h:1140
#define CKR_KEY_INDIGESTIBLE
Definition: pkcs11t.h:1078
#define CKR_ACTION_PROHIBITED
Definition: pkcs11t.h:1056
#define CKR_USER_TOO_MANY_TYPES
Definition: pkcs11t.h:1122
#define CKR_OPERATION_ACTIVE
Definition: pkcs11t.h:1087
#define CKR_KEY_NOT_WRAPPABLE
Definition: pkcs11t.h:1080
#define CKR_FUNCTION_NOT_SUPPORTED
Definition: pkcs11t.h:1068
#define CKR_PIN_LOCKED
Definition: pkcs11t.h:1094
#define CKR_FUNCTION_FAILED
Definition: pkcs11t.h:1044
#define CKR_TEMPLATE_INCONSISTENT
Definition: pkcs11t.h:1109
#define CKR_ARGUMENTS_BAD
Definition: pkcs11t.h:1046
#define CKR_BUFFER_TOO_SMALL
Definition: pkcs11t.h:1137
#define CKR_USER_NOT_LOGGED_IN
Definition: pkcs11t.h:1117
#define CKR_USER_ANOTHER_ALREADY_LOGGED_IN
Definition: pkcs11t.h:1121
#define CKR_FUNCTION_NOT_PARALLEL
Definition: pkcs11t.h:1066
CK_ULONG CK_RV
Definition: pkcs11t.h:1036
#define CKR_KEY_TYPE_INCONSISTENT
Definition: pkcs11t.h:1073
#define CKR_SLOT_ID_INVALID
Definition: pkcs11t.h:1041
#define CKR_CANT_LOCK
Definition: pkcs11t.h:1049
#define CKR_KEY_NOT_NEEDED
Definition: pkcs11t.h:1075
#define CKR_ATTRIBUTE_VALUE_INVALID
Definition: pkcs11t.h:1054
#define CKR_SIGNATURE_LEN_RANGE
Definition: pkcs11t.h:1107
#define CKR_KEY_SIZE_RANGE
Definition: pkcs11t.h:1072
#define CKR_CRYPTOKI_ALREADY_INITIALIZED
Definition: pkcs11t.h:1143
#define CKR_NEED_TO_CREATE_THREADS
Definition: pkcs11t.h:1048
#define CKR_CRYPTOKI_NOT_INITIALIZED
Definition: pkcs11t.h:1142
#define CKR_WRAPPING_KEY_HANDLE_INVALID
Definition: pkcs11t.h:1126
#define CKR_TOKEN_NOT_PRESENT
Definition: pkcs11t.h:1110
#define CKR_UNWRAPPING_KEY_HANDLE_INVALID
Definition: pkcs11t.h:1113
#define CKR_FUNCTION_REJECTED
Definition: pkcs11t.h:1156
#define CKR_TOKEN_NOT_RECOGNIZED
Definition: pkcs11t.h:1111
#define CKR_SESSION_PARALLEL_NOT_SUPPORTED
Definition: pkcs11t.h:1099
#define CKR_USER_TYPE_INVALID
Definition: pkcs11t.h:1119
#define CKR_UNWRAPPING_KEY_SIZE_RANGE
Definition: pkcs11t.h:1114
#define CKR_SESSION_HANDLE_INVALID
Definition: pkcs11t.h:1098
#define CKR_USER_ALREADY_LOGGED_IN
Definition: pkcs11t.h:1116
#define CKR_PIN_LEN_RANGE
Definition: pkcs11t.h:1091
#define CKR_KEY_UNEXTRACTABLE
Definition: pkcs11t.h:1081
#define CKR_SESSION_READ_ONLY_EXISTS
Definition: pkcs11t.h:1103
#define CKR_WRAPPED_KEY_LEN_RANGE
Definition: pkcs11t.h:1125
#define CKR_MECHANISM_INVALID
Definition: pkcs11t.h:1083
#define CKR_KEY_FUNCTION_NOT_PERMITTED
Definition: pkcs11t.h:1079
#define CKR_VENDOR_DEFINED
Definition: pkcs11t.h:1158
#define CKR_SESSION_READ_ONLY
Definition: pkcs11t.h:1100
#define CKR_MECHANISM_PARAM_INVALID
Definition: pkcs11t.h:1084
#define CKR_KEY_HANDLE_INVALID
Definition: pkcs11t.h:1070
#define CKR_NEW_PIN_MODE
Definition: pkcs11t.h:1147
#define CKR_KEY_CHANGED
Definition: pkcs11t.h:1076
#define CKR_DOMAIN_PARAMS_INVALID
Definition: pkcs11t.h:1133
#define CKR_USER_PIN_NOT_INITIALIZED
Definition: pkcs11t.h:1118
#define CKR_SESSION_CLOSED
Definition: pkcs11t.h:1096
#define CKR_ENCRYPTED_DATA_LEN_RANGE
Definition: pkcs11t.h:1064
#define CKR_WRAPPED_KEY_INVALID
Definition: pkcs11t.h:1124
#define CKR_SESSION_COUNT
Definition: pkcs11t.h:1097
#define CKR_CURVE_NOT_SUPPORTED
Definition: pkcs11t.h:1135
#define CKR_TEMPLATE_INCOMPLETE
Definition: pkcs11t.h:1108
#define CKR_SESSION_READ_WRITE_SO_EXISTS
Definition: pkcs11t.h:1104
#define CKR_DATA_LEN_RANGE
Definition: pkcs11t.h:1059
#define CKR_OPERATION_NOT_INITIALIZED
Definition: pkcs11t.h:1088
#define CKR_HOST_MEMORY
Definition: pkcs11t.h:1040

◆ SessionState

Enumerator
RoPublicSession 
RoUserFunctions 
RwPublicSession 
RwUserFunctions 
RwSoFunctions 

Definition at line 704 of file p11.h.

◆ UserType

Enumerator
SO 
User 
ContextSpecific 

Definition at line 812 of file p11.h.

812  : CK_USER_TYPE
813  {
814  SO = CKU_SO,
815  User = CKU_USER,
817  };
#define CKU_CONTEXT_SPECIFIC
Definition: pkcs11t.h:268
#define CKU_SO
Definition: pkcs11t.h:264
CK_ULONG CK_USER_TYPE
Definition: pkcs11t.h:262
#define CKU_USER
Definition: pkcs11t.h:266

Function Documentation

◆ change_pin()

void Botan::PKCS11::change_pin ( Slot slot,
const secure_string old_pin,
const secure_string new_pin 
)

Change PIN with old PIN to new PIN

Parameters
slotThe slot with the attached token
old_pinThe old user PIN
new_pinThe new user PIN

Definition at line 52 of file p11.cpp.

References Botan::PKCS11::Session::login(), Botan::PKCS11::Session::set_pin(), and User.

53  {
54  Session session(slot, false);
55  session.login(UserType::User, old_pin);
56  session.set_pin(old_pin, new_pin);
57  }

◆ change_so_pin()

void Botan::PKCS11::change_so_pin ( Slot slot,
const secure_string old_so_pin,
const secure_string new_so_pin 
)

Change SO_PIN with old SO_PIN to new SO_PIN

Parameters
slotThe slot with the attached token
old_so_pinThe old SO_PIN
new_so_pinThe new SO_PIN

Definition at line 59 of file p11.cpp.

References Botan::PKCS11::Session::login(), Botan::PKCS11::Session::set_pin(), and SO.

60  {
61  Session session(slot, false);
62  session.login(UserType::SO, old_so_pin);
63  session.set_pin(old_so_pin, new_so_pin);
64  }

◆ flags()

Flags Botan::PKCS11::flags ( Flag  flags)
inline

◆ initialize_token()

void Botan::PKCS11::initialize_token ( Slot slot,
const std::string &  label,
const secure_string so_pin,
const secure_string pin 
)

Initializes a token

Parameters
slotThe slot with the attached token that should be initialized
labelThe token label
so_pinPIN of the security officer. Will be set if the token is uninitialized other this has to be the current SO_PIN
pinThe user PIN that will be set

Definition at line 46 of file p11.cpp.

References Botan::PKCS11::Slot::initialize(), and set_pin().

47  {
48  slot.initialize(label, so_pin);
49  set_pin(slot, so_pin, pin);
50  }
void set_pin(Slot &slot, const secure_string &so_pin, const secure_string &pin)
Definition: p11.cpp:66

◆ operator|()

Flag Botan::PKCS11::operator| ( Flag  a,
Flag  b 
)
inline

Definition at line 265 of file p11.h.

266  {
267  return static_cast< Flag >(static_cast< CK_FLAGS >(a) | static_cast< CK_FLAGS >(b));
268  }
CK_ULONG CK_FLAGS
Definition: pkcs11t.h:54

◆ set_pin()

void Botan::PKCS11::set_pin ( Slot slot,
const secure_string so_pin,
const secure_string pin 
)

Sets user PIN with SO_PIN

Parameters
slotThe slot with the attached token
so_pinPIN of the security officer
pinThe user PIN that should be set

Definition at line 66 of file p11.cpp.

References Botan::PKCS11::Session::init_pin(), Botan::PKCS11::Session::login(), and SO.

Referenced by initialize_token().

67  {
68  Session session(slot, false);
69  session.login(UserType::SO, so_pin);
70  session.init_pin(pin);
71  }

Variable Documentation

◆ False

const Bbool Botan::PKCS11::False = 0

Definition at line 856 of file p11.h.

Referenced by Botan::PKCS11::AttributeContainer::add_bool().

◆ ThrowException

ReturnValue * Botan::PKCS11::ThrowException = reinterpret_cast< ReturnValue* >(-1)

Definition at line 19 of file p11.cpp.

◆ True

const Bbool Botan::PKCS11::True = 1

Definition at line 855 of file p11.h.

Referenced by Botan::PKCS11::AttributeContainer::add_bool().