Cryptography functionsΒΆ

The public functions listed here perform cryptographic operations based on the PKCS #11 interface.

If documentation is available for a function listed below, the function name is linked to either its MDC wiki page or its entry in the OLD SSL Reference. The Mozilla Cross Reference (MXR) link for each function provides access to the function definition, prototype definition, and source code references. The NSS version column indicates which versions of NSS support the function.

Function name/documentation

Source code

NSS versions

PK11_AlgtagToMechanism

MXR

3.2 and later

PK11_Authenticate

MXR

3.2 and later

PK11_BlockData

MXR

3.2 and later

PK11_ChangePW

MXR

3.2 and later

PK11_CheckUserPassword

MXR

3.2 and later

PK11_CipherOp

MXR

3.2 and later

PK11_CloneContext

MXR

3.2 and later

PK11_ConfigurePKCS11

MXR

3.2 and later

PK1 1_ConvertSessionPrivKeyToTokenPrivKey

MXR

3.6 and later

P K11_ConvertSessionSymKeyToTokenSymKey

MXR

3.6 and later

`` PK11_CopyTokenPrivKeyToSessionPrivKey``

MXR

3.11 and later

PK11_CreateContextBySymKey

MXR

3.2 and later

PK11_CreateDigestContext

MXR

3.2 and later

PK11_CreateGenericObject

MXR

3.12 and later

PK11_CreateMergeLog

MXR

3.12 and later

PK11_CreatePBEAlgorithmID

MXR

3.2 and later

PK11_CreatePBEV2AlgorithmID

MXR

3.12 and later

PK11_DeleteTokenPrivateKey

MXR

3.4 and later

PK11_DeleteTokenPublicKey

MXR

3.4 and later

PK11_DeleteTokenSymKey

MXR

3.4 and later

PK11_Derive

MXR

3.2 and later

PK11_DeriveWithFlags

MXR

3.2 and later

PK11_DeriveWithFlagsPerm

MXR

3.9 and later

PK11_DestroyContext

MXR

3.2 and later

PK11_DestroyGenericObject

MXR

3.9.2 and later

PK11_DestroyGenericObjects

MXR

3.9.2 and later

PK11_DestroyMergeLog

MXR

3.12 and later

PK11_DestroyObject

MXR

3.2 and later

PK11_DestroyTokenObject

MXR

3.2 and later

PK11_DigestBegin

MXR

3.2 and later

PK11_DigestKey

MXR

3.2 and later

PK11_DigestOp

MXR

3.2 and later

PK11_DigestFinal

MXR

3.2 and later

PK11_DoesMechanism

MXR

3.2 and later

PK11_ExportEncryptedPrivateKeyInfo

MXR

3.2 and later

PK11_ExportEncryptedPrivKeyInfo

MXR

3.9 and later

PK11_ExportPrivateKeyInfo

MXR

3.2 and later

PK11_Finalize

MXR

3.2 and later

PK11_FindBestKEAMatch

MXR

3.2 and later

PK11_FindCertAndKeyByRecipientList

MXR

3.2 and later

`` PK11_FindCertAndKeyByRecipientListNew``

MXR

3.2 and later

PK11_FindCertByIssuerAndSN

MXR

3.2 and later

PK11_FindCertFromDERCert

MXR

3.2 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1035673

MXR

3.2 and later

PK11_FindCertInSlot

MXR

3.2 and later

PK11_FindGenericObjects

MXR

3.9.2 and later

PK11_FindFixedKey

MXR

3.2 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1026891

MXR

3.2 and later

PK11_FindKeyByDERCert

MXR

3.2 and later

PK11_FindPrivateKeyFromCert

MXR

3.2 and later

PK11_FindSlotByName

MXR

3.2 and later

PK11_FindSlotsByNames

MXR

3.9 and later

PK11_FortezzaHasKEA

MXR

3.2 and later

PK11_FortezzaMapSig

MXR

3.2 and later

PK11_FreeSlot

MXR

3.2 and later

PK11_FreeSlotList

MXR

3.2 and later

PK11_FreeSlotListElement

MXR

3.11 and later

PK11_FreeSymKey

MXR

3.2 and later

PK11_GenerateFortezzaIV

MXR

3.2 and later

PK11_GenerateKeyPair

MXR

3.2 and later

PK11_GenerateKeyPairWithFlags

MXR

3.10.2 and later

PK11_GenerateKeyPairWithOpFlags

MXR

3.12 and later

PK11_GenerateNewParam

MXR

3.2 and later

PK11_GenerateRandom

MXR

3.2 and later

PK11_GenerateRandomOnSlot

MXR

3.11 and later

PK11_GetAllTokens

MXR

3.2 and later

PK11_GetAllSlotsForCert

MXR

3.12 and later

PK11_GetBestKeyLength

MXR

3.2 and later

PK11_GetBestSlot

MXR

3.2 and later

PK11_GetBestSlotMultiple

MXR

3.2 and later

PK11_GetBestWrapMechanism

MXR

3.2 and later

PK11_GetBlockSize

MXR

3.2 and later

PK11_GetCertFromPrivateKey

MXR

3.9.3 and later

