![EnOcean EASYFIT EMDCB User Manual Download Page 65](http://html1.mh-extra.com/html/enocean/easyfit-emdcb/easyfit-emdcb_user-manual_2413682065.webp)
USER MANUAL
EMDCB
–
BLUETOOTH LOW ENERGY MOTION AND ILLUMINATION SENSOR
© 2019 EnOcean | www.enocean.com
EMDCB User Manual | v1.3 | August 2019 | Page 65/67
B.5
Execution example
At the time of writing, a suitable online AES calculator could be found here:
http://testprotect.com/appendix/AEScalc
Likewise, a suitable online XOR calculator could be found here:
We can now calculate the signature using a sequence of AES128 and XOR operations as
shown in Figure 37 as follows:
X_1 = AES128(B0, Key)
X_1 = AES128(49C400000000E557E201000000000000, 9E0DE9C25386B6C4F070642E19E03680)
X_1 = 97F967605F8B20A988A026AC76B0E4E0
X_1A = XOR(X_1, B_1)
X_1A = XOR(97F967605F8B20A988A026AC76B0E4E0, 001215FFDA0357E2010002AA44D60045)
X_1A = 97EB729F8588774B89A024063266E4A5
X_2 = AES128(X_1A, Key)
X_2 = AES128(97EB729F8588774B89A024063266E4A5, 9E0DE9C25386B6C4F070642E19E03680)
X_2 = 8CD6013AFFB05E19DA7891398FFA00B4
X_2A = XOR(X_2, B_2)
X_2A = XOR(8CD6013AFFB05E19DA7891398FFA00B4, 35002002000000000000000000000000)
X_2A = B9D62138FFB05E19DA7891398FFA00B4
X_3 = AES128(X_2A, Key)
X_3 = AES128(B9D62138FFB05E19DA7891398FFA00B4,9E0DE9C25386B6C4F070642E19E03680)
X_3 = 1FA1970E831CFA1C445EC14639CB4AFE
S_0 = AES128(A0, Key)
S_0 = AES128(01C400000000E557E201000000000000,9E0DE9C25386B6C4F070642E19E03680)
S_0 = D76DC01C1302BEC9C7DC61042CE71D2C
T_0 = XOR(X_3, S_0)
T_0 = XOR(1FA1970E831CFA1C445EC14639CB4AFE, D76DC01C1302BEC9C7DC61042CE71D2C)
T_0 = C8CC5712901E44D58382A042152C57D2
The calculated signature is formed by the first four bytes of
T_0
, i.e. it is
C8CC5712
.
The calculated signature matches the signature that was transmitted as part of the data
telegram payload (see chapter A.1).
This proves that the telegram originates from a sender that possesses the same security
key and the telegram content has not been modified.