@@ -51,6 +51,46 @@ cc_library(
5151 ],
5252)
5353
54+ cc_library (
55+ name = "ecc256_keygen_sca" ,
56+ srcs = ["ecc256_keygen_sca.c" ],
57+ hdrs = ["ecc256_keygen_sca.h" ],
58+ deps = [
59+ "//hw/top_earlgrey/sw/autogen:top_earlgrey" ,
60+ "//sw/device/lib/base:abs_mmio" ,
61+ "//sw/device/lib/base:memory" ,
62+ "//sw/device/lib/crypto/drivers:otbn" ,
63+ "//sw/device/lib/runtime:ibex" ,
64+ "//sw/device/lib/runtime:log" ,
65+ "//sw/device/lib/testing/test_framework:ottf_main" ,
66+ "//sw/device/lib/testing/test_framework:ujson_ottf" ,
67+ "//sw/device/lib/ujson" ,
68+ "//sw/device/sca/lib:prng" ,
69+ "//sw/device/sca/lib:sca" ,
70+ "//sw/device/tests/penetrationtests/json:otbn_sca_commands" ,
71+ "//sw/otbn/crypto:p256_key_from_seed_sca" ,
72+ ],
73+ )
74+
75+ cc_library (
76+ name = "otbn_sca" ,
77+ srcs = ["otbn_sca.c" ],
78+ hdrs = ["otbn_sca.h" ],
79+ deps = [
80+ ":ecc256_keygen_sca" ,
81+ "//sw/device/lib/base:memory" ,
82+ "//sw/device/lib/base:status" ,
83+ "//sw/device/lib/crypto/impl:status" ,
84+ "//sw/device/lib/runtime:log" ,
85+ "//sw/device/lib/testing/test_framework:ujson_ottf" ,
86+ "//sw/device/lib/ujson" ,
87+ "//sw/device/sca/lib:prng" ,
88+ "//sw/device/sca/lib:sca" ,
89+ "//sw/device/tests/penetrationtests/firmware:sca_lib" ,
90+ "//sw/device/tests/penetrationtests/json:otbn_sca_commands" ,
91+ ],
92+ )
93+
5494cc_library (
5595 name = "ibex_fi" ,
5696 srcs = [
@@ -176,11 +216,17 @@ cc_library(
176216 hdrs = ["sca_lib.h" ],
177217 deps = [
178218 "//sw/device/lib/base:csr" ,
219+ "//sw/device/lib/base:mmio" ,
179220 "//sw/device/lib/dif:alert_handler" ,
221+ "//sw/device/lib/dif:csrng" ,
222+ "//sw/device/lib/dif:csrng_shared" ,
223+ "//sw/device/lib/dif:edn" ,
224+ "//sw/device/lib/dif:entropy_src" ,
180225 "//sw/device/lib/dif:rstmgr" ,
181226 "//sw/device/lib/dif:rv_core_ibex" ,
182227 "//sw/device/lib/dif:rv_plic" ,
183228 "//sw/device/lib/testing:alert_handler_testutils" ,
229+ "//sw/device/lib/testing:entropy_testutils" ,
184230 "//sw/device/lib/testing:rv_plic_testutils" ,
185231 "//sw/device/lib/testing/test_framework:ottf_main" ,
186232 "//sw/device/lib/ujson" ,
@@ -227,6 +273,7 @@ FIRMWARE_DEPS = [
227273 ":ibex_fi" ,
228274 ":ibex_sca" ,
229275 ":kmac_sca" ,
276+ ":otbn_sca" ,
230277 ":otbn_fi" ,
231278 ":prng_sca" ,
232279 ":sha3_sca" ,
0 commit comments