PK11_GetCurrentWrapIndex

MXR

3.2 and later

PK11_GetDefaultArray

MXR

3.8 and later

PK11_GetDefaultFlags

MXR

3.8 and later

PK11_GetDisabledReason

MXR

3.8 and later

PK11_GetFirstSafe

MXR

3.2 and later

PK11_GetInternalKeySlot

MXR

3.2 and later

PK11_GetInternalSlot

MXR

3.2 and later

PK11_GetKeyGen

MXR

3.4 and later

PK11_GetKeyLength

MXR

3.2 and later

PK11_GetKeyStrength

MXR

3.2 and later

PK11_GetMechanism

MXR

3.2 and later

PK11_GetMinimumPwdLength

MXR

3.4 and later

PK11_GetModInfo

MXR

3.6 and later

PK11_GetModule

MXR

3.3 and later

PK11_GetModuleID

MXR

3.2 and later

PK11_GetNextGenericObject

MXR

3.9.2 and later

PK11_GetNextSafe

MXR

3.4 and later

PK11_GetNextSymKey

MXR

3.4 and later

PK11_GetPadMechanism

MXR

3.4 and later

PK11_GetPBECryptoMechanism

MXR

3.12 and later

PK11_GetPBEIV

MXR

3.6 and later

PK11_GetPQGParamsFromPrivateKey

MXR

3.4 and later

PK11_GetPrevGenericObject

MXR

3.9.2 and later

PK11_GetPrivateKeyNickname

MXR

3.4 and later

PK11_GetPrivateModulusLen

MXR

3.2 and later

PK11_GetPublicKeyNickname

MXR

3.4 and later

PK11_GetSlotFromKey

MXR

3.2 and later

PK11_GetSlotFromPrivateKey

MXR

3.2 and later

PK11_GetSlotID

MXR

3.2 and later

PK11_GetSlotInfo

MXR

3.4 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1030779

MXR

3.2 and later

PK11_GetSlotSeries

MXR

3.2 and later

PK11_GetSymKeyNickname

MXR

3.4 and later

PK11_GetSymKeyType

MXR

3.9 and later

PK11_GetSymKeyUserData

MXR

3.11 and later

PK11_GetTokenInfo

MXR

3.2 and later

mozilla_pro jects_nss_ssl_functions_sslcrt#1026964

MXR

3.2 and later

PK11_GetWindow

MXR

3.2 and later

PK11_GetWrapKey

MXR

3.2 and later

PK11_HashBuf

MXR

3.2 and later

PK11_HasRootCerts

MXR

3.4 and later

PK11_ImportCert

MXR

3.5 and later

PK11_ImportCertForKeyToSlot

MXR

3.2 and later

PK11_ImportCRL

MXR

3.6 and later

PK11_ImportDERCert

MXR

3.6 and later

PK1 1_ImportDERPrivateKeyInfoAndReturnKey

MXR

3.4 and later

PK11_ImportEncryptedPrivateKeyInfo

MXR

3.2 and later

PK11_ImportPrivateKeyInfo

MXR

3.2 and later

`` PK11_ImportPrivateKeyInfoAndReturnKey``

MXR

3.4 and later

PK11_ImportPublicKey

MXR

3.4 and later

PK11_ImportSymKeyWithFlags

MXR

3.4 and later

PK11_InitPin

MXR

3.2 and later

PK11_IsFIPS

MXR

3.2 and later

PK11_IsDisabled

MXR

3.4 and later

PK11_IsFriendly

MXR

3.2 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1026762

MXR

3.2 and later

PK11_IsInternal

MXR

3.2 and later

mozilla_pro jects_nss_ssl_functions_sslcrt#1026762

MXR

3.2 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1022991

MXR

3.2 and later

PK11_IsRemovable

MXR

3.12 and later

PK11_IVFromParam

MXR

3.2 and later

PK11_KeyGen

MXR

3.2 and later

PK11_LinkGenericObject

MXR

3.9.2 and later

PK11_ListCerts

MXR

3.2 and later. Updated 3.8 with new options. See bug 215186

PK11_ListFixedKeysInSlot

MXR

3.4 and later

PK11_ListPrivKeysInSlot

MXR

3.4 and later

PK11_ListPublicKeysInSlot

MXR

3.4 and later

PK11_LoadPrivKey

MXR

3.4 and later

PK11_LogoutAll

MXR

3.4 and later

PK11_MakeKEAPubKey

MXR

3.2 and later

`` PK11_MapPBEMechanismToCryptoMechanism``

MXR

3.2 and later

PK11_MapSignKeyType

MXR

3.11 and later

PK11_MechanismToAlgtag

MXR

3.4 and later

PK11_MergeTokens

MXR

3.12 and later

PK11_MoveSymKey

MXR

3.9 and later

PK11_NeedLogin

MXR

3.2 and later

PK11_NeedUserInit

MXR

3.2 and later

PK11_ParamFromIV

MXR

3.2 and later

PK11_ParamFromAlgid

MXR

3.2 and later

PK11_ParamToAlgid

MXR

3.2 and later

PK11_PBEKeyGen

MXR

3.2 and later

