Created a changelog, to be used in accordance with http://keepachangelog.com
[legacy-proxmark3.git] / include / hitag2.h
blobca15d81d2b6e959040c2920ef53382c92a8d6275
1 //-----------------------------------------------------------------------------
2 // (c) 2012 Roel Verdult
3 //
4 // This code is licensed to you under the terms of the GNU GPL, version 2 or,
5 // at your option, any later version. See the LICENSE.txt file for the text of
6 // the license.
7 //-----------------------------------------------------------------------------
8 // Hitag2 type prototyping
9 //-----------------------------------------------------------------------------
11 #ifndef _HITAG2_H_
12 #define _HITAG2_H_
14 typedef enum {
15 RHT2F_PASSWORD = 21,
16 RHT2F_AUTHENTICATE = 22,
17 RHT2F_CRYPTO = 23,
18 RHT2F_TEST_AUTH_ATTEMPTS = 25,
19 } hitag_function;
21 typedef struct {
22 byte_t password[4];
23 } PACKED rht2d_password;
25 typedef struct {
26 byte_t NrAr[8];
27 } PACKED rht2d_authenticate;
29 typedef struct {
30 byte_t key[4];
31 } PACKED rht2d_crypto;
33 typedef union {
34 rht2d_password pwd;
35 rht2d_authenticate auth;
36 rht2d_crypto crypto;
37 } hitag_data;
39 #endif