edhoc 1.0.4 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (314) hide show
  1. package/README.md +170 -0
  2. package/binding.gyp +13 -11
  3. package/dist/bindings.d.ts +5 -0
  4. package/dist/bindings.d.ts.map +1 -0
  5. package/dist/bindings.js +10 -0
  6. package/dist/crypto.d.ts +29 -0
  7. package/dist/crypto.d.ts.map +1 -0
  8. package/dist/crypto.js +205 -0
  9. package/dist/edhoc.d.ts +368 -0
  10. package/dist/edhoc.d.ts.map +1 -0
  11. package/dist/edhoc.js +76 -0
  12. package/dist/index.d.ts +4 -0
  13. package/dist/index.d.ts.map +1 -0
  14. package/dist/index.js +19 -0
  15. package/dist/x509credentials.d.ts +20 -0
  16. package/dist/x509credentials.d.ts.map +1 -0
  17. package/dist/x509credentials.js +140 -0
  18. package/external/libedhoc/backends/cbor/include/backend_cbor_bstr_type_decode.h +1 -1
  19. package/external/libedhoc/backends/cbor/include/backend_cbor_bstr_type_encode.h +1 -1
  20. package/external/libedhoc/backends/cbor/include/backend_cbor_bstr_type_types.h +1 -1
  21. package/external/libedhoc/backends/cbor/include/backend_cbor_ead_decode.h +2 -2
  22. package/external/libedhoc/backends/cbor/include/backend_cbor_ead_encode.h +2 -2
  23. package/external/libedhoc/backends/cbor/include/backend_cbor_edhoc_types.h +48 -43
  24. package/external/libedhoc/backends/cbor/include/backend_cbor_enc_structure_decode.h +1 -1
  25. package/external/libedhoc/backends/cbor/include/backend_cbor_enc_structure_encode.h +1 -1
  26. package/external/libedhoc/backends/cbor/include/backend_cbor_enc_structure_types.h +3 -3
  27. package/external/libedhoc/backends/cbor/include/backend_cbor_id_cred_x_decode.h +1 -1
  28. package/external/libedhoc/backends/cbor/include/backend_cbor_id_cred_x_encode.h +1 -1
  29. package/external/libedhoc/backends/cbor/include/backend_cbor_info_decode.h +1 -1
  30. package/external/libedhoc/backends/cbor/include/backend_cbor_info_encode.h +1 -1
  31. package/external/libedhoc/backends/cbor/include/backend_cbor_int_type_decode.h +1 -1
  32. package/external/libedhoc/backends/cbor/include/backend_cbor_int_type_encode.h +1 -1
  33. package/external/libedhoc/backends/cbor/include/backend_cbor_int_type_types.h +1 -1
  34. package/external/libedhoc/backends/cbor/include/backend_cbor_message_1_decode.h +1 -1
  35. package/external/libedhoc/backends/cbor/include/backend_cbor_message_1_encode.h +1 -1
  36. package/external/libedhoc/backends/cbor/include/backend_cbor_message_2_decode.h +1 -1
  37. package/external/libedhoc/backends/cbor/include/backend_cbor_message_2_encode.h +1 -1
  38. package/external/libedhoc/backends/cbor/include/backend_cbor_message_3_decode.h +1 -1
  39. package/external/libedhoc/backends/cbor/include/backend_cbor_message_3_encode.h +1 -1
  40. package/external/libedhoc/backends/cbor/include/backend_cbor_message_4_decode.h +1 -1
  41. package/external/libedhoc/backends/cbor/include/backend_cbor_message_4_encode.h +1 -1
  42. package/external/libedhoc/backends/cbor/include/backend_cbor_message_error_decode.h +1 -1
  43. package/external/libedhoc/backends/cbor/include/backend_cbor_message_error_encode.h +1 -1
  44. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_2_decode.h +1 -1
  45. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_2_encode.h +1 -1
  46. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_3_decode.h +1 -1
  47. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_3_encode.h +1 -1
  48. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_4_decode.h +3 -3
  49. package/external/libedhoc/backends/cbor/include/backend_cbor_plaintext_4_encode.h +3 -3
  50. package/external/libedhoc/backends/cbor/include/backend_cbor_sig_structure_decode.h +1 -1
  51. package/external/libedhoc/backends/cbor/include/backend_cbor_sig_structure_encode.h +1 -1
  52. package/external/libedhoc/backends/cbor/include/backend_cbor_sig_structure_types.h +4 -4
  53. package/external/libedhoc/backends/cbor/include/backend_cbor_x509_types.h +93 -83
  54. package/external/libedhoc/backends/cbor/src/backend_cbor_bstr_type_decode.c +11 -20
  55. package/external/libedhoc/backends/cbor/src/backend_cbor_bstr_type_encode.c +11 -20
  56. package/external/libedhoc/backends/cbor/src/backend_cbor_ead_decode.c +27 -32
  57. package/external/libedhoc/backends/cbor/src/backend_cbor_ead_encode.c +27 -32
  58. package/external/libedhoc/backends/cbor/src/backend_cbor_enc_structure_decode.c +14 -23
  59. package/external/libedhoc/backends/cbor/src/backend_cbor_enc_structure_encode.c +14 -23
  60. package/external/libedhoc/backends/cbor/src/backend_cbor_id_cred_x_decode.c +63 -52
  61. package/external/libedhoc/backends/cbor/src/backend_cbor_id_cred_x_encode.c +62 -51
  62. package/external/libedhoc/backends/cbor/src/backend_cbor_info_decode.c +14 -23
  63. package/external/libedhoc/backends/cbor/src/backend_cbor_info_encode.c +14 -23
  64. package/external/libedhoc/backends/cbor/src/backend_cbor_int_type_decode.c +11 -20
  65. package/external/libedhoc/backends/cbor/src/backend_cbor_int_type_encode.c +11 -20
  66. package/external/libedhoc/backends/cbor/src/backend_cbor_message_1_decode.c +54 -51
  67. package/external/libedhoc/backends/cbor/src/backend_cbor_message_1_encode.c +54 -51
  68. package/external/libedhoc/backends/cbor/src/backend_cbor_message_2_decode.c +11 -20
  69. package/external/libedhoc/backends/cbor/src/backend_cbor_message_2_encode.c +11 -20
  70. package/external/libedhoc/backends/cbor/src/backend_cbor_message_3_decode.c +11 -20
  71. package/external/libedhoc/backends/cbor/src/backend_cbor_message_3_encode.c +11 -20
  72. package/external/libedhoc/backends/cbor/src/backend_cbor_message_4_decode.c +11 -20
  73. package/external/libedhoc/backends/cbor/src/backend_cbor_message_4_encode.c +11 -20
  74. package/external/libedhoc/backends/cbor/src/backend_cbor_message_error_decode.c +36 -37
  75. package/external/libedhoc/backends/cbor/src/backend_cbor_message_error_encode.c +36 -37
  76. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_2_decode.c +103 -80
  77. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_2_encode.c +102 -79
  78. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_3_decode.c +99 -76
  79. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_3_encode.c +98 -75
  80. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_4_decode.c +40 -41
  81. package/external/libedhoc/backends/cbor/src/backend_cbor_plaintext_4_encode.c +40 -41
  82. package/external/libedhoc/backends/cbor/src/backend_cbor_sig_structure_decode.c +15 -24
  83. package/external/libedhoc/backends/cbor/src/backend_cbor_sig_structure_encode.c +15 -24
  84. package/external/libedhoc/externals/Unity/examples/example_1/src/ProductionCode.c +31 -0
  85. package/external/libedhoc/externals/Unity/examples/example_1/src/ProductionCode.h +10 -0
  86. package/external/libedhoc/externals/Unity/examples/example_1/src/ProductionCode2.c +18 -0
  87. package/external/libedhoc/externals/Unity/examples/example_1/src/ProductionCode2.h +9 -0
  88. package/external/libedhoc/externals/Unity/examples/example_1/test/TestProductionCode.c +69 -0
  89. package/external/libedhoc/externals/Unity/examples/example_1/test/TestProductionCode2.c +38 -0
  90. package/external/libedhoc/externals/Unity/examples/example_1/test/test_runners/TestProductionCode2_Runner.c +53 -0
  91. package/external/libedhoc/externals/Unity/examples/example_1/test/test_runners/TestProductionCode_Runner.c +57 -0
  92. package/external/libedhoc/externals/Unity/examples/example_2/src/ProductionCode.c +31 -0
  93. package/external/libedhoc/externals/Unity/examples/example_2/src/ProductionCode.h +10 -0
  94. package/external/libedhoc/externals/Unity/examples/example_2/src/ProductionCode2.c +18 -0
  95. package/external/libedhoc/externals/Unity/examples/example_2/src/ProductionCode2.h +9 -0
  96. package/external/libedhoc/externals/Unity/examples/example_2/test/TestProductionCode.c +71 -0
  97. package/external/libedhoc/externals/Unity/examples/example_2/test/TestProductionCode2.c +40 -0
  98. package/external/libedhoc/externals/Unity/examples/example_2/test/test_runners/TestProductionCode2_Runner.c +16 -0
  99. package/external/libedhoc/externals/Unity/examples/example_2/test/test_runners/TestProductionCode_Runner.c +18 -0
  100. package/external/libedhoc/externals/Unity/examples/example_2/test/test_runners/all_tests.c +19 -0
  101. package/external/libedhoc/externals/Unity/examples/example_3/helper/UnityHelper.c +17 -0
  102. package/external/libedhoc/externals/Unity/examples/example_3/helper/UnityHelper.h +19 -0
  103. package/external/libedhoc/externals/Unity/examples/example_3/src/ProductionCode.c +31 -0
  104. package/external/libedhoc/externals/Unity/examples/example_3/src/ProductionCode.h +10 -0
  105. package/external/libedhoc/externals/Unity/examples/example_3/src/ProductionCode2.c +18 -0
  106. package/external/libedhoc/externals/Unity/examples/example_3/src/ProductionCode2.h +9 -0
  107. package/external/libedhoc/externals/Unity/examples/example_3/test/TestProductionCode.c +69 -0
  108. package/external/libedhoc/externals/Unity/examples/example_3/test/TestProductionCode2.c +38 -0
  109. package/external/libedhoc/externals/Unity/examples/example_4/src/ProductionCode.c +31 -0
  110. package/external/libedhoc/externals/Unity/examples/example_4/src/ProductionCode.h +10 -0
  111. package/external/libedhoc/externals/Unity/examples/example_4/src/ProductionCode2.c +18 -0
  112. package/external/libedhoc/externals/Unity/examples/example_4/src/ProductionCode2.h +9 -0
  113. package/external/libedhoc/externals/Unity/examples/example_4/test/TestProductionCode.c +70 -0
  114. package/external/libedhoc/externals/Unity/examples/example_4/test/TestProductionCode2.c +42 -0
  115. package/external/libedhoc/externals/Unity/examples/example_4/test/test_runners/TestProductionCode2_Runner.c +53 -0
  116. package/external/libedhoc/externals/Unity/examples/example_4/test/test_runners/TestProductionCode_Runner.c +57 -0
  117. package/external/libedhoc/externals/Unity/examples/unity_config.h +251 -0
  118. package/external/libedhoc/externals/Unity/extras/bdd/src/unity_bdd.h +44 -0
  119. package/external/libedhoc/externals/Unity/extras/bdd/test/test_bdd.c +129 -0
  120. package/external/libedhoc/externals/Unity/extras/fixture/src/unity_fixture.c +310 -0
  121. package/external/libedhoc/externals/Unity/extras/fixture/src/unity_fixture.h +95 -0
  122. package/external/libedhoc/externals/Unity/extras/fixture/src/unity_fixture_internals.h +51 -0
  123. package/external/libedhoc/externals/Unity/extras/fixture/test/main/AllTests.c +20 -0
  124. package/external/libedhoc/externals/Unity/extras/fixture/test/template_fixture_tests.c +40 -0
  125. package/external/libedhoc/externals/Unity/extras/fixture/test/unity_fixture_Test.c +246 -0
  126. package/external/libedhoc/externals/Unity/extras/fixture/test/unity_fixture_TestRunner.c +33 -0
  127. package/external/libedhoc/externals/Unity/extras/memory/src/unity_memory.c +203 -0
  128. package/external/libedhoc/externals/Unity/extras/memory/src/unity_memory.h +61 -0
  129. package/external/libedhoc/externals/Unity/extras/memory/test/unity_memory_Test.c +326 -0
  130. package/external/libedhoc/externals/Unity/extras/memory/test/unity_memory_TestRunner.c +50 -0
  131. package/external/libedhoc/externals/Unity/extras/memory/test/unity_output_Spy.c +57 -0
  132. package/external/libedhoc/externals/Unity/extras/memory/test/unity_output_Spy.h +17 -0
  133. package/external/libedhoc/externals/Unity/src/unity.c +2501 -0
  134. package/external/libedhoc/externals/Unity/src/unity.h +698 -0
  135. package/external/libedhoc/externals/Unity/src/unity_internals.h +1183 -0
  136. package/external/libedhoc/externals/Unity/test/expectdata/testsample_cmd.c +61 -0
  137. package/external/libedhoc/externals/Unity/test/expectdata/testsample_def.c +57 -0
  138. package/external/libedhoc/externals/Unity/test/expectdata/testsample_head1.c +55 -0
  139. package/external/libedhoc/externals/Unity/test/expectdata/testsample_head1.h +15 -0
  140. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_cmd.c +80 -0
  141. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_def.c +76 -0
  142. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_head1.c +75 -0
  143. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_head1.h +13 -0
  144. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_new1.c +89 -0
  145. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_new2.c +89 -0
  146. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_param.c +77 -0
  147. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_run1.c +89 -0
  148. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_run2.c +89 -0
  149. package/external/libedhoc/externals/Unity/test/expectdata/testsample_mock_yaml.c +90 -0
  150. package/external/libedhoc/externals/Unity/test/expectdata/testsample_new1.c +67 -0
  151. package/external/libedhoc/externals/Unity/test/expectdata/testsample_new2.c +70 -0
  152. package/external/libedhoc/externals/Unity/test/expectdata/testsample_param.c +58 -0
  153. package/external/libedhoc/externals/Unity/test/expectdata/testsample_run1.c +67 -0
  154. package/external/libedhoc/externals/Unity/test/expectdata/testsample_run2.c +70 -0
  155. package/external/libedhoc/externals/Unity/test/expectdata/testsample_yaml.c +71 -0
  156. package/external/libedhoc/externals/Unity/test/testdata/CException.h +18 -0
  157. package/external/libedhoc/externals/Unity/test/testdata/Defs.h +16 -0
  158. package/external/libedhoc/externals/Unity/test/testdata/cmock.h +21 -0
  159. package/external/libedhoc/externals/Unity/test/testdata/mockMock.h +20 -0
  160. package/external/libedhoc/externals/Unity/test/testdata/testRunnerGenerator.c +204 -0
  161. package/external/libedhoc/externals/Unity/test/testdata/testRunnerGeneratorSmall.c +73 -0
  162. package/external/libedhoc/externals/Unity/test/testdata/testRunnerGeneratorWithMocks.c +200 -0
  163. package/external/libedhoc/externals/Unity/test/tests/self_assessment_utils.h +151 -0
  164. package/external/libedhoc/externals/Unity/test/tests/test_unity_arrays.c +2941 -0
  165. package/external/libedhoc/externals/Unity/test/tests/test_unity_core.c +375 -0
  166. package/external/libedhoc/externals/Unity/test/tests/test_unity_doubles.c +1285 -0
  167. package/external/libedhoc/externals/Unity/test/tests/test_unity_floats.c +1395 -0
  168. package/external/libedhoc/externals/Unity/test/tests/test_unity_integers.c +2863 -0
  169. package/external/libedhoc/externals/Unity/test/tests/test_unity_integers_64.c +783 -0
  170. package/external/libedhoc/externals/Unity/test/tests/test_unity_memory.c +82 -0
  171. package/external/libedhoc/externals/Unity/test/tests/test_unity_parameterized.c +309 -0
  172. package/external/libedhoc/externals/Unity/test/tests/test_unity_parameterizedDemo.c +28 -0
  173. package/external/libedhoc/externals/Unity/test/tests/test_unity_strings.c +330 -0
  174. package/external/libedhoc/externals/Unity/test/tests/types_for_test.h +21 -0
  175. package/external/libedhoc/externals/zcbor/include/zcbor_common.h +147 -60
  176. package/external/libedhoc/externals/zcbor/include/zcbor_decode.h +291 -202
  177. package/external/libedhoc/externals/zcbor/include/zcbor_encode.h +100 -156
  178. package/external/libedhoc/externals/zcbor/include/zcbor_print.h +165 -0
  179. package/external/libedhoc/externals/zcbor/samples/hello_world/src/main.c +1 -1
  180. package/external/libedhoc/externals/zcbor/samples/pet/include/pet_decode.h +1 -1
  181. package/external/libedhoc/externals/zcbor/samples/pet/include/pet_encode.h +1 -1
  182. package/external/libedhoc/externals/zcbor/samples/pet/include/pet_types.h +4 -4
  183. package/external/libedhoc/externals/zcbor/samples/pet/src/main.c +4 -4
  184. package/external/libedhoc/externals/zcbor/samples/pet/src/pet_decode.c +15 -24
  185. package/external/libedhoc/externals/zcbor/samples/pet/src/pet_encode.c +14 -23
  186. package/external/libedhoc/externals/zcbor/src/zcbor_common.c +202 -29
  187. package/external/libedhoc/externals/zcbor/src/zcbor_decode.c +633 -173
  188. package/external/libedhoc/externals/zcbor/src/zcbor_encode.c +71 -184
  189. package/external/libedhoc/externals/zcbor/tests/decode/test1_suit_old_formats/src/main.c +152 -153
  190. package/external/libedhoc/externals/zcbor/tests/decode/test2_suit/src/main.c +64 -64
  191. package/external/libedhoc/externals/zcbor/tests/decode/test3_simple/src/main.c +15 -16
  192. package/external/libedhoc/externals/zcbor/tests/decode/test5_corner_cases/src/main.c +228 -84
  193. package/external/libedhoc/externals/zcbor/tests/decode/test7_suit9_simple/src/main.c +9 -9
  194. package/external/libedhoc/externals/zcbor/tests/decode/test8_suit12/src/main.c +0 -1
  195. package/external/libedhoc/externals/zcbor/tests/decode/test9_manifest14/src/main.c +172 -173
  196. package/external/libedhoc/externals/zcbor/tests/encode/test1_suit/src/main.c +73 -73
  197. package/external/libedhoc/externals/zcbor/tests/encode/test2_simple/src/main.c +1 -2
  198. package/external/libedhoc/externals/zcbor/tests/encode/test3_corner_cases/src/main.c +83 -56
  199. package/external/libedhoc/externals/zcbor/tests/encode/test4_senml/src/main.c +15 -16
  200. package/external/libedhoc/externals/zcbor/tests/fuzz/fuzz_everything.c +12 -0
  201. package/external/libedhoc/externals/zcbor/tests/fuzz/fuzz_manifest12.c +69 -69
  202. package/external/libedhoc/externals/zcbor/tests/unit/test1_unit_tests/src/main.c +448 -55
  203. package/external/libedhoc/externals/zcbor/tests/unit/test3_float16/src/main.c +49 -48
  204. package/external/libedhoc/include/edhoc.h +348 -54
  205. package/external/libedhoc/include/edhoc_common.h +289 -0
  206. package/external/libedhoc/include/edhoc_context.h +60 -35
  207. package/external/libedhoc/include/edhoc_credentials.h +55 -7
  208. package/external/libedhoc/include/edhoc_crypto.h +10 -10
  209. package/external/libedhoc/include/edhoc_ead.h +13 -10
  210. package/external/libedhoc/include/edhoc_macros.h +20 -11
  211. package/external/libedhoc/include/edhoc_values.h +2 -2
  212. package/external/libedhoc/library/edhoc.c +70 -36
  213. package/external/libedhoc/library/edhoc_common.c +1314 -0
  214. package/external/libedhoc/library/edhoc_exporter.c +45 -46
  215. package/external/libedhoc/library/edhoc_message_1.c +107 -72
  216. package/external/libedhoc/library/edhoc_message_2.c +396 -1693
  217. package/external/libedhoc/library/edhoc_message_3.c +465 -1656
  218. package/external/libedhoc/library/edhoc_message_4.c +93 -91
  219. package/external/libedhoc/library/edhoc_message_error.c +41 -41
  220. package/external/libedhoc/tests/include/{cipher_suites/cipher_suite_0.h → cipher_suite_0.h} +131 -134
  221. package/external/libedhoc/tests/include/{cipher_suites/cipher_suite_2.h → cipher_suite_2.h} +139 -140
  222. package/external/libedhoc/tests/include/{edhoc_trace_1/test_vector_1.h → test_vector_rfc9529_chapter_2.h} +786 -738
  223. package/external/libedhoc/tests/include/{edhoc_trace_2/test_vector_2.h → test_vector_rfc9529_chapter_3.h} +14 -10
  224. package/external/libedhoc/tests/include/{x509_chain_cs_0/test_vector_x5chain_cs_0.h → test_vector_x5chain_sign_keys_suite_0.h} +137 -140
  225. package/external/libedhoc/tests/include/{x509_chain_cs_2/test_vector_x5chain_cs_2.h → test_vector_x5chain_sign_keys_suite_2.h} +7 -8
  226. package/external/libedhoc/tests/include/{x509_chain_cs_2_static_dh/test_vector_x5chain_cs_2_static_dh.h → test_vector_x5chain_static_dh_keys_suite_2.h} +7 -8
  227. package/external/libedhoc/tests/include/{x509_hash_cs_2/test_vector_x5t_cs_2.h → test_vector_x5t_sign_keys_suite_2.h} +6 -7
  228. package/external/libedhoc/tests/src/{cipher_suites/cipher_suite_0.c → cipher_suite_0.c} +445 -447
  229. package/external/libedhoc/tests/src/{cipher_suites/cipher_suite_2.c → cipher_suite_2.c} +600 -600
  230. package/external/libedhoc/tests/src/module_test_api.c +430 -0
  231. package/external/libedhoc/tests/src/module_test_cipher_suite_0.c +395 -0
  232. package/external/libedhoc/tests/src/module_test_cipher_suite_2.c +392 -0
  233. package/external/libedhoc/tests/src/{error_message/test_edhoc_error_message.c → module_test_error_message.c} +94 -69
  234. package/external/libedhoc/tests/src/module_test_main.c +49 -0
  235. package/external/libedhoc/tests/src/{cipher_suite_negotiation/test_edhoc_cipher_suite_negotiation.c → module_test_rfc9528_suites_negotiation.c} +224 -227
  236. package/external/libedhoc/tests/src/module_test_rfc9529_chapter_2.c +2681 -0
  237. package/external/libedhoc/tests/src/module_test_rfc9529_chapter_3.c +1635 -0
  238. package/external/libedhoc/tests/src/module_test_x5chain_sign_keys_suite_0.c +1135 -0
  239. package/external/libedhoc/tests/src/module_test_x5chain_sign_keys_suite_2.c +1249 -0
  240. package/external/libedhoc/tests/src/module_test_x5chain_static_dh_keys_suite_2.c +798 -0
  241. package/external/libedhoc/tests/src/module_test_x5t_sign_keys_suite_2.c +956 -0
  242. package/include/EdhocComposeAsyncWorker.h +8 -6
  243. package/include/EdhocCredentialManager.h +16 -11
  244. package/include/EdhocCryptoManager.h +28 -21
  245. package/include/EdhocEadManager.h +3 -6
  246. package/include/{EdhocExportAsyncWorker.h → EdhocExportOscoreAsyncWorker.h} +20 -17
  247. package/include/EdhocKeyExporterAsyncWorker.h +76 -0
  248. package/include/EdhocKeyUpdateAsyncWorker.h +72 -0
  249. package/include/EdhocProcessAsyncWorker.h +14 -10
  250. package/include/LibEDHOC.h +44 -20
  251. package/include/UserContext.h +7 -9
  252. package/include/Utils.h +31 -27
  253. package/package.json +14 -3
  254. package/prebuilds/android-arm/edhoc.armv7.node +0 -0
  255. package/prebuilds/android-arm64/edhoc.armv8.node +0 -0
  256. package/prebuilds/darwin-arm64/edhoc.node +0 -0
  257. package/prebuilds/darwin-x64/edhoc.node +0 -0
  258. package/prebuilds/linux-arm/edhoc.armv6.node +0 -0
  259. package/prebuilds/linux-arm/edhoc.armv7.node +0 -0
  260. package/prebuilds/linux-arm64/edhoc.armv8.node +0 -0
  261. package/prebuilds/linux-x64/edhoc.glibc.node +0 -0
  262. package/prebuilds/linux-x64/edhoc.musl.node +0 -0
  263. package/prebuilds/win32-ia32/edhoc.node +0 -0
  264. package/prebuilds/win32-x64/edhoc.node +0 -0
  265. package/src/EdhocComposeAsyncWorker.cpp +18 -35
  266. package/src/EdhocCredentialManager.cpp +160 -187
  267. package/src/EdhocCryptoManager.cpp +386 -586
  268. package/src/EdhocEadManager.cpp +10 -18
  269. package/src/EdhocExportOscoreAsyncWorker.cpp +77 -0
  270. package/src/EdhocKeyExporterAsyncWorker.cpp +49 -0
  271. package/src/EdhocKeyUpdateAsyncWorker.cpp +41 -0
  272. package/src/EdhocProcessAsyncWorker.cpp +72 -19
  273. package/src/LibEDHOC.cpp +213 -174
  274. package/src/Suites.cpp +39 -72
  275. package/src/Utils.cpp +32 -56
  276. package/test/basic.test.ts +64 -0
  277. package/test/vectors.test.ts +111 -0
  278. package/external/libedhoc/externals/zcbor/include/zcbor_debug.h +0 -69
  279. package/external/libedhoc/tests/include/cipher_suite_negotiation/test_edhoc_cipher_suite_negotiation.h +0 -37
  280. package/external/libedhoc/tests/include/cipher_suites/test_cipher_suite_0.h +0 -48
  281. package/external/libedhoc/tests/include/cipher_suites/test_cipher_suite_2.h +0 -48
  282. package/external/libedhoc/tests/include/edhoc_trace_1/authentication_credentials_1.h +0 -60
  283. package/external/libedhoc/tests/include/edhoc_trace_1/test_edhoc_handshake_1.h +0 -208
  284. package/external/libedhoc/tests/include/edhoc_trace_1/test_edhoc_handshake_ead_1.h +0 -59
  285. package/external/libedhoc/tests/include/edhoc_trace_2/authentication_credentials_2.h +0 -60
  286. package/external/libedhoc/tests/include/edhoc_trace_2/test_edhoc_handshake_2.h +0 -199
  287. package/external/libedhoc/tests/include/error_message/test_edhoc_error_message.h +0 -48
  288. package/external/libedhoc/tests/include/x509_chain_cs_0/authentication_credentials_x5chain_cs_0.h +0 -92
  289. package/external/libedhoc/tests/include/x509_chain_cs_0/test_edhoc_handshake_x5chain_cs_0.h +0 -96
  290. package/external/libedhoc/tests/include/x509_chain_cs_2/authentication_credentials_x5chain_cs_2.h +0 -58
  291. package/external/libedhoc/tests/include/x509_chain_cs_2/test_edhoc_handshake_x5chain_cs_2.h +0 -56
  292. package/external/libedhoc/tests/include/x509_chain_cs_2/test_edhoc_handshake_x5chain_cs_2_ead.h +0 -57
  293. package/external/libedhoc/tests/include/x509_chain_cs_2_static_dh/authentication_credentials_x5chain_cs_2_static_dh.h +0 -59
  294. package/external/libedhoc/tests/include/x509_chain_cs_2_static_dh/test_edhoc_handshake_x5chain_cs_2_static_dh_ead.h +0 -57
  295. package/external/libedhoc/tests/include/x509_hash_cs_2/authentication_credentials_x5t_cs_2.h +0 -60
  296. package/external/libedhoc/tests/include/x509_hash_cs_2/test_edhoc_handshake_x5t_cs_2_ead.h +0 -57
  297. package/external/libedhoc/tests/src/cipher_suites/test_cipher_suite_0.c +0 -475
  298. package/external/libedhoc/tests/src/cipher_suites/test_cipher_suite_2.c +0 -473
  299. package/external/libedhoc/tests/src/edhoc_trace_1/authentication_credentials_1.c +0 -252
  300. package/external/libedhoc/tests/src/edhoc_trace_1/test_edhoc_handshake_1.c +0 -1829
  301. package/external/libedhoc/tests/src/edhoc_trace_1/test_edhoc_handshake_ead_1.c +0 -1247
  302. package/external/libedhoc/tests/src/edhoc_trace_2/authentication_credentials_2.c +0 -170
  303. package/external/libedhoc/tests/src/edhoc_trace_2/test_edhoc_handshake_2.c +0 -1783
  304. package/external/libedhoc/tests/src/tests.c +0 -228
  305. package/external/libedhoc/tests/src/x509_chain_cs_0/authentication_credentials_x5chain_cs_0.c +0 -332
  306. package/external/libedhoc/tests/src/x509_chain_cs_0/test_edhoc_handshake_x5chain_cs_0.c +0 -936
  307. package/external/libedhoc/tests/src/x509_chain_cs_2/authentication_credentials_x5chain_cs_2.c +0 -166
  308. package/external/libedhoc/tests/src/x509_chain_cs_2/test_edhoc_handshake_x5chain_cs_2.c +0 -587
  309. package/external/libedhoc/tests/src/x509_chain_cs_2/test_edhoc_handshake_x5chain_cs_2_ead.c +0 -917
  310. package/external/libedhoc/tests/src/x509_chain_cs_2_static_dh/authentication_credentials_x5chain_cs_2_static_dh.c +0 -186
  311. package/external/libedhoc/tests/src/x509_chain_cs_2_static_dh/test_edhoc_handshake_x5chain_cs_2_static_dh_ead.c +0 -743
  312. package/external/libedhoc/tests/src/x509_hash_cs_2/authentication_credentials_x5t_cs_2.c +0 -261
  313. package/external/libedhoc/tests/src/x509_hash_cs_2/test_edhoc_handshake_x5t_cs_2_ead.c +0 -854
  314. package/src/EdhocExportAsyncWorker.cpp +0 -82
