LibLogicalAccess  2.5.0
An Open Source RFID Library
Loading...
Searching...
No Matches
nxpkeydiversification.hpp
Go to the documentation of this file.
1#ifndef NXPKEYDIVERSIFICATION_HPP__
2#define NXPKEYDIVERSIFICATION_HPP__
3
6#include <vector>
7#include <string>
8#include <logicalaccess/plugins/cards/desfire/lla_cards_desfire_api.hpp>
9
10namespace logicalaccess
11{
12class LLA_CARDS_DESFIRE_API NXPKeyDiversification : public KeyDiversification
13{
14 public:
15 void initDiversification(ByteVector identifier, unsigned int AID,
16 std::shared_ptr<Key> key, unsigned char keyno,
17 ByteVector &diversify) override = 0;
18 ByteVector getDiversifiedKey(std::shared_ptr<Key> key,
19 ByteVector diversify) override = 0;
20
22 {
23 }
24 virtual ~NXPKeyDiversification() = default;
25
26 std::string getKeyDiversificationType() override
27 {
28 return "NXP";
29 }
30
31 void serialize(boost::property_tree::ptree & /*parentNode*/) override
32 {
33 }
34 void unSerialize(boost::property_tree::ptree & /*node*/) override
35 {
36 }
37 std::string getDefaultXmlNodeName() const override
38 {
39 return "NXPKeyDiversification";
40 }
41};
42}
43
44#endif
Definition: keydiversification.hpp:13
Definition: nxpkeydiversification.hpp:13
std::string getDefaultXmlNodeName() const override
Get the default Xml Node name for this object.
Definition: nxpkeydiversification.hpp:37
NXPKeyDiversification()
Definition: nxpkeydiversification.hpp:21
virtual ~NXPKeyDiversification()=default
void initDiversification(ByteVector identifier, unsigned int AID, std::shared_ptr< Key > key, unsigned char keyno, ByteVector &diversify) override=0
ByteVector getDiversifiedKey(std::shared_ptr< Key > key, ByteVector diversify) override=0
void serialize(boost::property_tree::ptree &) override
Serialize object to Xml Node.
Definition: nxpkeydiversification.hpp:31
void unSerialize(boost::property_tree::ptree &) override
UnSerialize object from a Xml Node.
Definition: nxpkeydiversification.hpp:34
std::string getKeyDiversificationType() override
Definition: nxpkeydiversification.hpp:26
std::vector< uint8_t > ByteVector
Definition: lla_fwd.hpp:80
Definition: asn1.hpp:9