]> cvs.zerfleddert.de Git - proxmark3-svn/blob - include/hitag2.h
Fixed all "misleading-indentation" warnings (fixes #187).
[proxmark3-svn] / include / hitag2.h
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 //-----------------------------------------------------------------------------
10 // HitagS added
11 //-----------------------------------------------------------------------------
12
13 #ifndef _HITAG2_H_
14 #define _HITAG2_H_
15
16 typedef enum {
17 RHTSF_CHALLENGE = 01,
18 RHTSF_KEY = 02,
19 WHTSF_CHALLENGE = 03,
20 WHTSF_KEY = 04,
21 RHT2F_PASSWORD = 21,
22 RHT2F_AUTHENTICATE = 22,
23 RHT2F_CRYPTO = 23,
24 RHT2F_TEST_AUTH_ATTEMPTS = 25,
25 } hitag_function;
26
27 typedef struct {
28 byte_t password[4];
29 } PACKED rht2d_password;
30
31 typedef struct {
32 byte_t NrAr[8];
33 byte_t data[4];
34 } PACKED rht2d_authenticate;
35
36 typedef struct {
37 byte_t key[6];
38 byte_t data[4];
39 } PACKED rht2d_crypto;
40
41 typedef union {
42 rht2d_password pwd;
43 rht2d_authenticate auth;
44 rht2d_crypto crypto;
45 } hitag_data;
46
47 #endif
Impressum, Datenschutz