LibLogicalAccess  2.5.0
An Open Source RFID Library
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
epasscommands.hpp
Go to the documentation of this file.
1#pragma once
2
6
7namespace logicalaccess
8{
9#define CMD_EPASS "EPass"
10
11class LLA_CARDS_EPASS_API EPassCommands : public Commands
12{
13 public:
15
16 explicit EPassCommands(std::string ct);
17
18 void setReaderCardAdapter(std::shared_ptr<ReaderCardAdapter> adapter) override;
19
20 bool selectApplication(const ByteVector &app_id);
21
22 bool selectIssuerApplication();
23 bool authenticate(const std::string &mrz);
24
31 EPassEFCOM readEFCOM() const;
32
41 ByteVector readEF(uint8_t size_bytes, uint8_t size_offset) const;
42
48 EPassDG1 readDG1() const;
49
56 EPassDG2 readDG2();
57
63 ByteVector readSOD() const;
64
65 virtual std::shared_ptr<ISO7816Commands> getISO7816Commands() const = 0;
66
67 private:
68 ByteVector compute_hash(const ByteVector &file_id) const;
69
78
79 std::shared_ptr<EPassCrypto> crypto_;
80};
81}
The base commands class for all card commands.
Definition: commands.hpp:21
Definition: epasscommands.hpp:12
virtual std::shared_ptr< ISO7816Commands > getISO7816Commands() const =0
ByteVector current_app_
Definition: epasscommands.hpp:77
std::shared_ptr< EPassCrypto > crypto_
Definition: epasscommands.hpp:79
ISO7816 commands. See http://www.cardwerk.com/smartcards/smartcard_standard_ISO7816-4....
std::vector< uint8_t > ByteVector
Definition: lla_fwd.hpp:80
Definition: asn1.hpp:9
Definition: utils.hpp:59
Definition: utils.hpp:25
Definition: utils.hpp:17