PK11_PrivDecryptPKCS1

MXR

3.9.3 and later

PK11_ProtectedAuthenticationPath

MXR

3.4 and later

PK11_PubDecryptRaw

MXR

3.2 and later

PK11_PubDerive

MXR

3.2 and later

PK11_PubDeriveWithKDF

MXR

3.9 and later

PK11_PubEncryptPKCS1

MXR

3.9.3 and later

PK11_PubEncryptRaw

MXR

3.2 and later

PK11_PubUnwrapSymKey

MXR

3.2 and later

PK11_PubUnwrapSymKeyWithFlags

MXR

3.6 and later

PK11_PubUnwrapSymKeyWithFlagsPerm

MXR

3.9 and later

PK11_PubWrapSymKey

MXR

3.2 and later

PK11_RandomUpdate

MXR

3.2 and later

PK11_ReadRawAttribute

MXR

3.9.2 and later

PK11_ReferenceSymKey

MXR

3.2 and later

PK11_ResetToken

MXR

3.4 and later

PK11_RestoreContext

MXR

3.2 and later

PK11_SaveContext

MXR

3.2 and later

PK11_SaveContextAlloc

MXR

3.6 and later

PK11_SetFortezzaHack

MXR

3.2 and later

mozilla_pr ojects_nss_ssl_functions_pkfnc#1023128

MXR

3.2 and later

PK11_SetPrivateKeyNickname

MXR

3.4 and later

PK11_SetPublicKeyNickname

MXR

3.4 and later

PK11_SetSlotPWValues

MXR

3.2 and later

PK11_SetSymKeyNickname

MXR

3.4 and later

PK11_SetSymKeyUserData

MXR

3.11 and later

PK11_SetWrapKey

MXR

3.2 and later

PK11_Sign

MXR

3.2 and later

PK11_SignatureLen

MXR

3.2 and later

PK11_SymKeyFromHandle

MXR

3.2 and later

PK11_TokenExists

MXR

3.2 and later

PK11_TokenKeyGen

MXR

3.6 and later

PK11_TokenKeyGenWithFlags

MXR

3.10.2 and later

PK11_TokenRefresh

MXR

3.7.1 and later

PK11_TraverseCertsForNicknameInSlot

MXR

3.2 and later

PK11_TraverseCertsForSubjectInSlot

MXR

3.2 and later

PK11_TraverseSlotCerts

MXR

3.4 and later

PK11_UnlinkGenericObject

MXR

3.9.2 and later

PK11_UnwrapSymKey

MXR

3.2 and later

PK11_UnwrapSymKeyWithFlags

MXR

3.2 and later

PK11_UnwrapSymKeyWithFlagsPerm

MXR

3.9 and later

PK11_UpdateSlotAttribute

MXR

3.8 and later

PK11_UserEnableSlot

MXR

3.8 and later

PK11_UserDisableSlot

MXR

3.8 and later

PK11_Verify

MXR

3.2 and later

PK11_VerifyKeyOK

MXR

3.2 and later

PK11_WaitForTokenEvent

MXR

3.7 and later

PK11_WrapSymKey

MXR

3.2 and later

PK11_WriteRawAttribute

MXR

3.12 and later

PK11SDR_Encrypt

MXR

3.2 and later

PK11SDR_Decrypt

MXR

3.2 and later

SEC_DeletePermCertificate

MXR

3.2 and later

SEC_DeletePermCRL

MXR

3.2 and later

SEC_DerSignData

MXR

3.2 and later

SEC_DestroyCrl

MXR

3.2 and later

SEC_FindCrlByDERCert

MXR

3.2 and later

SEC_FindCrlByName

MXR

3.2 and later

SEC_LookupCrls

MXR

3.2 and later

SEC_NewCrl

MXR

3.2 and later

SEC_QuickDERDecodeItem

MXR

3.6 and later

SECKEY_CacheStaticFlags

MXR

3.10 and later

SECKEY_ConvertToPublicKey

MXR

3.2 and later

SECKEY_CopyPrivateKey

MXR

3.2 and later

SECKEY_CopyPublicKey

MXR

3.6 and later

SECKEY_CopySubjectPublicKeyInfo

MXR

3.4 and later

SECKEY_CreateDHPrivateKey

MXR

3.3 and later

SECKEY_CreateECPrivateKey

MXR

3.8 and later

SECKEY_CreateSubjectPublicKeyInfo

MXR

3.2 and later

` SECKEY_DecodeDERSubjectPublicKeyInfo`

MXR

3.4 and later

mozilla_pro jects_nss_ssl_functions_sslkey#1051017

MXR

3.2 and later

SECKEY_ECParamsToBasePointOrderLen

MXR

3.12 and later

SECKEY_ECParamsToKeySize

MXR

3.12 and later

SECKEY_DestroyPublicKeyList

MXR

3.4 and later

SECKEY_DestroySubjectPublicKeyInfo

MXR

3.2 and later

SECKEY_GetPublicKeyType

MXR

3.3 and later

SECKEY_PublicKeyStrengthInBits

MXR

3.8 and later

SECKEY_SignatureLen

MXR

3.11.2 and later