@@ -1,738 +1,786 @@
1
- /**
2
- * \file test_vector_1.h
3
- * \author Kamil Kielbasa
4
- * \brief Test vector from EDHOC traces (RFC 9529) for chapter 2.
5
- * It contains authentication with signatures, X.509 identified by 'x5t'.
6
- *
7
- * \version 0.4
8
- * \date 2024-01-01
9
- *
10
- * \copyright Copyright (c) 2024
11
- *
12
- */
13
-
14
- /* Header guard ------------------------------------------------------------ */
15
- #ifndef TEST_VECTOR_1_H
16
- #define TEST_VECTOR_1_H
17
-
18
- /* Include files ----------------------------------------------------------- */
19
- #include <stdint.h>
20
-
21
- /* Defines ----------------------------------------------------------------- */
22
- /* Types and type definitions ---------------------------------------------- */
23
- /* Module interface variables and constants -------------------------------- */
24
-
25
- /**
26
- * \brief EDHOC message 1.
27
- */
28
-
29
- static const uint8_t METHOD = 0;
30
-
31
- static const int32_t SUITES_I[] = { 0 };
32
-
33
- static const uint8_t X[] = {
34
- 0x89, 0x2e, 0xc2, 0x8e, 0x5c, 0xb6, 0x66, 0x91, 0x08, 0x47, 0x05,
35
- 0x39, 0x50, 0x0b, 0x70, 0x5e, 0x60, 0xd0, 0x08, 0xd3, 0x47, 0xc5,
36
- 0x81, 0x7e, 0xe9, 0xf3, 0x32, 0x7c, 0x8a, 0x87, 0xbb, 0x03,
37
- };
38
-
39
- static const uint8_t G_X[] = {
40
- 0x31, 0xf8, 0x2c, 0x7b, 0x5b, 0x9c, 0xbb, 0xf0, 0xf1, 0x94, 0xd9,
41
- 0x13, 0xcc, 0x12, 0xef, 0x15, 0x32, 0xd3, 0x28, 0xef, 0x32, 0x63,
42
- 0x2a, 0x48, 0x81, 0xa1, 0xc0, 0x70, 0x1e, 0x23, 0x7f, 0x04,
43
- };
44
-
45
- static const uint8_t C_I[] = { -14 };
46
-
47
- static const uint8_t message_1[] = {
48
- 0x00, 0x00, 0x58, 0x20, 0x31, 0xf8, 0x2c, 0x7b, 0x5b, 0x9c,
49
- 0xbb, 0xf0, 0xf1, 0x94, 0xd9, 0x13, 0xcc, 0x12, 0xef, 0x15,
50
- 0x32, 0xd3, 0x28, 0xef, 0x32, 0x63, 0x2a, 0x48, 0x81, 0xa1,
51
- 0xc0, 0x70, 0x1e, 0x23, 0x7f, 0x04, 0x2d,
52
- };
53
-
54
- /**
55
- * \brief EDHOC message 2.
56
- */
57
-
58
- static const uint8_t SUITES_R[] = { 0 };
59
-
60
- static const uint8_t Y[] = {
61
- 0xe6, 0x9c, 0x23, 0xfb, 0xf8, 0x1b, 0xc4, 0x35, 0x94, 0x24, 0x46,
62
- 0x83, 0x7f, 0xe8, 0x27, 0xbf, 0x20, 0x6c, 0x8f, 0xa1, 0x0a, 0x39,
63
- 0xdb, 0x47, 0x44, 0x9e, 0x5a, 0x81, 0x34, 0x21, 0xe1, 0xe8,
64
- };
65
-
66
- static const uint8_t G_Y[] = {
67
- 0xdc, 0x88, 0xd2, 0xd5, 0x1d, 0xa5, 0xed, 0x67, 0xfc, 0x46, 0x16,
68
- 0x35, 0x6b, 0xc8, 0xca, 0x74, 0xef, 0x9e, 0xbe, 0x8b, 0x38, 0x7e,
69
- 0x62, 0x3a, 0x36, 0x0b, 0xa4, 0x80, 0xb9, 0xb2, 0x9d, 0x1c,
70
- };
71
-
72
- static const uint8_t C_R[] = { 24 };
73
-
74
- static const uint8_t H_message_1[] = {
75
- 0xc1, 0x65, 0xd6, 0xa9, 0x9d, 0x1b, 0xca, 0xfa, 0xac, 0x8d, 0xbf,
76
- 0x2b, 0x35, 0x2a, 0x6f, 0x7d, 0x71, 0xa3, 0x0b, 0x43, 0x9c, 0x9d,
77
- 0x64, 0xd3, 0x49, 0xa2, 0x38, 0x48, 0x03, 0x8e, 0xd1, 0x6b,
78
- };
79
-
80
- static const uint8_t TH_2[] = {
81
- 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2,
82
- 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79,
83
- 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d,
84
- };
85
-
86
- static const uint8_t G_XY[] = {
87
- 0xe5, 0xcd, 0xf3, 0xa9, 0x86, 0xcd, 0xac, 0x5b, 0x7b, 0xf0, 0x46,
88
- 0x91, 0xe2, 0xb0, 0x7c, 0x08, 0xe7, 0x1f, 0x53, 0x99, 0x8d, 0x8f,
89
- 0x84, 0x2b, 0x7c, 0x3f, 0xb4, 0xd8, 0x39, 0xcf, 0x7b, 0x28,
90
- };
91
-
92
- static const uint8_t PRK_2e[] = {
93
- 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
94
- 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
95
- 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
96
- };
97
-
98
- static const uint8_t SK_R[] = {
99
- 0xef, 0x14, 0x0f, 0xf9, 0x00, 0xb0, 0xab, 0x03, 0xf0, 0xc0, 0x8d,
100
- 0x87, 0x9c, 0xbb, 0xd4, 0xb3, 0x1e, 0xa7, 0x1e, 0x6e, 0x7e, 0xe7,
101
- 0xff, 0xcb, 0x7e, 0x79, 0x55, 0x77, 0x7a, 0x33, 0x27, 0x99,
102
-
103
- 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
104
- 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6,
105
- 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59,
106
- };
107
-
108
- static const uint8_t PK_R[] = {
109
- 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
110
- 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6,
111
- 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59,
112
- };
113
-
114
- static const uint8_t PRK_3e2m[] = {
115
- 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
116
- 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
117
- 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
118
- };
119
-
120
- static const uint8_t ID_CRED_R_cborised[] = {
121
- 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79,
122
- 0xf2, 0xa4, 0x1b, 0x51, 0x0c, 0x1f, 0x9b,
123
- };
124
-
125
- static const uint8_t CRED_R[] = {
126
- 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02,
127
- 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
128
- 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c,
129
- 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20,
130
- 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32,
131
- 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a,
132
- 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30,
133
- 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55,
134
- 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65,
135
- 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35,
136
- 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
137
- 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1,
138
- 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2,
139
- 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30,
140
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc,
141
- 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc,
142
- 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec,
143
- 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6,
144
- 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65,
145
- 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb,
146
- 0x02,
147
- };
148
-
149
- static const uint8_t context_2[] = {
150
- 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b,
151
- 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56,
152
- 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f,
153
- 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61,
154
- 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03,
155
- 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06,
156
- 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03,
157
- 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52,
158
- 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
159
- 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32,
160
- 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31,
161
- 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30,
162
- 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f,
163
- 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20,
164
- 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06,
165
- 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51,
166
- 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac,
167
- 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9,
168
- 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41,
169
- 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c,
170
- 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0,
171
- 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc,
172
- 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a,
173
- 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab,
174
- 0x82, 0xc1, 0x52, 0xcb, 0x02,
175
- };
176
-
177
- static const uint8_t MAC_2_info_cborised[] = {
178
- 0x02, 0x59, 0x01, 0x25, 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48,
179
- 0x79, 0xf2, 0xa4, 0x1b, 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x20, 0xc6, 0x40,
180
- 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50,
181
- 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca,
182
- 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30,
183
- 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e,
184
- 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b,
185
- 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48,
186
- 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35,
187
- 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31,
188
- 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39,
189
- 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30,
190
- 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17,
191
- 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
192
- 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
193
- 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1,
194
- 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35,
195
- 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b,
196
- 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b,
197
- 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92,
198
- 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e,
199
- 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37,
200
- 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10,
201
- 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51,
202
- 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02, 0x18, 0x20,
203
- };
204
-
205
- static const uint8_t MAC_2[] = {
206
- 0x86, 0x2a, 0x7e, 0x5e, 0xf1, 0x47, 0xf9, 0xa5, 0xf4, 0xc5, 0x12,
207
- 0xe1, 0xb6, 0x62, 0x3c, 0xd6, 0x6c, 0xd1, 0x7a, 0x72, 0x72, 0x07,
208
- 0x2b, 0xfe, 0x5b, 0x60, 0x2f, 0xfe, 0x30, 0x7e, 0xe0, 0xe9,
209
- };
210
-
211
- static const uint8_t Signature_or_MAC_2_input[] = {
212
- 0x84, 0x6a, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x31,
213
- 0x4e, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b, 0x51,
214
- 0x0c, 0x1f, 0x9b, 0x59, 0x01, 0x15, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15,
215
- 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54,
216
- 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c,
217
- 0x90, 0x61, 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
218
- 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30,
219
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
220
- 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
221
- 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
222
- 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
223
- 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
224
- 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
225
- 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
226
- 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65,
227
- 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
228
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47,
229
- 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41,
230
- 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5,
231
- 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
232
- 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b,
233
- 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69,
234
- 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf,
235
- 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37,
236
- 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae,
237
- 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02, 0x58, 0x20, 0x86, 0x2a, 0x7e,
238
- 0x5e, 0xf1, 0x47, 0xf9, 0xa5, 0xf4, 0xc5, 0x12, 0xe1, 0xb6, 0x62, 0x3c,
239
- 0xd6, 0x6c, 0xd1, 0x7a, 0x72, 0x72, 0x07, 0x2b, 0xfe, 0x5b, 0x60, 0x2f,
240
- 0xfe, 0x30, 0x7e, 0xe0, 0xe9,
241
- };
242
-
243
- static const uint8_t Signature_or_MAC_2[] = {
244
- 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4, 0x4a, 0x08, 0x5c, 0x03, 0xd3,
245
- 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5, 0x72, 0xa1, 0x96, 0x8c,
246
- 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81, 0x60, 0x8d, 0x3d,
247
- 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d, 0x89, 0xac,
248
- 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9, 0x98,
249
- 0x70, 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09,
250
- };
251
-
252
- static const uint8_t PLAINTEXT_2[] = {
253
- 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b,
254
- 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x40, 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4,
255
- 0x4a, 0x08, 0x5c, 0x03, 0xd3, 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5,
256
- 0x72, 0xa1, 0x96, 0x8c, 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81,
257
- 0x60, 0x8d, 0x3d, 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d,
258
- 0x89, 0xac, 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9,
259
- 0x98, 0x70, 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09,
260
- };
261
-
262
- static const uint8_t KEYSTREAM_2_info[] = {
263
- 0x00, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74,
264
- 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e,
265
- 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6,
266
- 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x18, 0x52,
267
- };
268
-
269
- static const uint8_t KEYSTERAM_2[] = {
270
- 0xfd, 0x3e, 0x7c, 0x3f, 0x2d, 0x6b, 0xee, 0x64, 0x3d, 0x3c, 0x9d, 0x2f,
271
- 0x28, 0x47, 0x03, 0x5d, 0x73, 0xe2, 0xec, 0xb0, 0xf8, 0xdb, 0x5c, 0xd1,
272
- 0xc6, 0x85, 0x4e, 0x24, 0x89, 0x6a, 0xf2, 0x11, 0x88, 0xb2, 0xc4, 0x34,
273
- 0x4e, 0x68, 0x9e, 0xc2, 0x98, 0x42, 0x83, 0xd9, 0xfb, 0xc6, 0x9c, 0xe1,
274
- 0xc5, 0xdb, 0x10, 0xdc, 0xff, 0xf2, 0x4d, 0xf9, 0xa4, 0x9a, 0x04, 0xa9,
275
- 0x40, 0x58, 0x27, 0x7b, 0xc7, 0xfa, 0x9a, 0xd6, 0xc6, 0xb1, 0x94, 0xab,
276
- 0x32, 0x8b, 0x44, 0x5e, 0xb0, 0x80, 0x49, 0x0c, 0xd7, 0x86,
277
- };
278
-
279
- static const uint8_t CIPHERTEXT_2[] = {
280
- 0xbc, 0x26, 0xdd, 0x27, 0x0f, 0xe9, 0xc0, 0x2c, 0x44, 0xce, 0x39, 0x34,
281
- 0x79, 0x4b, 0x1c, 0xc6, 0x2b, 0xa2, 0x2f, 0x05, 0x45, 0x9f, 0x8d, 0x35,
282
- 0x8c, 0x8d, 0x12, 0x27, 0x5a, 0xc4, 0x2c, 0x5f, 0x96, 0xde, 0xd5, 0xf1,
283
- 0x3c, 0xc9, 0x08, 0x4e, 0x5b, 0x20, 0x18, 0x89, 0xa4, 0x5e, 0x5a, 0x60,
284
- 0xa5, 0x56, 0x2d, 0xc1, 0x18, 0x61, 0x9c, 0x3d, 0xaa, 0x2f, 0xd9, 0xf4,
285
- 0xc9, 0xf4, 0xd6, 0xed, 0xad, 0x10, 0x9d, 0xd4, 0xed, 0xf9, 0x59, 0x62,
286
- 0xaa, 0xfb, 0xaf, 0x9a, 0xb3, 0xf4, 0xa1, 0xf6, 0xb9, 0x8f,
287
- };
288
-
289
- static const uint8_t message_2[] = {
290
- 0x58, 0x72, 0xdc, 0x88, 0xd2, 0xd5, 0x1d, 0xa5, 0xed, 0x67, 0xfc, 0x46,
291
- 0x16, 0x35, 0x6b, 0xc8, 0xca, 0x74, 0xef, 0x9e, 0xbe, 0x8b, 0x38, 0x7e,
292
- 0x62, 0x3a, 0x36, 0x0b, 0xa4, 0x80, 0xb9, 0xb2, 0x9d, 0x1c, 0xbc, 0x26,
293
- 0xdd, 0x27, 0x0f, 0xe9, 0xc0, 0x2c, 0x44, 0xce, 0x39, 0x34, 0x79, 0x4b,
294
- 0x1c, 0xc6, 0x2b, 0xa2, 0x2f, 0x05, 0x45, 0x9f, 0x8d, 0x35, 0x8c, 0x8d,
295
- 0x12, 0x27, 0x5a, 0xc4, 0x2c, 0x5f, 0x96, 0xde, 0xd5, 0xf1, 0x3c, 0xc9,
296
- 0x08, 0x4e, 0x5b, 0x20, 0x18, 0x89, 0xa4, 0x5e, 0x5a, 0x60, 0xa5, 0x56,
297
- 0x2d, 0xc1, 0x18, 0x61, 0x9c, 0x3d, 0xaa, 0x2f, 0xd9, 0xf4, 0xc9, 0xf4,
298
- 0xd6, 0xed, 0xad, 0x10, 0x9d, 0xd4, 0xed, 0xf9, 0x59, 0x62, 0xaa, 0xfb,
299
- 0xaf, 0x9a, 0xb3, 0xf4, 0xa1, 0xf6, 0xb9, 0x8f,
300
- };
301
-
302
- /**
303
- * \brief EDHOC message 3.
304
- */
305
-
306
- static const uint8_t SK_I[] = {
307
- 0x4c, 0x5b, 0x25, 0x87, 0x8f, 0x50, 0x7c, 0x6b, 0x9d, 0xae, 0x68,
308
- 0xfb, 0xd4, 0xfd, 0x3f, 0xf9, 0x97, 0x53, 0x3d, 0xb0, 0xaf, 0x00,
309
- 0xb2, 0x5d, 0x32, 0x4e, 0xa2, 0x8e, 0x6c, 0x21, 0x3b, 0xc8,
310
-
311
- 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45,
312
- 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e,
313
- 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e,
314
- };
315
-
316
- static const uint8_t PK_I[] = {
317
- 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45,
318
- 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e,
319
- 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e,
320
- };
321
-
322
- static const uint8_t TH_3_input[] = {
323
- 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d,
324
- 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79,
325
- 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x41, 0x18,
326
- 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b, 0x51, 0x0c,
327
- 0x1f, 0x9b, 0x58, 0x40, 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4, 0x4a, 0x08,
328
- 0x5c, 0x03, 0xd3, 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5, 0x72, 0xa1,
329
- 0x96, 0x8c, 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81, 0x60, 0x8d,
330
- 0x3d, 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d, 0x89, 0xac,
331
- 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9, 0x98, 0x70,
332
- 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09, 0x58, 0xf1, 0x30, 0x81,
333
- 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62,
334
- 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d,
335
- 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45,
336
- 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64,
337
- 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30,
338
- 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d,
339
- 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30,
340
- 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03,
341
- 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70,
342
- 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
343
- 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21,
344
- 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
345
- 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62,
346
- 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06,
347
- 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea,
348
- 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23,
349
- 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1,
350
- 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30,
351
- 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d,
352
- 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02,
353
- };
354
-
355
- static const uint8_t TH_3[] = {
356
- 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e,
357
- 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6,
358
- 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
359
- };
360
-
361
- static const uint8_t PRK_4e3m[] = {
362
- 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
363
- 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
364
- 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
365
- };
366
-
367
- static const uint8_t ID_CRED_I_cborised[] = {
368
- 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2,
369
- 0x4a, 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f,
370
- };
371
-
372
- static const uint8_t CRED_I[] = {
373
- 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02,
374
- 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
375
- 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c,
376
- 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20,
377
- 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32,
378
- 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a,
379
- 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30,
380
- 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55,
381
- 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e,
382
- 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35,
383
- 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
384
- 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f,
385
- 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4,
386
- 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30,
387
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0x52, 0x12, 0x41,
388
- 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7,
389
- 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92,
390
- 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb,
391
- 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff,
392
- 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43,
393
- 0x0b,
394
- };
395
-
396
- static const uint8_t context_3[] = {
397
- 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43,
398
- 0xc7, 0x9f, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c,
399
- 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca,
400
- 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
401
- 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01,
402
- 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b,
403
- 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04,
404
- 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f,
405
- 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17,
406
- 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x30,
407
- 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33,
408
- 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06,
409
- 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20,
410
- 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64,
411
- 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b,
412
- 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29,
413
- 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3,
414
- 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14,
415
- 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0x52,
416
- 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea,
417
- 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10,
418
- 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d,
419
- 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05,
420
- 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0,
421
- 0x0b, 0x43, 0x0b,
422
- };
423
-
424
- static const uint8_t MAC_3_info[] = {
425
- 0x06, 0x59, 0x01, 0x23, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a,
426
- 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4,
427
- 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff,
428
- 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65,
429
- 0x92, 0xe9, 0x28, 0xbc, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
430
- 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30,
431
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
432
- 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
433
- 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
434
- 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
435
- 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
436
- 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
437
- 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
438
- 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f,
439
- 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
440
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8,
441
- 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f,
442
- 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20,
443
- 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
444
- 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b,
445
- 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a,
446
- 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01,
447
- 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21,
448
- 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa,
449
- 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b, 0x18, 0x20,
450
- };
451
-
452
- static const uint8_t MAC_3[] = {
453
- 0x39, 0xb1, 0x27, 0xc1, 0x30, 0x12, 0x9a, 0xfa, 0x30, 0x61, 0x8c,
454
- 0x75, 0x13, 0x29, 0xe6, 0x37, 0xcc, 0x37, 0x34, 0x27, 0x0d, 0x4b,
455
- 0x01, 0x25, 0x84, 0x45, 0xa8, 0xee, 0x02, 0xda, 0xa3, 0xbd,
456
- };
457
-
458
- static const uint8_t Signature_or_MAC_3_input[] = {
459
- 0x84, 0x6a, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x31,
460
- 0x4e, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76,
461
- 0x43, 0xc7, 0x9f, 0x59, 0x01, 0x15, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4,
462
- 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff,
463
- 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65,
464
- 0x92, 0xe9, 0x28, 0xbc, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
465
- 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30,
466
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
467
- 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
468
- 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
469
- 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
470
- 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
471
- 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
472
- 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
473
- 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f,
474
- 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
475
- 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8,
476
- 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f,
477
- 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20,
478
- 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
479
- 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b,
480
- 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a,
481
- 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01,
482
- 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21,
483
- 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa,
484
- 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b, 0x58, 0x20, 0x39, 0xb1, 0x27,
485
- 0xc1, 0x30, 0x12, 0x9a, 0xfa, 0x30, 0x61, 0x8c, 0x75, 0x13, 0x29, 0xe6,
486
- 0x37, 0xcc, 0x37, 0x34, 0x27, 0x0d, 0x4b, 0x01, 0x25, 0x84, 0x45, 0xa8,
487
- 0xee, 0x02, 0xda, 0xa3, 0xbd,
488
- };
489
-
490
- static const uint8_t Signature_or_MAC_3[] = {
491
- 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1, 0xb5, 0xaf, 0x81,
492
- 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55, 0x95, 0x7f,
493
- 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18, 0x6a,
494
- 0x0d, 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec,
495
- 0xb9, 0xcf, 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca,
496
- 0x11, 0x8c, 0xe4, 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07,
497
- };
498
-
499
- static const uint8_t PLAINTET_3[] = {
500
- 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43,
501
- 0xc7, 0x9f, 0x58, 0x40, 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1,
502
- 0xb5, 0xaf, 0x81, 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55,
503
- 0x95, 0x7f, 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18,
504
- 0x6a, 0x0d, 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec,
505
- 0xb9, 0xcf, 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca, 0x11,
506
- 0x8c, 0xe4, 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07,
507
- };
508
-
509
- static const uint8_t A_3[] = {
510
- 0x83, 0x68, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x30, 0x40, 0x58,
511
- 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e,
512
- 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69,
513
- 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
514
- };
515
-
516
- static const uint8_t K_3_info[] = {
517
- 0x03, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0,
518
- 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57,
519
- 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0x10,
520
- };
521
-
522
- static const uint8_t K_3[] = {
523
- 0xda, 0x19, 0x5e, 0x5f, 0x64, 0x8a, 0xc6, 0x3b,
524
- 0x0e, 0x8f, 0xb0, 0xc4, 0x55, 0x20, 0x51, 0x39,
525
- };
526
-
527
- static const uint8_t IV_3_info[] = {
528
- 0x04, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0,
529
- 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57,
530
- 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0x0d,
531
- };
532
-
533
- static const uint8_t IV_3[] = {
534
- 0x38, 0xd8, 0xc6, 0x4c, 0x56, 0x25, 0x5a,
535
- 0xff, 0xa4, 0x49, 0xf4, 0xbe, 0xd7,
536
- };
537
-
538
- static const uint8_t CIPHERTEXT_3[] = {
539
- 0x25, 0xc3, 0x45, 0x88, 0x4a, 0xaa, 0xeb, 0x22, 0xc5, 0x27, 0xf9,
540
- 0xb1, 0xd2, 0xb6, 0x78, 0x72, 0x07, 0xe0, 0x16, 0x3c, 0x69, 0xb6,
541
- 0x2a, 0x0d, 0x43, 0x92, 0x81, 0x50, 0x42, 0x72, 0x03, 0xc3, 0x16,
542
- 0x74, 0xe4, 0x51, 0x4e, 0xa6, 0xe3, 0x83, 0xb5, 0x66, 0xeb, 0x29,
543
- 0x76, 0x3e, 0xfe, 0xb0, 0xaf, 0xa5, 0x18, 0x77, 0x6a, 0xe1, 0xc6,
544
- 0x5f, 0x85, 0x6d, 0x84, 0xbf, 0x32, 0xaf, 0x3a, 0x78, 0x36, 0x97,
545
- 0x04, 0x66, 0xdc, 0xb7, 0x1f, 0x76, 0x74, 0x5d, 0x39, 0xd3, 0x02,
546
- 0x5e, 0x77, 0x03, 0xe0, 0xc0, 0x32, 0xeb, 0xad, 0x51, 0x94, 0x7c,
547
- };
548
-
549
- static const uint8_t message_3[] = {
550
- 0x58, 0x58, 0x25, 0xc3, 0x45, 0x88, 0x4a, 0xaa, 0xeb, 0x22, 0xc5, 0x27,
551
- 0xf9, 0xb1, 0xd2, 0xb6, 0x78, 0x72, 0x07, 0xe0, 0x16, 0x3c, 0x69, 0xb6,
552
- 0x2a, 0x0d, 0x43, 0x92, 0x81, 0x50, 0x42, 0x72, 0x03, 0xc3, 0x16, 0x74,
553
- 0xe4, 0x51, 0x4e, 0xa6, 0xe3, 0x83, 0xb5, 0x66, 0xeb, 0x29, 0x76, 0x3e,
554
- 0xfe, 0xb0, 0xaf, 0xa5, 0x18, 0x77, 0x6a, 0xe1, 0xc6, 0x5f, 0x85, 0x6d,
555
- 0x84, 0xbf, 0x32, 0xaf, 0x3a, 0x78, 0x36, 0x97, 0x04, 0x66, 0xdc, 0xb7,
556
- 0x1f, 0x76, 0x74, 0x5d, 0x39, 0xd3, 0x02, 0x5e, 0x77, 0x03, 0xe0, 0xc0,
557
- 0x32, 0xeb, 0xad, 0x51, 0x94, 0x7c,
558
- };
559
-
560
- static const uint8_t TH_4_input[] = {
561
- 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41,
562
- 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6,
563
- 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0xa1, 0x18,
564
- 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f,
565
- 0x58, 0x40, 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1, 0xb5, 0xaf,
566
- 0x81, 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55, 0x95, 0x7f,
567
- 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18, 0x6a, 0x0d,
568
- 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec, 0xb9, 0xcf,
569
- 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca, 0x11, 0x8c, 0xe4,
570
- 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30,
571
- 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e,
572
- 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b,
573
- 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48,
574
- 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35,
575
- 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31,
576
- 0x36, 0x30, 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39,
577
- 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30,
578
- 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17,
579
- 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61,
580
- 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
581
- 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed,
582
- 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9,
583
- 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8,
584
- 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b,
585
- 0x65, 0x70, 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70,
586
- 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb,
587
- 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7,
588
- 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f,
589
- 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8,
590
- 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b,
591
- };
592
-
593
- static const uint8_t TH_4[] = {
594
- 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc, 0xcd, 0x39,
595
- 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe, 0x42,
596
- 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac,
597
- };
598
-
599
- /**
600
- * \brief EDHOC message 4.
601
- */
602
-
603
- static const uint8_t A_4[] = {
604
- 0x83, 0x68, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x30, 0x40, 0x58,
605
- 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc, 0xcd, 0x39,
606
- 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe, 0x42, 0xd5,
607
- 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac,
608
- };
609
-
610
- static const uint8_t K_4_info[] = {
611
- 0x08, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc,
612
- 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe,
613
- 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x10,
614
- };
615
-
616
- static const uint8_t K_4[] = {
617
- 0xdf, 0x8c, 0xb5, 0x86, 0x1e, 0x1f, 0xdf, 0xed,
618
- 0xd3, 0xb2, 0x30, 0x15, 0xa3, 0x9d, 0x1e, 0x2e,
619
- };
620
-
621
- static const uint8_t IV_4_info[] = {
622
-
623
- 0x09, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc,
624
- 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe,
625
- 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x0d,
626
- };
627
-
628
- static const uint8_t IV_4[] = {
629
- 0x12, 0x8e, 0xc6, 0x58, 0xd9, 0x70, 0xd7,
630
- 0x38, 0x0f, 0x74, 0xfc, 0x6c, 0x27,
631
- };
632
-
633
- static const uint8_t CIPHERTEXT_4[] = {
634
- 0x4f, 0x0e, 0xde, 0xe3, 0x66, 0xe5, 0xc8, 0x83,
635
- };
636
-
637
- static const uint8_t message_4[] = {
638
- 0x48, 0x4f, 0x0e, 0xde, 0xe3, 0x66, 0xe5, 0xc8, 0x83,
639
- };
640
-
641
- /**
642
- * \brief PRK_out
643
- */
644
-
645
- static const uint8_t PRK_out_info[] = {
646
- 0x07, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35,
647
- 0x55, 0xdc, 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37,
648
- 0x50, 0xd5, 0x99, 0xbe, 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37,
649
- 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x18, 0x20,
650
- };
651
-
652
- static const uint8_t PRK_out[] = {
653
- 0xb7, 0x44, 0xcb, 0x7d, 0x8a, 0x87, 0xcc, 0x04, 0x47, 0xc3, 0x35,
654
- 0x0e, 0x16, 0x5b, 0x25, 0x0d, 0xab, 0x12, 0xec, 0x45, 0x33, 0x25,
655
- 0xab, 0xb9, 0x22, 0xb3, 0x03, 0x07, 0xe5, 0xc3, 0x68, 0xf0,
656
- };
657
-
658
- static const uint8_t PRK_exporter_info[] = {
659
- 0x0a,
660
- 0x40,
661
- 0x18,
662
- 0x20,
663
- };
664
-
665
- static const uint8_t PRK_exporter[] = {
666
- 0x2a, 0xae, 0xc8, 0xfc, 0x4a, 0xb3, 0xbc, 0x32, 0x95, 0xde, 0xf6,
667
- 0xb5, 0x51, 0x05, 0x1a, 0x2f, 0xa5, 0x61, 0x42, 0x4d, 0xb3, 0x01,
668
- 0xfa, 0x84, 0xf6, 0x42, 0xf5, 0x57, 0x8a, 0x6d, 0xf5, 0x1a,
669
- };
670
-
671
- /**
672
- * \brief OSCORE security session.
673
- */
674
-
675
- static const uint8_t OSCORE_Master_Secret_info[] = {
676
- 0x00,
677
- 0x40,
678
- 0x10,
679
- };
680
-
681
- static const uint8_t OSCORE_Master_Secret[] = {
682
- 0x1e, 0x1c, 0x6b, 0xea, 0xc3, 0xa8, 0xa1, 0xca,
683
- 0xc4, 0x35, 0xde, 0x7e, 0x2f, 0x9a, 0xe7, 0xff,
684
- };
685
-
686
- static const uint8_t OSCORE_Master_Salt_info[] = {
687
- 0x01,
688
- 0x40,
689
- 0x08,
690
- };
691
-
692
- static const uint8_t OSCORE_Master_Salt[] = {
693
- 0xce, 0x7a, 0xb8, 0x44, 0xc0, 0x10, 0x6d, 0x73,
694
- };
695
-
696
- /**
697
- * \brief OSCORE security session after EDHOC key update.
698
- */
699
-
700
- static const uint8_t keyUpdate_context[] = {
701
- 0xd6, 0xbe, 0x16, 0x96, 0x02, 0xb8, 0xbc, 0xea,
702
- 0xa0, 0x11, 0x58, 0xfd, 0xb8, 0x20, 0x89, 0x0c,
703
- };
704
-
705
- static const uint8_t keyUpdate_PRK_out[] = {
706
- 0xda, 0x6e, 0xac, 0xd9, 0xa9, 0x85, 0xf4, 0xfb, 0xa9, 0xae, 0xc2,
707
- 0xa9, 0x29, 0x90, 0x22, 0x97, 0x6b, 0x25, 0xb1, 0x4e, 0x89, 0xfa,
708
- 0x15, 0x97, 0x94, 0xf2, 0x8d, 0x82, 0xfa, 0xf2, 0xda, 0xad,
709
- };
710
-
711
- static const uint8_t keyUpdate_PRK_exporter[] = {
712
- 0x00, 0x14, 0xd2, 0x52, 0x5e, 0xe0, 0xd8, 0xe2, 0x13, 0xea, 0x59,
713
- 0x08, 0x02, 0x8e, 0x9a, 0x1c, 0xe9, 0xa0, 0x1c, 0x30, 0x54, 0x6f,
714
- 0x09, 0x30, 0xc0, 0x44, 0xd3, 0x8d, 0xb5, 0x36, 0x2c, 0x05,
715
- };
716
-
717
- static const uint8_t keyUpdate_OSCORE_Master_Secret[] = {
718
- 0xee, 0x0f, 0xf5, 0x42, 0xc4, 0x7e, 0xb0, 0xe0,
719
- 0x9c, 0x69, 0x30, 0x76, 0x49, 0xbd, 0xbb, 0xe5,
720
- };
721
-
722
- static const uint8_t keyUpdate_OSCORE_Master_Salt[] = {
723
- 0x80, 0xce, 0xde, 0x2a, 0x1e, 0x5a, 0xab, 0x48,
724
- };
725
-
726
- /**
727
- * \brief Root X.509 public key.
728
- */
729
- static const uint8_t PK_CA[] = {
730
- 0x2b, 0x7b, 0x3e, 0x80, 0x57, 0xc8, 0x64, 0x29, 0x44, 0xd0, 0x6a,
731
- 0xfe, 0x7a, 0x71, 0xd1, 0xc9, 0xbf, 0x96, 0x1b, 0x62, 0x92, 0xba,
732
- 0xc4, 0xb0, 0x4f, 0x91, 0x66, 0x9b, 0xbb, 0x71, 0x3b, 0xe4,
733
- };
734
-
735
- /* Extern variables and constant declarations ------------------------------ */
736
- /* Module interface function declarations ---------------------------------- */
737
-
738
- #endif /* TEST_VECTOR_1_H */
1
+ /**
2
+ * \file test_vector_rfc9529_chapter_2.h
3
+ * \author Kamil Kielbasa
4
+ * \brief Test vector from EDHOC traces (RFC 9529) for chapter 2.
5
+ * It contains authentication with signatures, X.509 identified by 'x5t'.
6
+ *
7
+ * \version 0.6
8
+ * \date 2024-08-05
9
+ *
10
+ * \copyright Copyright (c) 2024
11
+ *
12
+ */
13
+
14
+ /* Header guard ------------------------------------------------------------ */
15
+ #ifndef TEST_VECTOR_RFC9529_CHAPTER_2_H
16
+ #define TEST_VECTOR_RFC9529_CHAPTER_2_H
17
+
18
+ /* Include files ----------------------------------------------------------- */
19
+ #include <stdint.h>
20
+
21
+ /* Defines ----------------------------------------------------------------- */
22
+ /* Types and type definitions ---------------------------------------------- */
23
+ /* Module interface variables and constants -------------------------------- */
24
+
25
+ /**
26
+ * \brief EDHOC message 1.
27
+ */
28
+
29
+ static const uint8_t METHOD = 0;
30
+
31
+ static const int32_t SUITES_I[] = { 0 };
32
+
33
+ static const uint8_t X[] = {
34
+ 0x89, 0x2e, 0xc2, 0x8e, 0x5c, 0xb6, 0x66, 0x91, 0x08, 0x47, 0x05,
35
+ 0x39, 0x50, 0x0b, 0x70, 0x5e, 0x60, 0xd0, 0x08, 0xd3, 0x47, 0xc5,
36
+ 0x81, 0x7e, 0xe9, 0xf3, 0x32, 0x7c, 0x8a, 0x87, 0xbb, 0x03,
37
+ };
38
+
39
+ static const uint8_t G_X[] = {
40
+ 0x31, 0xf8, 0x2c, 0x7b, 0x5b, 0x9c, 0xbb, 0xf0, 0xf1, 0x94, 0xd9,
41
+ 0x13, 0xcc, 0x12, 0xef, 0x15, 0x32, 0xd3, 0x28, 0xef, 0x32, 0x63,
42
+ 0x2a, 0x48, 0x81, 0xa1, 0xc0, 0x70, 0x1e, 0x23, 0x7f, 0x04,
43
+ };
44
+
45
+ static const uint8_t C_I[] = { -14 };
46
+
47
+ static const uint8_t message_1[] = {
48
+ 0x00, 0x00, 0x58, 0x20, 0x31, 0xf8, 0x2c, 0x7b, 0x5b, 0x9c,
49
+ 0xbb, 0xf0, 0xf1, 0x94, 0xd9, 0x13, 0xcc, 0x12, 0xef, 0x15,
50
+ 0x32, 0xd3, 0x28, 0xef, 0x32, 0x63, 0x2a, 0x48, 0x81, 0xa1,
51
+ 0xc0, 0x70, 0x1e, 0x23, 0x7f, 0x04, 0x2d,
52
+ };
53
+
54
+ /**
55
+ * \brief EDHOC message 2.
56
+ */
57
+
58
+ static const uint8_t SUITES_R[] = { 0 };
59
+
60
+ static const uint8_t Y[] = {
61
+ 0xe6, 0x9c, 0x23, 0xfb, 0xf8, 0x1b, 0xc4, 0x35, 0x94, 0x24, 0x46,
62
+ 0x83, 0x7f, 0xe8, 0x27, 0xbf, 0x20, 0x6c, 0x8f, 0xa1, 0x0a, 0x39,
63
+ 0xdb, 0x47, 0x44, 0x9e, 0x5a, 0x81, 0x34, 0x21, 0xe1, 0xe8,
64
+ };
65
+
66
+ static const uint8_t G_Y[] = {
67
+ 0xdc, 0x88, 0xd2, 0xd5, 0x1d, 0xa5, 0xed, 0x67, 0xfc, 0x46, 0x16,
68
+ 0x35, 0x6b, 0xc8, 0xca, 0x74, 0xef, 0x9e, 0xbe, 0x8b, 0x38, 0x7e,
69
+ 0x62, 0x3a, 0x36, 0x0b, 0xa4, 0x80, 0xb9, 0xb2, 0x9d, 0x1c,
70
+ };
71
+
72
+ static const uint8_t C_R[] = { 24 };
73
+
74
+ static const uint8_t H_message_1[] = {
75
+ 0xc1, 0x65, 0xd6, 0xa9, 0x9d, 0x1b, 0xca, 0xfa, 0xac, 0x8d, 0xbf,
76
+ 0x2b, 0x35, 0x2a, 0x6f, 0x7d, 0x71, 0xa3, 0x0b, 0x43, 0x9c, 0x9d,
77
+ 0x64, 0xd3, 0x49, 0xa2, 0x38, 0x48, 0x03, 0x8e, 0xd1, 0x6b,
78
+ };
79
+
80
+ static const uint8_t TH_2[] = {
81
+ 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2,
82
+ 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79,
83
+ 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d,
84
+ };
85
+
86
+ static const uint8_t G_XY[] = {
87
+ 0xe5, 0xcd, 0xf3, 0xa9, 0x86, 0xcd, 0xac, 0x5b, 0x7b, 0xf0, 0x46,
88
+ 0x91, 0xe2, 0xb0, 0x7c, 0x08, 0xe7, 0x1f, 0x53, 0x99, 0x8d, 0x8f,
89
+ 0x84, 0x2b, 0x7c, 0x3f, 0xb4, 0xd8, 0x39, 0xcf, 0x7b, 0x28,
90
+ };
91
+
92
+ static const uint8_t PRK_2e[] = {
93
+ 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
94
+ 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
95
+ 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
96
+ };
97
+
98
+ static const uint8_t SK_R[] = {
99
+ 0xef, 0x14, 0x0f, 0xf9, 0x00, 0xb0, 0xab, 0x03, 0xf0, 0xc0, 0x8d,
100
+ 0x87, 0x9c, 0xbb, 0xd4, 0xb3, 0x1e, 0xa7, 0x1e, 0x6e, 0x7e, 0xe7,
101
+ 0xff, 0xcb, 0x7e, 0x79, 0x55, 0x77, 0x7a, 0x33, 0x27, 0x99,
102
+
103
+ 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
104
+ 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6,
105
+ 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59,
106
+ };
107
+
108
+ static const uint8_t PK_R[] = {
109
+ 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
110
+ 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6,
111
+ 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59,
112
+ };
113
+
114
+ static const uint8_t PRK_3e2m[] = {
115
+ 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
116
+ 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
117
+ 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
118
+ };
119
+
120
+ static const uint8_t ID_CRED_R_cborised[] = {
121
+ 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79,
122
+ 0xf2, 0xa4, 0x1b, 0x51, 0x0c, 0x1f, 0x9b,
123
+ };
124
+
125
+ static const uint8_t CRED_R[] = {
126
+ 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02,
127
+ 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
128
+ 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c,
129
+ 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20,
130
+ 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32,
131
+ 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a,
132
+ 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30,
133
+ 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55,
134
+ 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65,
135
+ 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35,
136
+ 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
137
+ 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1,
138
+ 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2,
139
+ 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30,
140
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc,
141
+ 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc,
142
+ 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec,
143
+ 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6,
144
+ 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65,
145
+ 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb,
146
+ 0x02,
147
+ };
148
+
149
+ static const uint8_t CRED_R_cborised[] = {
150
+ 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01,
151
+ 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b,
152
+ 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04,
153
+ 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f,
154
+ 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17,
155
+ 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x33,
156
+ 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33,
157
+ 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06,
158
+ 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20,
159
+ 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x45, 0x64,
160
+ 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b,
161
+ 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85,
162
+ 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a,
163
+ 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93,
164
+ 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7,
165
+ 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde,
166
+ 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47,
167
+ 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8,
168
+ 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94,
169
+ 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1,
170
+ 0x52, 0xcb, 0x02,
171
+ };
172
+
173
+ static const uint8_t context_2[] = {
174
+ 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b,
175
+ 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56,
176
+ 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f,
177
+ 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61,
178
+ 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03,
179
+ 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06,
180
+ 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03,
181
+ 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52,
182
+ 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
183
+ 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32,
184
+ 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31,
185
+ 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30,
186
+ 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f,
187
+ 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20,
188
+ 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06,
189
+ 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51,
190
+ 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac,
191
+ 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9,
192
+ 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41,
193
+ 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c,
194
+ 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0,
195
+ 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc,
196
+ 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a,
197
+ 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab,
198
+ 0x82, 0xc1, 0x52, 0xcb, 0x02,
199
+ };
200
+
201
+ static const uint8_t MAC_2_info_cborised[] = {
202
+ 0x02, 0x59, 0x01, 0x25, 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48,
203
+ 0x79, 0xf2, 0xa4, 0x1b, 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x20, 0xc6, 0x40,
204
+ 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50,
205
+ 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca,
206
+ 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30,
207
+ 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e,
208
+ 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b,
209
+ 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48,
210
+ 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35,
211
+ 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31,
212
+ 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39,
213
+ 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30,
214
+ 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17,
215
+ 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
216
+ 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
217
+ 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1,
218
+ 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35,
219
+ 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b,
220
+ 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b,
221
+ 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92,
222
+ 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e,
223
+ 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37,
224
+ 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10,
225
+ 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51,
226
+ 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02, 0x18, 0x20,
227
+ };
228
+
229
+ static const uint8_t MAC_2[] = {
230
+ 0x86, 0x2a, 0x7e, 0x5e, 0xf1, 0x47, 0xf9, 0xa5, 0xf4, 0xc5, 0x12,
231
+ 0xe1, 0xb6, 0x62, 0x3c, 0xd6, 0x6c, 0xd1, 0x7a, 0x72, 0x72, 0x07,
232
+ 0x2b, 0xfe, 0x5b, 0x60, 0x2f, 0xfe, 0x30, 0x7e, 0xe0, 0xe9,
233
+ };
234
+
235
+ static const uint8_t Signature_or_MAC_2_input[] = {
236
+ 0x84, 0x6a, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x31,
237
+ 0x4e, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b, 0x51,
238
+ 0x0c, 0x1f, 0x9b, 0x59, 0x01, 0x15, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15,
239
+ 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54,
240
+ 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c,
241
+ 0x90, 0x61, 0x68, 0x8d, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
242
+ 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xc4, 0x30,
243
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
244
+ 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
245
+ 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
246
+ 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
247
+ 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
248
+ 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
249
+ 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
250
+ 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x65,
251
+ 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
252
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xa1, 0xdb, 0x47,
253
+ 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c, 0x1a, 0x35, 0x4e, 0x41,
254
+ 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62, 0xc0, 0x0b, 0x3a, 0xc5,
255
+ 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
256
+ 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea, 0xb0, 0x92, 0x8e, 0x8b,
257
+ 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23, 0xd4, 0x6e, 0x7d, 0x69,
258
+ 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1, 0x45, 0x37, 0xa1, 0xaf,
259
+ 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30, 0x44, 0x10, 0x18, 0x37,
260
+ 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d, 0xce, 0x51, 0xcf, 0xae,
261
+ 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02, 0x58, 0x20, 0x86, 0x2a, 0x7e,
262
+ 0x5e, 0xf1, 0x47, 0xf9, 0xa5, 0xf4, 0xc5, 0x12, 0xe1, 0xb6, 0x62, 0x3c,
263
+ 0xd6, 0x6c, 0xd1, 0x7a, 0x72, 0x72, 0x07, 0x2b, 0xfe, 0x5b, 0x60, 0x2f,
264
+ 0xfe, 0x30, 0x7e, 0xe0, 0xe9,
265
+ };
266
+
267
+ static const uint8_t Signature_or_MAC_2[] = {
268
+ 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4, 0x4a, 0x08, 0x5c, 0x03, 0xd3,
269
+ 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5, 0x72, 0xa1, 0x96, 0x8c,
270
+ 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81, 0x60, 0x8d, 0x3d,
271
+ 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d, 0x89, 0xac,
272
+ 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9, 0x98,
273
+ 0x70, 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09,
274
+ };
275
+
276
+ static const uint8_t PLAINTEXT_2[] = {
277
+ 0x41, 0x18, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b,
278
+ 0x51, 0x0c, 0x1f, 0x9b, 0x58, 0x40, 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4,
279
+ 0x4a, 0x08, 0x5c, 0x03, 0xd3, 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5,
280
+ 0x72, 0xa1, 0x96, 0x8c, 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81,
281
+ 0x60, 0x8d, 0x3d, 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d,
282
+ 0x89, 0xac, 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9,
283
+ 0x98, 0x70, 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09,
284
+ };
285
+
286
+ static const uint8_t KEYSTREAM_2_info[] = {
287
+ 0x00, 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74,
288
+ 0x66, 0xab, 0x1d, 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e,
289
+ 0x9f, 0x14, 0xbd, 0x3a, 0x79, 0x6a, 0x06, 0x52, 0xca, 0xe6,
290
+ 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x18, 0x52,
291
+ };
292
+
293
+ static const uint8_t KEYSTERAM_2[] = {
294
+ 0xfd, 0x3e, 0x7c, 0x3f, 0x2d, 0x6b, 0xee, 0x64, 0x3d, 0x3c, 0x9d, 0x2f,
295
+ 0x28, 0x47, 0x03, 0x5d, 0x73, 0xe2, 0xec, 0xb0, 0xf8, 0xdb, 0x5c, 0xd1,
296
+ 0xc6, 0x85, 0x4e, 0x24, 0x89, 0x6a, 0xf2, 0x11, 0x88, 0xb2, 0xc4, 0x34,
297
+ 0x4e, 0x68, 0x9e, 0xc2, 0x98, 0x42, 0x83, 0xd9, 0xfb, 0xc6, 0x9c, 0xe1,
298
+ 0xc5, 0xdb, 0x10, 0xdc, 0xff, 0xf2, 0x4d, 0xf9, 0xa4, 0x9a, 0x04, 0xa9,
299
+ 0x40, 0x58, 0x27, 0x7b, 0xc7, 0xfa, 0x9a, 0xd6, 0xc6, 0xb1, 0x94, 0xab,
300
+ 0x32, 0x8b, 0x44, 0x5e, 0xb0, 0x80, 0x49, 0x0c, 0xd7, 0x86,
301
+ };
302
+
303
+ static const uint8_t CIPHERTEXT_2[] = {
304
+ 0xbc, 0x26, 0xdd, 0x27, 0x0f, 0xe9, 0xc0, 0x2c, 0x44, 0xce, 0x39, 0x34,
305
+ 0x79, 0x4b, 0x1c, 0xc6, 0x2b, 0xa2, 0x2f, 0x05, 0x45, 0x9f, 0x8d, 0x35,
306
+ 0x8c, 0x8d, 0x12, 0x27, 0x5a, 0xc4, 0x2c, 0x5f, 0x96, 0xde, 0xd5, 0xf1,
307
+ 0x3c, 0xc9, 0x08, 0x4e, 0x5b, 0x20, 0x18, 0x89, 0xa4, 0x5e, 0x5a, 0x60,
308
+ 0xa5, 0x56, 0x2d, 0xc1, 0x18, 0x61, 0x9c, 0x3d, 0xaa, 0x2f, 0xd9, 0xf4,
309
+ 0xc9, 0xf4, 0xd6, 0xed, 0xad, 0x10, 0x9d, 0xd4, 0xed, 0xf9, 0x59, 0x62,
310
+ 0xaa, 0xfb, 0xaf, 0x9a, 0xb3, 0xf4, 0xa1, 0xf6, 0xb9, 0x8f,
311
+ };
312
+
313
+ static const uint8_t message_2[] = {
314
+ 0x58, 0x72, 0xdc, 0x88, 0xd2, 0xd5, 0x1d, 0xa5, 0xed, 0x67, 0xfc, 0x46,
315
+ 0x16, 0x35, 0x6b, 0xc8, 0xca, 0x74, 0xef, 0x9e, 0xbe, 0x8b, 0x38, 0x7e,
316
+ 0x62, 0x3a, 0x36, 0x0b, 0xa4, 0x80, 0xb9, 0xb2, 0x9d, 0x1c, 0xbc, 0x26,
317
+ 0xdd, 0x27, 0x0f, 0xe9, 0xc0, 0x2c, 0x44, 0xce, 0x39, 0x34, 0x79, 0x4b,
318
+ 0x1c, 0xc6, 0x2b, 0xa2, 0x2f, 0x05, 0x45, 0x9f, 0x8d, 0x35, 0x8c, 0x8d,
319
+ 0x12, 0x27, 0x5a, 0xc4, 0x2c, 0x5f, 0x96, 0xde, 0xd5, 0xf1, 0x3c, 0xc9,
320
+ 0x08, 0x4e, 0x5b, 0x20, 0x18, 0x89, 0xa4, 0x5e, 0x5a, 0x60, 0xa5, 0x56,
321
+ 0x2d, 0xc1, 0x18, 0x61, 0x9c, 0x3d, 0xaa, 0x2f, 0xd9, 0xf4, 0xc9, 0xf4,
322
+ 0xd6, 0xed, 0xad, 0x10, 0x9d, 0xd4, 0xed, 0xf9, 0x59, 0x62, 0xaa, 0xfb,
323
+ 0xaf, 0x9a, 0xb3, 0xf4, 0xa1, 0xf6, 0xb9, 0x8f,
324
+ };
325
+
326
+ /**
327
+ * \brief EDHOC message 3.
328
+ */
329
+
330
+ static const uint8_t SK_I[] = {
331
+ 0x4c, 0x5b, 0x25, 0x87, 0x8f, 0x50, 0x7c, 0x6b, 0x9d, 0xae, 0x68,
332
+ 0xfb, 0xd4, 0xfd, 0x3f, 0xf9, 0x97, 0x53, 0x3d, 0xb0, 0xaf, 0x00,
333
+ 0xb2, 0x5d, 0x32, 0x4e, 0xa2, 0x8e, 0x6c, 0x21, 0x3b, 0xc8,
334
+
335
+ 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45,
336
+ 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e,
337
+ 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e,
338
+ };
339
+
340
+ static const uint8_t PK_I[] = {
341
+ 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45,
342
+ 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e,
343
+ 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e,
344
+ };
345
+
346
+ static const uint8_t TH_3_input[] = {
347
+ 0x58, 0x20, 0xc6, 0x40, 0x5c, 0x15, 0x4c, 0x56, 0x74, 0x66, 0xab, 0x1d,
348
+ 0xf2, 0x03, 0x69, 0x50, 0x0e, 0x54, 0x0e, 0x9f, 0x14, 0xbd, 0x3a, 0x79,
349
+ 0x6a, 0x06, 0x52, 0xca, 0xe6, 0x6c, 0x90, 0x61, 0x68, 0x8d, 0x41, 0x18,
350
+ 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0x79, 0xf2, 0xa4, 0x1b, 0x51, 0x0c,
351
+ 0x1f, 0x9b, 0x58, 0x40, 0xc3, 0xb5, 0xbd, 0x44, 0xd1, 0xe4, 0x4a, 0x08,
352
+ 0x5c, 0x03, 0xd3, 0xae, 0xde, 0x4e, 0x1e, 0x6c, 0x11, 0xc5, 0x72, 0xa1,
353
+ 0x96, 0x8c, 0xc3, 0x62, 0x9b, 0x50, 0x5f, 0x98, 0xc6, 0x81, 0x60, 0x8d,
354
+ 0x3d, 0x1d, 0xe7, 0x93, 0xd1, 0xc4, 0x0e, 0xb5, 0xdd, 0x5d, 0x89, 0xac,
355
+ 0xf1, 0x96, 0x6a, 0xea, 0x07, 0x02, 0x2b, 0x48, 0xcd, 0xc9, 0x98, 0x70,
356
+ 0xeb, 0xc4, 0x03, 0x74, 0xe8, 0xfa, 0x6e, 0x09, 0x58, 0xf1, 0x30, 0x81,
357
+ 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62,
358
+ 0x31, 0x9e, 0xc4, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d,
359
+ 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45,
360
+ 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64,
361
+ 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30,
362
+ 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x33, 0x36, 0x5a, 0x17, 0x0d,
363
+ 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30,
364
+ 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03,
365
+ 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x65, 0x73, 0x70,
366
+ 0x6f, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
367
+ 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21,
368
+ 0x00, 0xa1, 0xdb, 0x47, 0xb9, 0x51, 0x84, 0x85, 0x4a, 0xd1, 0x2a, 0x0c,
369
+ 0x1a, 0x35, 0x4e, 0x41, 0x8a, 0xac, 0xe3, 0x3a, 0xa0, 0xf2, 0xc6, 0x62,
370
+ 0xc0, 0x0b, 0x3a, 0xc5, 0x5d, 0xe9, 0x2f, 0x93, 0x59, 0x30, 0x05, 0x06,
371
+ 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0xb7, 0x23, 0xbc, 0x01, 0xea,
372
+ 0xb0, 0x92, 0x8e, 0x8b, 0x2b, 0x6c, 0x98, 0xde, 0x19, 0xcc, 0x38, 0x23,
373
+ 0xd4, 0x6e, 0x7d, 0x69, 0x87, 0xb0, 0x32, 0x47, 0x8f, 0xec, 0xfa, 0xf1,
374
+ 0x45, 0x37, 0xa1, 0xaf, 0x14, 0xcc, 0x8b, 0xe8, 0x29, 0xc6, 0xb7, 0x30,
375
+ 0x44, 0x10, 0x18, 0x37, 0xeb, 0x4a, 0xbc, 0x94, 0x95, 0x65, 0xd8, 0x6d,
376
+ 0xce, 0x51, 0xcf, 0xae, 0x52, 0xab, 0x82, 0xc1, 0x52, 0xcb, 0x02,
377
+ };
378
+
379
+ static const uint8_t TH_3[] = {
380
+ 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e,
381
+ 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6,
382
+ 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
383
+ };
384
+
385
+ static const uint8_t PRK_4e3m[] = {
386
+ 0xd5, 0x84, 0xac, 0x2e, 0x5d, 0xad, 0x5a, 0x77, 0xd1, 0x4b, 0x53,
387
+ 0xeb, 0xe7, 0x2e, 0xf1, 0xd5, 0xda, 0xa8, 0x86, 0x0d, 0x39, 0x93,
388
+ 0x73, 0xbf, 0x2c, 0x24, 0x0a, 0xfa, 0x7b, 0xa8, 0x04, 0xda,
389
+ };
390
+
391
+ static const uint8_t ID_CRED_I_cborised[] = {
392
+ 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2,
393
+ 0x4a, 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f,
394
+ };
395
+
396
+ static const uint8_t CRED_I[] = {
397
+ 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02,
398
+ 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
399
+ 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c,
400
+ 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20,
401
+ 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32,
402
+ 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a,
403
+ 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30,
404
+ 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55,
405
+ 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e,
406
+ 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35,
407
+ 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
408
+ 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f,
409
+ 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4,
410
+ 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30,
411
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0x52, 0x12, 0x41,
412
+ 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7,
413
+ 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92,
414
+ 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb,
415
+ 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff,
416
+ 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43,
417
+ 0x0b,
418
+ };
419
+
420
+ static const uint8_t CRED_I_cborised[] = {
421
+ 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01,
422
+ 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b,
423
+ 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04,
424
+ 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f,
425
+ 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17,
426
+ 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x30,
427
+ 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33,
428
+ 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06,
429
+ 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20,
430
+ 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64,
431
+ 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b,
432
+ 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29,
433
+ 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3,
434
+ 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14,
435
+ 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0x52,
436
+ 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea,
437
+ 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10,
438
+ 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d,
439
+ 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05,
440
+ 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0,
441
+ 0x0b, 0x43, 0x0b,
442
+ };
443
+
444
+ static const uint8_t context_3[] = {
445
+ 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43,
446
+ 0xc7, 0x9f, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c,
447
+ 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca,
448
+ 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
449
+ 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01,
450
+ 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b,
451
+ 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19, 0x06, 0x03, 0x55, 0x04,
452
+ 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f,
453
+ 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17,
454
+ 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30, 0x38, 0x32, 0x34, 0x30,
455
+ 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32, 0x33, 0x31, 0x32, 0x33,
456
+ 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06,
457
+ 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20,
458
+ 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64,
459
+ 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b,
460
+ 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29,
461
+ 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3,
462
+ 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14,
463
+ 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x41, 0x00, 0x52,
464
+ 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea,
465
+ 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10,
466
+ 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d,
467
+ 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05,
468
+ 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0,
469
+ 0x0b, 0x43, 0x0b,
470
+ };
471
+
472
+ static const uint8_t MAC_3_info[] = {
473
+ 0x06, 0x59, 0x01, 0x23, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a,
474
+ 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4,
475
+ 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff,
476
+ 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65,
477
+ 0x92, 0xe9, 0x28, 0xbc, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
478
+ 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30,
479
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
480
+ 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
481
+ 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
482
+ 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
483
+ 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
484
+ 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
485
+ 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
486
+ 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f,
487
+ 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
488
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8,
489
+ 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f,
490
+ 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20,
491
+ 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
492
+ 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b,
493
+ 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a,
494
+ 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01,
495
+ 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21,
496
+ 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa,
497
+ 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b, 0x18, 0x20,
498
+ };
499
+
500
+ static const uint8_t MAC_3[] = {
501
+ 0x39, 0xb1, 0x27, 0xc1, 0x30, 0x12, 0x9a, 0xfa, 0x30, 0x61, 0x8c,
502
+ 0x75, 0x13, 0x29, 0xe6, 0x37, 0xcc, 0x37, 0x34, 0x27, 0x0d, 0x4b,
503
+ 0x01, 0x25, 0x84, 0x45, 0xa8, 0xee, 0x02, 0xda, 0xa3, 0xbd,
504
+ };
505
+
506
+ static const uint8_t Signature_or_MAC_3_input[] = {
507
+ 0x84, 0x6a, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x31,
508
+ 0x4e, 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76,
509
+ 0x43, 0xc7, 0x9f, 0x59, 0x01, 0x15, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4,
510
+ 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff,
511
+ 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65,
512
+ 0x92, 0xe9, 0x28, 0xbc, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30, 0x81, 0xa1,
513
+ 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e, 0xa0, 0x30,
514
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b, 0x30, 0x19,
515
+ 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48, 0x4f, 0x43,
516
+ 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31,
517
+ 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31, 0x36, 0x30,
518
+ 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39, 0x31, 0x32,
519
+ 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30, 0x22, 0x31,
520
+ 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17, 0x45, 0x44,
521
+ 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f,
522
+ 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30, 0x2a, 0x30,
523
+ 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed, 0x06, 0xa8,
524
+ 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9, 0xd0, 0x7f,
525
+ 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8, 0xcc, 0x20,
526
+ 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70,
527
+ 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70, 0x99, 0x6b,
528
+ 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb, 0x35, 0x3a,
529
+ 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7, 0x56, 0x01,
530
+ 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f, 0x67, 0x21,
531
+ 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8, 0x13, 0xfa,
532
+ 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b, 0x58, 0x20, 0x39, 0xb1, 0x27,
533
+ 0xc1, 0x30, 0x12, 0x9a, 0xfa, 0x30, 0x61, 0x8c, 0x75, 0x13, 0x29, 0xe6,
534
+ 0x37, 0xcc, 0x37, 0x34, 0x27, 0x0d, 0x4b, 0x01, 0x25, 0x84, 0x45, 0xa8,
535
+ 0xee, 0x02, 0xda, 0xa3, 0xbd,
536
+ };
537
+
538
+ static const uint8_t Signature_or_MAC_3[] = {
539
+ 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1, 0xb5, 0xaf, 0x81,
540
+ 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55, 0x95, 0x7f,
541
+ 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18, 0x6a,
542
+ 0x0d, 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec,
543
+ 0xb9, 0xcf, 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca,
544
+ 0x11, 0x8c, 0xe4, 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07,
545
+ };
546
+
547
+ static const uint8_t PLAINTET_3[] = {
548
+ 0xa1, 0x18, 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43,
549
+ 0xc7, 0x9f, 0x58, 0x40, 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1,
550
+ 0xb5, 0xaf, 0x81, 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55,
551
+ 0x95, 0x7f, 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18,
552
+ 0x6a, 0x0d, 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec,
553
+ 0xb9, 0xcf, 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca, 0x11,
554
+ 0x8c, 0xe4, 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07,
555
+ };
556
+
557
+ static const uint8_t A_3[] = {
558
+ 0x83, 0x68, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x30, 0x40, 0x58,
559
+ 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41, 0x8e,
560
+ 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6, 0x69,
561
+ 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc,
562
+ };
563
+
564
+ static const uint8_t K_3_info[] = {
565
+ 0x03, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0,
566
+ 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57,
567
+ 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0x10,
568
+ };
569
+
570
+ static const uint8_t K_3[] = {
571
+ 0xda, 0x19, 0x5e, 0x5f, 0x64, 0x8a, 0xc6, 0x3b,
572
+ 0x0e, 0x8f, 0xb0, 0xc4, 0x55, 0x20, 0x51, 0x39,
573
+ };
574
+
575
+ static const uint8_t IV_3_info[] = {
576
+ 0x04, 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0,
577
+ 0x41, 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57,
578
+ 0xf6, 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0x0d,
579
+ };
580
+
581
+ static const uint8_t IV_3[] = {
582
+ 0x38, 0xd8, 0xc6, 0x4c, 0x56, 0x25, 0x5a,
583
+ 0xff, 0xa4, 0x49, 0xf4, 0xbe, 0xd7,
584
+ };
585
+
586
+ static const uint8_t CIPHERTEXT_3[] = {
587
+ 0x25, 0xc3, 0x45, 0x88, 0x4a, 0xaa, 0xeb, 0x22, 0xc5, 0x27, 0xf9,
588
+ 0xb1, 0xd2, 0xb6, 0x78, 0x72, 0x07, 0xe0, 0x16, 0x3c, 0x69, 0xb6,
589
+ 0x2a, 0x0d, 0x43, 0x92, 0x81, 0x50, 0x42, 0x72, 0x03, 0xc3, 0x16,
590
+ 0x74, 0xe4, 0x51, 0x4e, 0xa6, 0xe3, 0x83, 0xb5, 0x66, 0xeb, 0x29,
591
+ 0x76, 0x3e, 0xfe, 0xb0, 0xaf, 0xa5, 0x18, 0x77, 0x6a, 0xe1, 0xc6,
592
+ 0x5f, 0x85, 0x6d, 0x84, 0xbf, 0x32, 0xaf, 0x3a, 0x78, 0x36, 0x97,
593
+ 0x04, 0x66, 0xdc, 0xb7, 0x1f, 0x76, 0x74, 0x5d, 0x39, 0xd3, 0x02,
594
+ 0x5e, 0x77, 0x03, 0xe0, 0xc0, 0x32, 0xeb, 0xad, 0x51, 0x94, 0x7c,
595
+ };
596
+
597
+ static const uint8_t message_3[] = {
598
+ 0x58, 0x58, 0x25, 0xc3, 0x45, 0x88, 0x4a, 0xaa, 0xeb, 0x22, 0xc5, 0x27,
599
+ 0xf9, 0xb1, 0xd2, 0xb6, 0x78, 0x72, 0x07, 0xe0, 0x16, 0x3c, 0x69, 0xb6,
600
+ 0x2a, 0x0d, 0x43, 0x92, 0x81, 0x50, 0x42, 0x72, 0x03, 0xc3, 0x16, 0x74,
601
+ 0xe4, 0x51, 0x4e, 0xa6, 0xe3, 0x83, 0xb5, 0x66, 0xeb, 0x29, 0x76, 0x3e,
602
+ 0xfe, 0xb0, 0xaf, 0xa5, 0x18, 0x77, 0x6a, 0xe1, 0xc6, 0x5f, 0x85, 0x6d,
603
+ 0x84, 0xbf, 0x32, 0xaf, 0x3a, 0x78, 0x36, 0x97, 0x04, 0x66, 0xdc, 0xb7,
604
+ 0x1f, 0x76, 0x74, 0x5d, 0x39, 0xd3, 0x02, 0x5e, 0x77, 0x03, 0xe0, 0xc0,
605
+ 0x32, 0xeb, 0xad, 0x51, 0x94, 0x7c,
606
+ };
607
+
608
+ static const uint8_t TH_4_input[] = {
609
+ 0x58, 0x20, 0x5b, 0x7d, 0xf9, 0xb4, 0xf5, 0x8f, 0x24, 0x0c, 0xe0, 0x41,
610
+ 0x8e, 0x48, 0x19, 0x1b, 0x5f, 0xff, 0x3a, 0x22, 0xb5, 0xca, 0x57, 0xf6,
611
+ 0x69, 0xb1, 0x67, 0x77, 0x99, 0x65, 0x92, 0xe9, 0x28, 0xbc, 0xa1, 0x18,
612
+ 0x22, 0x82, 0x2e, 0x48, 0xc2, 0x4a, 0xb2, 0xfd, 0x76, 0x43, 0xc7, 0x9f,
613
+ 0x58, 0x40, 0x96, 0xe1, 0xcd, 0x5f, 0xce, 0xad, 0xfa, 0xc1, 0xb5, 0xaf,
614
+ 0x81, 0x94, 0x43, 0xf7, 0x09, 0x24, 0xf5, 0x71, 0x99, 0x55, 0x95, 0x7f,
615
+ 0xd0, 0x26, 0x55, 0xbe, 0xb4, 0x77, 0x5e, 0x1a, 0x73, 0x18, 0x6a, 0x0d,
616
+ 0x1d, 0x3e, 0xa6, 0x83, 0xf0, 0x8f, 0x8d, 0x03, 0xdc, 0xec, 0xb9, 0xcf,
617
+ 0x15, 0x4e, 0x1c, 0x6f, 0x55, 0x5a, 0x1e, 0x12, 0xca, 0x11, 0x8c, 0xe4,
618
+ 0x2b, 0xdb, 0xa6, 0x87, 0x89, 0x07, 0x58, 0xf1, 0x30, 0x81, 0xee, 0x30,
619
+ 0x81, 0xa1, 0xa0, 0x03, 0x02, 0x01, 0x02, 0x02, 0x04, 0x62, 0x31, 0x9e,
620
+ 0xa0, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x30, 0x1d, 0x31, 0x1b,
621
+ 0x30, 0x19, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x12, 0x45, 0x44, 0x48,
622
+ 0x4f, 0x43, 0x20, 0x52, 0x6f, 0x6f, 0x74, 0x20, 0x45, 0x64, 0x32, 0x35,
623
+ 0x35, 0x31, 0x39, 0x30, 0x1e, 0x17, 0x0d, 0x32, 0x32, 0x30, 0x33, 0x31,
624
+ 0x36, 0x30, 0x38, 0x32, 0x34, 0x30, 0x30, 0x5a, 0x17, 0x0d, 0x32, 0x39,
625
+ 0x31, 0x32, 0x33, 0x31, 0x32, 0x33, 0x30, 0x30, 0x30, 0x30, 0x5a, 0x30,
626
+ 0x22, 0x31, 0x20, 0x30, 0x1e, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 0x17,
627
+ 0x45, 0x44, 0x48, 0x4f, 0x43, 0x20, 0x49, 0x6e, 0x69, 0x74, 0x69, 0x61,
628
+ 0x74, 0x6f, 0x72, 0x20, 0x45, 0x64, 0x32, 0x35, 0x35, 0x31, 0x39, 0x30,
629
+ 0x2a, 0x30, 0x05, 0x06, 0x03, 0x2b, 0x65, 0x70, 0x03, 0x21, 0x00, 0xed,
630
+ 0x06, 0xa8, 0xae, 0x61, 0xa8, 0x29, 0xba, 0x5f, 0xa5, 0x45, 0x25, 0xc9,
631
+ 0xd0, 0x7f, 0x48, 0xdd, 0x44, 0xa3, 0x02, 0xf4, 0x3e, 0x0f, 0x23, 0xd8,
632
+ 0xcc, 0x20, 0xb7, 0x30, 0x85, 0x14, 0x1e, 0x30, 0x05, 0x06, 0x03, 0x2b,
633
+ 0x65, 0x70, 0x03, 0x41, 0x00, 0x52, 0x12, 0x41, 0xd8, 0xb3, 0xa7, 0x70,
634
+ 0x99, 0x6b, 0xcf, 0xc9, 0xb9, 0xea, 0xd4, 0xe7, 0xe0, 0xa1, 0xc0, 0xdb,
635
+ 0x35, 0x3a, 0x3b, 0xdf, 0x29, 0x10, 0xb3, 0x92, 0x75, 0xae, 0x48, 0xb7,
636
+ 0x56, 0x01, 0x59, 0x81, 0x85, 0x0d, 0x27, 0xdb, 0x67, 0x34, 0xe3, 0x7f,
637
+ 0x67, 0x21, 0x22, 0x67, 0xdd, 0x05, 0xee, 0xff, 0x27, 0xb9, 0xe7, 0xa8,
638
+ 0x13, 0xfa, 0x57, 0x4b, 0x72, 0xa0, 0x0b, 0x43, 0x0b,
639
+ };
640
+
641
+ static const uint8_t TH_4[] = {
642
+ 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc, 0xcd, 0x39,
643
+ 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe, 0x42,
644
+ 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac,
645
+ };
646
+
647
+ /**
648
+ * \brief EDHOC message 4.
649
+ */
650
+
651
+ static const uint8_t A_4[] = {
652
+ 0x83, 0x68, 0x45, 0x6e, 0x63, 0x72, 0x79, 0x70, 0x74, 0x30, 0x40, 0x58,
653
+ 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc, 0xcd, 0x39,
654
+ 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe, 0x42, 0xd5,
655
+ 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac,
656
+ };
657
+
658
+ static const uint8_t K_4_info[] = {
659
+ 0x08, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc,
660
+ 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe,
661
+ 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x10,
662
+ };
663
+
664
+ static const uint8_t K_4[] = {
665
+ 0xdf, 0x8c, 0xb5, 0x86, 0x1e, 0x1f, 0xdf, 0xed,
666
+ 0xd3, 0xb2, 0x30, 0x15, 0xa3, 0x9d, 0x1e, 0x2e,
667
+ };
668
+
669
+ static const uint8_t IV_4_info[] = {
670
+
671
+ 0x09, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35, 0x55, 0xdc,
672
+ 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37, 0x50, 0xd5, 0x99, 0xbe,
673
+ 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37, 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x0d,
674
+ };
675
+
676
+ static const uint8_t IV_4[] = {
677
+ 0x12, 0x8e, 0xc6, 0x58, 0xd9, 0x70, 0xd7,
678
+ 0x38, 0x0f, 0x74, 0xfc, 0x6c, 0x27,
679
+ };
680
+
681
+ static const uint8_t CIPHERTEXT_4[] = {
682
+ 0x4f, 0x0e, 0xde, 0xe3, 0x66, 0xe5, 0xc8, 0x83,
683
+ };
684
+
685
+ static const uint8_t message_4[] = {
686
+ 0x48, 0x4f, 0x0e, 0xde, 0xe3, 0x66, 0xe5, 0xc8, 0x83,
687
+ };
688
+
689
+ /**
690
+ * \brief PRK_out
691
+ */
692
+
693
+ static const uint8_t PRK_out_info[] = {
694
+ 0x07, 0x58, 0x20, 0x0e, 0xb8, 0x68, 0xf2, 0x63, 0xcf, 0x35,
695
+ 0x55, 0xdc, 0xcd, 0x39, 0x6d, 0xd8, 0xde, 0xc2, 0x9d, 0x37,
696
+ 0x50, 0xd5, 0x99, 0xbe, 0x42, 0xd5, 0xa4, 0x1a, 0x5a, 0x37,
697
+ 0xc8, 0x96, 0xf2, 0x94, 0xac, 0x18, 0x20,
698
+ };
699
+
700
+ static const uint8_t PRK_out[] = {
701
+ 0xb7, 0x44, 0xcb, 0x7d, 0x8a, 0x87, 0xcc, 0x04, 0x47, 0xc3, 0x35,
702
+ 0x0e, 0x16, 0x5b, 0x25, 0x0d, 0xab, 0x12, 0xec, 0x45, 0x33, 0x25,
703
+ 0xab, 0xb9, 0x22, 0xb3, 0x03, 0x07, 0xe5, 0xc3, 0x68, 0xf0,
704
+ };
705
+
706
+ static const uint8_t PRK_exporter_info[] = {
707
+ 0x0a,
708
+ 0x40,
709
+ 0x18,
710
+ 0x20,
711
+ };
712
+
713
+ static const uint8_t PRK_exporter[] = {
714
+ 0x2a, 0xae, 0xc8, 0xfc, 0x4a, 0xb3, 0xbc, 0x32, 0x95, 0xde, 0xf6,
715
+ 0xb5, 0x51, 0x05, 0x1a, 0x2f, 0xa5, 0x61, 0x42, 0x4d, 0xb3, 0x01,
716
+ 0xfa, 0x84, 0xf6, 0x42, 0xf5, 0x57, 0x8a, 0x6d, 0xf5, 0x1a,
717
+ };
718
+
719
+ /**
720
+ * \brief OSCORE security session.
721
+ */
722
+
723
+ static const uint8_t OSCORE_Master_Secret_info[] = {
724
+ 0x00,
725
+ 0x40,
726
+ 0x10,
727
+ };
728
+
729
+ static const uint8_t OSCORE_Master_Secret[] = {
730
+ 0x1e, 0x1c, 0x6b, 0xea, 0xc3, 0xa8, 0xa1, 0xca,
731
+ 0xc4, 0x35, 0xde, 0x7e, 0x2f, 0x9a, 0xe7, 0xff,
732
+ };
733
+
734
+ static const uint8_t OSCORE_Master_Salt_info[] = {
735
+ 0x01,
736
+ 0x40,
737
+ 0x08,
738
+ };
739
+
740
+ static const uint8_t OSCORE_Master_Salt[] = {
741
+ 0xce, 0x7a, 0xb8, 0x44, 0xc0, 0x10, 0x6d, 0x73,
742
+ };
743
+
744
+ /**
745
+ * \brief OSCORE security session after EDHOC key update.
746
+ */
747
+
748
+ static const uint8_t keyUpdate_context[] = {
749
+ 0xd6, 0xbe, 0x16, 0x96, 0x02, 0xb8, 0xbc, 0xea,
750
+ 0xa0, 0x11, 0x58, 0xfd, 0xb8, 0x20, 0x89, 0x0c,
751
+ };
752
+
753
+ static const uint8_t keyUpdate_PRK_out[] = {
754
+ 0xda, 0x6e, 0xac, 0xd9, 0xa9, 0x85, 0xf4, 0xfb, 0xa9, 0xae, 0xc2,
755
+ 0xa9, 0x29, 0x90, 0x22, 0x97, 0x6b, 0x25, 0xb1, 0x4e, 0x89, 0xfa,
756
+ 0x15, 0x97, 0x94, 0xf2, 0x8d, 0x82, 0xfa, 0xf2, 0xda, 0xad,
757
+ };
758
+
759
+ static const uint8_t keyUpdate_PRK_exporter[] = {
760
+ 0x00, 0x14, 0xd2, 0x52, 0x5e, 0xe0, 0xd8, 0xe2, 0x13, 0xea, 0x59,
761
+ 0x08, 0x02, 0x8e, 0x9a, 0x1c, 0xe9, 0xa0, 0x1c, 0x30, 0x54, 0x6f,
762
+ 0x09, 0x30, 0xc0, 0x44, 0xd3, 0x8d, 0xb5, 0x36, 0x2c, 0x05,
763
+ };
764
+
765
+ static const uint8_t keyUpdate_OSCORE_Master_Secret[] = {
766
+ 0xee, 0x0f, 0xf5, 0x42, 0xc4, 0x7e, 0xb0, 0xe0,
767
+ 0x9c, 0x69, 0x30, 0x76, 0x49, 0xbd, 0xbb, 0xe5,
768
+ };
769
+
770
+ static const uint8_t keyUpdate_OSCORE_Master_Salt[] = {
771
+ 0x80, 0xce, 0xde, 0x2a, 0x1e, 0x5a, 0xab, 0x48,
772
+ };
773
+
774
+ /**
775
+ * \brief Root X.509 public key.
776
+ */
777
+ static const uint8_t PK_CA[] = {
778
+ 0x2b, 0x7b, 0x3e, 0x80, 0x57, 0xc8, 0x64, 0x29, 0x44, 0xd0, 0x6a,
779
+ 0xfe, 0x7a, 0x71, 0xd1, 0xc9, 0xbf, 0x96, 0x1b, 0x62, 0x92, 0xba,
780
+ 0xc4, 0xb0, 0x4f, 0x91, 0x66, 0x9b, 0xbb, 0x71, 0x3b, 0xe4,
781
+ };
782
+
783
+ /* Extern variables and constant declarations ------------------------------ */
784
+ /* Module interface function declarations ---------------------------------- */
785
+
786
+ #endif /* TEST_VECTOR_RFC9529_CHAPTER_2_H */