AlexaClientSDK  1.26.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Public Member Functions | Static Public Member Functions | List of all members
alexaClientSDK::acsdkPkcs11::PKCS11Functions Class Reference

PKCS11 API Wrapper. More...

#include <PKCS11Functions.h>

Inheritance diagram for alexaClientSDK::acsdkPkcs11::PKCS11Functions:
Inheritance graph
[legend]
Collaboration diagram for alexaClientSDK::acsdkPkcs11::PKCS11Functions:
Collaboration graph
[legend]

Public Member Functions

virtual ~PKCS11Functions () noexcept
 Releases library. More...
 
bool listSlots (bool tokenPresent, std::vector< std::shared_ptr< PKCS11Slot >> &slots) noexcept
 Lists available PKCS11 slots by type. More...
 
bool findSlotByTokenName (const std::string &tokenName, std::shared_ptr< PKCS11Slot > &slot) noexcept
 Finds PKCS11 slot by name. More...
 

Static Public Member Functions

static std::shared_ptr< PKCS11Functionscreate (const std::string &libpath) noexcept
 

Detailed Description

PKCS11 API Wrapper.

This class manages library load, initialization, and slot operations.

Constructor & Destructor Documentation

◆ ~PKCS11Functions()

alexaClientSDK::acsdkPkcs11::PKCS11Functions::~PKCS11Functions ( )
virtualnoexcept

Releases library.

Member Function Documentation

◆ create()

std::shared_ptr< PKCS11Functions > alexaClientSDK::acsdkPkcs11::PKCS11Functions::create ( const std::string &  libpath)
staticnoexcept

Creates object.

Parameters
libpathFile path to PKCS11 library.
Returns

◆ findSlotByTokenName()

bool alexaClientSDK::acsdkPkcs11::PKCS11Functions::findSlotByTokenName ( const std::string &  tokenName,
std::shared_ptr< PKCS11Slot > &  slot 
)
noexcept

Finds PKCS11 slot by name.

Parameters
[in]tokenNameToken name.
[out]slotDiscovered slot or nullptr if slot with given name doesn't exist.
Returns
True if operation is successful. If operation fails, the value of slot is unchanged.

◆ listSlots()

bool alexaClientSDK::acsdkPkcs11::PKCS11Functions::listSlots ( bool  tokenPresent,
std::vector< std::shared_ptr< PKCS11Slot >> &  slots 
)
noexcept

Lists available PKCS11 slots by type.

Parameters
[in]tokenPresentFlag, if list slots with tokens (when true), or all slots.
[out]slotsDiscovered slot names.
Returns
True if operation is successful.

The documentation for this class was generated from the following files:

AlexaClientSDK 1.26.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0