{"badge":{"color":"red","label":"Entropy: fail"},"brand_name":"Coldcard","commit_sha":"4845161a9887771960660473f2d6cecfadc5085a","construction_grade":"flawed","enrichment_notes":"host-side enricher (tester remained offline)","enrichment_status":"not_required","entropy_sources":[{"api_name":"ngu.random.bytes","confidence":"exact","file_path":"external/libngu/ngu/ngu_tests/test_random.py","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/libngu/ngu/ngu_tests/test_random.py#L11","is_cryptographic":false,"language":"python","line_end":null,"line_start":11,"notes":"Coldcard bind=yasmarang_fallback","scope":"production"},{"api_name":"ngu.random.bytes","confidence":"exact","file_path":"external/libngu/ngu/ngu_tests/test_random.py","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/libngu/ngu/ngu_tests/test_random.py#L15","is_cryptographic":false,"language":"python","line_end":null,"line_start":15,"notes":"Coldcard bind=yasmarang_fallback","scope":"production"},{"api_name":"Possible weak entropy seeding from Date / performance / timestamp","confidence":"exact","file_path":"external/micropython/ports/javascript/library.js","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/ports/javascript/library.js#L45","is_cryptographic":false,"language":null,"line_end":null,"line_start":45,"notes":"semgrep opt.ew.rules.semgrep.ew.timestamp-seeding","scope":"production"},{"api_name":"Possible weak entropy seeding from Date / performance / timestamp","confidence":"exact","file_path":"external/micropython/ports/javascript/wrapper.js","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/ports/javascript/wrapper.js#L36","is_cryptographic":false,"language":null,"line_end":null,"line_start":36,"notes":"semgrep opt.ew.rules.semgrep.ew.timestamp-seeding","scope":"production"},{"api_name":"yasmarang","confidence":"exact","file_path":"external/micropython/ports/stm32/rng.c","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/ports/stm32/rng.c","is_cryptographic":false,"language":"c","line_end":null,"line_start":null,"notes":"MicroPython software PRNG fallback","scope":"production"},{"api_name":"RNG-\u003eDR","confidence":"exact","file_path":"stm32/COLDCARD/rng.c","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/stm32/COLDCARD/rng.c","is_cryptographic":true,"language":"c","line_end":null,"line_start":null,"notes":"STM32 hardware RNG data register","scope":"production"},{"api_name":"ngu.random.bytes","confidence":"exact","file_path":"testing/test_rng.py","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/testing/test_rng.py#L27","is_cryptographic":false,"language":"python","line_end":null,"line_start":27,"notes":"Coldcard bind=yasmarang_fallback","scope":"production"}],"error_summary":null,"finished_at":"2026-08-18T16:22:34.349702Z","github_owner":"Coldcard","github_repo":"firmware","id":"29088245-d748-4a28-9a38-bb7fb8960578","layman":{"minentropy_intro":"Min-entropy asks how easy the most likely value would be to guess. Higher bits per symbol is better. This still cannot prove cryptographic strength.","statistical_intro":"These checks look at a large sample of bits we generated. A pass means we did not see an obvious pattern in that sample. That cannot prove the wallet is secure. Read the linked specifications if you want the formal test definitions and how p-values are interpreted."},"minentropy_estimates":[{"alphabet_size":256,"bits_per_symbol":7.99984634420366,"estimator":"collision","iid_track":true,"layman":{"text":"This is a simple collision-based estimate. It is not the full NIST SP 800-90B collision estimator.","title":"How often do values repeat?"},"raw":{"note":"simplified collision figure; not the full SP 800-90B collision estimator","sum_p_i_squared":0.003906666061538999},"sample_size":2097152},{"alphabet_size":256,"bits_per_symbol":7.957656620206309,"estimator":"most_common_value","iid_track":true,"layman":{"text":"If one value appears far more than the others, a guesser has an easier job. Higher bits/symbol is better.","title":"How common is the most common byte?"},"raw":{"pmax":0.0040225982666015625},"sample_size":2097152}],"omitted_files":[],"overall_verdict":"fail","packages":[{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"466d533f-81cf-4fdc-a78b-6ecebb1aabc3","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/libngu/requirements.txt","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"82ffdcb0-2819-42bc-b0fe-c7ee4c4b7600","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/code_formatting.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"07ee245a-41b5-4bbd-ab9c-def15024864c","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/code_size.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"e8fcc433-f374-4509-9c8a-649e2efdf633","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/commit_formatting.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"efe0e91f-daa7-49b7-800e-a82d1c131f58","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/docs.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"1e9210e9-d9ed-4089-be96-a50270b0dfef","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_cc3200.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"7988a35b-da91-4097-863f-467f9c61ec3d","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_esp32.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"8d2c0dd4-eee1-486f-9913-1bef0e97dc75","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_esp8266.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"1fd34537-37ed-42b2-95f9-2ee64bea4fb9","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_nrf.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"4cc7891e-e7a8-48f9-9b06-19ff980e7650","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_powerpc.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"23b5fe31-f200-4cc0-a6af-01a501dcc67a","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_qemu-arm.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"1c94a626-ba47-4f01-8dd6-12955fdef430","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_rp2.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"843058e3-d1fc-4751-83f8-0d74f687055b","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_samd.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"dcd845cd-c8f8-4117-bddb-afdab5fefbe6","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_stm32.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"0ecd28ef-1ab0-406d-8450-77641831d240","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_teensy.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"424b76db-cb88-4d64-be7d-5ecb24ba2ad5","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_unix.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"3793888f-045e-4048-89f8-927e5fab2fa9","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_windows.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"46902a25-ba8f-4312-9942-197d752b9cf6","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/external/micropython/.github/workflows/ports_zephyr.yml","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"unknown","evidence":null,"github_url":null,"has_entropy_code":false,"id":"a21d033f-7ee1-4138-a2dc-81a8192cd6d2","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"/work/src/testing/requirements.txt","package_version":null,"purl":null,"references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"github","evidence":null,"github_url":null,"has_entropy_code":false,"id":"c054b1b1-4dd5-44b7-a080-cec8fa9d3fd4","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"actions/checkout","package_version":"v2","purl":"pkg:github/actions/checkout@v2","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"github","evidence":null,"github_url":null,"has_entropy_code":false,"id":"a8c4bb29-645a-4586-b4f7-bd52d0d986d4","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"actions/setup-python","package_version":"v1","purl":"pkg:github/actions/setup-python@v1","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"github","evidence":null,"github_url":null,"has_entropy_code":false,"id":"3abe053c-653b-4f48-a3e2-e802343fdd65","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"coverallsapp/github-action","package_version":"master","purl":"pkg:github/coverallsapp/github-action@master","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":true,"id":"745a93ec-197a-4d00-bb7a-9b3f2a4be335","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"mnemonic","package_version":"0.18","purl":"pkg:pypi/mnemonic@0.18","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":false,"id":"eb43bb7f-a2ba-4b72-8425-146c08179a75","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"onetimepass","package_version":"1.0.1","purl":"pkg:pypi/onetimepass@1.0.1","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":false,"id":"32f90613-7196-424d-8a58-9dd6a0ad3afb","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"pyaes","package_version":"1.6.1","purl":"pkg:pypi/pyaes@1.6.1","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":false,"id":"54171e68-f87f-4b93-9a66-b5c64bbfe371","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"pycoin","package_version":"0.80","purl":"pkg:pypi/pycoin@0.80","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":false,"id":"d4a0f75b-4adf-427f-8420-b07e6391833c","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"wallycore","package_version":"0.8.1","purl":"pkg:pypi/wallycore@0.8.1","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"},{"advisories":[],"audit_advisory_count":0,"contributor_count":null,"ecosystem":"pypi","evidence":null,"github_url":null,"has_entropy_code":false,"id":"5b6a8155-a292-4890-8f51-70afc571e079","in_secret_callgraph":false,"is_direct":null,"license":null,"new_contributor_count":null,"new_contributors":null,"package_name":"zbar-py","package_version":"1.0.4","purl":"pkg:pypi/zbar-py@1.0.4","references":[],"registry_url":null,"repo_url":null,"socket_alert_count":null,"socket_findings":null,"socket_score":null,"socket_url":null,"source_availability":"none"}],"previous_run_id":null,"risk_flags":[],"sample_bytes":2097152,"sample_mode":"firmware_sim_trng","sample_sha256":"c4db23389d12e7bab4f34b8f32b857c7c4104b6494a52291e4a54d49c38db681","slug":"coldcard","source_availability":"full","source_quality":"weak","standard_caveats":["Statistical tests can only fail a generator; they never prove cryptographic security.","Short samples can look fine even when underlying entropy is low.","Implementation bugs (state reuse, incorrect seeding, buffer issues) frequently destroy entropy in ways pure statistical tests miss.","True confidence requires both high-quality sources and correct design/review.","When sample_mode=firmware_sim_trng, statistical scores describe a software simulation of the documented mixer, not the device hardware TRNG."],"started_at":"2026-08-18T16:21:31.75915Z","static_findings":[{"category":"weak_prng","dataflow_summary":null,"evidence":{"board_files":["external/micropython/ports/stm32/mpconfigboard_common.h","external/micropython/ports/stm32/boards/NUCLEO_WB55/mpconfigboard.h","external/micropython/ports/stm32/boards/USBDONGLE_WB55/mpconfigboard.h","external/micropython/ports/stm32/boards/PYBV10/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32F439/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F413ZH/mpconfigboard.h","external/micropython/ports/stm32/boards/HYDRABUS/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F722ZE/mpconfigboard.h","external/micropython/ports/stm32/boards/MIKROE_CLICKER2_STM32/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32F429DISC/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F767ZI/mpconfigboard.h","external/micropython/ports/stm32/boards/CERB40/mpconfigboard.h","external/micropython/ports/stm32/boards/PYBV3/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F412ZG/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32L476DISC/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_L452RE/mpconfigboard.h","external/micropython/ports/stm32/boards/ADAFRUIT_F405_EXPRESS/mpconfigboard.h","external/micropython/ports/stm32/boards/NADHAT_PYBF405/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32F7DISC/mpconfigboard.h","external/micropython/ports/stm32/boards/PYBV11/mpconfigboard.h","external/micropython/ports/stm32/boards/OLIMEX_E407/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32F4DISC/mpconfigboard.h","external/micropython/ports/stm32/boards/B_L475E_IOT01A/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32L496GDISC/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F746ZG/mpconfigboard.h","external/micropython/ports/stm32/boards/NETDUINO_PLUS_2/mpconfigboard.h","external/micropython/ports/stm32/boards/STM32F769DISC/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_F429ZI/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_L476RG/mpconfigboard.h","external/micropython/ports/stm32/boards/PYBV4/mpconfigboard.h","external/micropython/ports/stm32/boards/NUCLEO_H743ZI/mpconfigboard.h","external/micropython/ports/stm32/boards/PYBD_SF2/mpconfigboard.h","external/micropython/ports/stm32/boards/LIMIFROG/mpconfigboard.h","external/micropython/ports/nrf/boards/microbit/mpconfigboard.h","external/micropython/ports/nrf/boards/dvk_bl652/mpconfigboard.h","external/micropython/ports/nrf/boards/arduino_primo/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10059/mpconfigboard.h","external/micropython/ports/nrf/boards/particle_xenon/mpconfigboard.h","external/micropython/ports/nrf/boards/actinius_icarus/mpconfigboard.h","external/micropython/ports/nrf/boards/ibk_blyst_nano/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10000/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10056/mpconfigboard.h","external/micropython/ports/nrf/boards/feather52/mpconfigboard.h","external/micropython/ports/nrf/boards/evk_nina_b1/mpconfigboard.h","external/micropython/ports/nrf/boards/blueio_tag_evim/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10031/mpconfigboard.h","external/micropython/ports/nrf/boards/wt51822_s4at/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10028/mpconfigboard.h","external/micropython/ports/nrf/boards/nrf52840-mdk-usb-dongle/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10001/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10090/mpconfigboard.h","external/micropython/ports/nrf/boards/idk_blyst_nano/mpconfigboard.h","external/micropython/ports/nrf/boards/pca10040/mpconfigboard.h","stm32/COLDCARD/mpconfigboard.h"],"board_macro_one":false,"board_macro_zero":true,"hw_file":"stm32/COLDCARD/rng.c","hw_rng_dr":true,"libngu_error":true,"libngu_file":"external/libngu/ngu/random.c","libngu_ifndef":true,"libngu_seen":true,"libngu_value_if":false,"micropython_rng_seen":true,"seed_uses_ckcc":false,"seed_uses_ngu":true,"submodules_present":true,"yasmarang":true,"yasmarang_file":"external/micropython/ports/stm32/rng.c"},"file_path":"external/libngu/ngu/ngu_tests/test_random.py","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/libngu/ngu/ngu_tests/test_random.py#L11","line_end":null,"line_start":11,"message":"Coldcard seed generation calls ngu.random while MICROPY_HW_ENABLE_RNG is 0 and libngu tests #ifndef (defined?), so rng_get resolves to MicroPython's Yasmarang software PRNG. Construction flaw — not a measured bit count.","references":[{"date":"2006-07-19","title":"CWE-338: Use of Cryptographically Weak PRNG","url":"https://cwe.mitre.org/data/definitions/338.html"},{"date":"2026-07-30","title":"Coinkite — Technical Deep Dive into the Entropy Issue","url":"https://blog.coinkite.com/entropy-technical-backgrounder/"},{"date":"2026-07-30","title":"Block — Predictable RNG Fallback and 32-Bit Reseed in Coldcard Firmware","url":"https://engineering.block.xyz/blog/predictable-rng-fallback-and-32-bit-reseed-in-coldcard-firmware"}],"rule_id":"ew.coldcard.yasmarang-fallback","scope":"production","severity":"critical","sink_kind":"private_key","source_api":"ngu.random.bytes","symbol":null},{"category":"weak_prng","dataflow_summary":null,"evidence":null,"file_path":"external/micropython/tests/extmod/urandom_extra_float.py","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/tests/extmod/urandom_extra_float.py#L18","line_end":null,"line_start":18,"message":"random.random appears in Coldcard firmware Python at external/micropython/tests/extmod/urandom_extra_float.py:18; must not seed keys.","references":[{"date":"2024-01-01","title":"MDN Math.random is not a CSPRNG","url":"https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/random"},{"date":"2006-07-19","title":"CWE-338: Use of Cryptographically Weak PRNG","url":"https://cwe.mitre.org/data/definitions/338.html"}],"rule_id":"ew.coldcard-random-random","scope":"production","severity":"critical","sink_kind":null,"source_api":"random.random","symbol":null},{"category":"weak_entropy_source","dataflow_summary":null,"evidence":null,"file_path":"external/micropython/ports/javascript/library.js","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/ports/javascript/library.js#L45","line_end":null,"line_start":45,"message":"Possible weak entropy seeding from Date / performance / timestamp","references":[],"rule_id":"opt.ew.rules.semgrep.ew.timestamp-seeding","scope":"production","severity":"medium","sink_kind":null,"source_api":"Possible weak entropy seeding from Date / performance / timestamp","symbol":null},{"category":"weak_entropy_source","dataflow_summary":null,"evidence":null,"file_path":"external/micropython/ports/javascript/wrapper.js","github_url":"https://github.com/Coldcard/firmware/blob/4845161a9887771960660473f2d6cecfadc5085a/external/micropython/ports/javascript/wrapper.js#L36","line_end":null,"line_start":36,"message":"Possible weak entropy seeding from Date / performance / timestamp","references":[],"rule_id":"opt.ew.rules.semgrep.ew.timestamp-seeding","scope":"production","severity":"medium","sink_kind":null,"source_api":"Possible weak entropy seeding from Date / performance / timestamp","symbol":null}],"statistical_artifacts":[{"title":"Fourmilab ENT — A Pseudorandom Number Sequence Test Program","url":"https://www.fourmilab.ch/random/","date":"2008-01","note":"What entropy bits/byte, chi-square, arithmetic mean, and serial correlation mean on a byte stream."},{"title":"Dieharder — A Random Number Test Suite (Robert G. Brown)","url":"https://webhome.phy.duke.edu/~rgb/General/dieharder.php","date":"","note":"Successor to Marsaglia's Diehard. Needs a large sample; we only run it at ≥ 10 MiB."},{"title":"rngtest(1) — FIPS 140-2 RNG tests","url":"https://manpages.debian.org/bookworm/rng-tools5/rngtest.1.en.html","date":"","note":"Man page for the rng-tools FIPS battery we record as rngtest.fips_140_2."},{"title":"NIST STS source and user guide","url":"https://csrc.nist.gov/projects/random-bit-generation/documentation-and-software","date":"","note":"Software and notes that accompany SP 800-22."},{"title":"CWE-338 — Use of Cryptographically Weak Pseudo-Random Number Generator","url":"https://cwe.mitre.org/data/definitions/338.html","date":"2006-07","note":"The weakness statistical tests can hint at but cannot prove is absent."}],"statistical_references":[{"title":"NIST SP 800-22 Rev. 1a — A Statistical Test Suite for Random and Pseudorandom Number Generators","url":"https://nvlpubs.nist.gov/nistpubs/Legacy/SP/nistspecialpublication800-22r1a.pdf","date":"2010-04","note":"Official STS document. Section 4 explains p-values and what a pass does and does not mean."},{"title":"NIST SP 800-90B — Recommendation for the Entropy Sources Used for Random Bit Generation","url":"https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-90B.pdf","date":"2018-01","note":"How min-entropy of an entropy source is estimated. Our collision figure is a simplified cousin, not the full 90B estimator."},{"title":"RFC 4086 — Randomness Requirements for Security","url":"https://www.rfc-editor.org/rfc/rfc4086","date":"2005-06","note":"Why cryptographic secrets need a CSPRNG, and why statistical batteries are only a sanity check."},{"title":"FIPS 140-2 — Security Requirements for Cryptographic Modules","url":"https://csrc.nist.gov/pubs/fips/140-2/upd2/final","date":"2002-12","note":"Historical module standard. rngtest implements the old FIPS 140-2 continuous RNG health checks."}],"statistical_results":[{"battery":null,"iterations":null,"layman":{"text":"A fair mix of bits should average near 127.5. A large gap is a warning sign in the sample.","title":"Is the average byte stuck high or low?"},"p_value":null,"params":null,"raw":null,"statistic":127.5025,"suite":"ent","test_name":"arithmetic_mean","verdict":"pass"},{"battery":null,"iterations":null,"layman":{"text":"This checks whether the 256 possible byte values appear about equally often.","title":"Do some byte values show up too often?"},"p_value":null,"params":null,"raw":{"stdout":"Entropy = 7.999923 bits per byte.\n\nOptimum compression would reduce the size\nof this 2097152 byte file by 0 percent.\n\nChi square distribution for 2097152 samples is 223.37, and randomly\nwould exceed this value 92.41 percent of the times.\n\nArithmetic mean value of data bytes is 127.5025 (127.5 = random).\nMonte Carlo value for Pi is 3.138098848 (error 0.11 percent).\nSerial correlation coefficient is 0.000660 (totally uncorrelated = 0.0).\n"},"statistic":223.37,"suite":"ent","test_name":"chi_square","verdict":"pass"},{"battery":null,"iterations":null,"layman":{"text":"Near 8 bits per byte means the sample looks well mixed and hard to compress. It is not a security proof.","title":"How mixed are the bytes?"},"p_value":null,"params":null,"raw":{"stdout":"Entropy = 7.999923 bits per byte.\n\nOptimum compression would reduce the size\nof this 2097152 byte file by 0 percent.\n\nChi square distribution for 2097152 samples is 223.37, and randomly\nwould exceed this value 92.41 percent of the times.\n\nArithmetic mean value of data bytes is 127.5025 (127.5 = random).\nMonte Carlo value for Pi is 3.138098848 (error 0.11 percent).\nSerial correlation coefficient is 0.000660 (totally uncorrelated = 0.0).\n"},"statistic":7.999923,"suite":"ent","test_name":"entropy_bits_per_byte","verdict":"pass"},{"battery":null,"iterations":null,"layman":{"text":"A value near zero means neighboring bytes do not follow each other in a simple way.","title":"Does each byte predict the next one?"},"p_value":null,"params":null,"raw":null,"statistic":0.00066,"suite":"ent","test_name":"serial_correlation","verdict":"pass"},{"battery":"python-core","iterations":null,"layman":{"text":"The sample is split into chunks. A pass means those chunks are not mostly zeros or mostly ones.","title":"Are short blocks of bits lopsided?"},"p_value":0.7530806933241491,"params":null,"raw":null,"statistic":null,"suite":"nist_sp800_22","test_name":"BlockFrequency","verdict":"pass"},{"battery":"python-core","iterations":null,"layman":{"text":"This counts zeros and ones. A pass means the mix is close enough that we did not see an obvious bias.","title":"Are there too many 0s or 1s?"},"p_value":0.31925014518032724,"params":null,"raw":null,"statistic":null,"suite":"nist_sp800_22","test_name":"Frequency","verdict":"pass"},{"battery":"python-core","iterations":null,"layman":{"text":"This looks for unusually long runs of 0 or 1, which can be a sign of a stuck or simple generator.","title":"Are there long streaks of the same bit?"},"p_value":0.6221906326777771,"params":null,"raw":null,"statistic":null,"suite":"nist_sp800_22","test_name":"Runs","verdict":"pass"},{"battery":"rngtest","iterations":null,"layman":{"text":"A quick battery that fails if the stream looks stuck or badly biased. Passing it is a low bar.","title":"Old FIPS-style health checks"},"p_value":null,"params":null,"raw":{"failures":0,"successes":100,"text":"rngtest 5\nCopyright (c) 2004 by Henrique de Moraes Holschuh\nThis is free software; see the source for copying conditions.  There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\nrngtest: starting FIPS tests...\nrngtest: bits received from input: 2000032\nrngtest: FIPS 140-2 successes: 100\nrngtest: FIPS 140-2 failures: 0\nrngtest: FIPS 140-2(2001-10-10) Monobit: 0\nrngtest: FIPS 140-2(2001-10-10) Poker: 0\nrngtest: FIPS 140-2(2001-10-10) Runs: 0\nrngtest: FIPS 140-2(2001-10-10) Long run: 0\nrngtest: FIPS 140-2(2001-10-10) Continuous run: 0\nrngtest: input channel speed: (min=3.104; avg=7.421; max=18.626)Gibits/s\nrngtest: FIPS tests speed: (min=71.170; avg=105.864; max=124.663)Mibits/s\nrngtest: Program run time: 18360 microseconds\n"},"statistic":0,"suite":"rngtest","test_name":"fips_140_2","verdict":"pass"}],"status":"succeeded","test_date":"2026-08-18","tester_image_ref":"ghcr.io/409h/entropy-watch/tester:local","theoretical_notes":[{"assumptions":"Vendor estimates ~40 bits (Mk2/Mk3) and ~72 bits (Mk4/Mk5/Q with SE mix). EntropyWatch did not measure those figures.","claimed_input_bits":null,"construction":"Yasmarang PRNG (libngu → MicroPython rng_get) → BIP39","notes":"Coldcard 2021–2026 rng_get construction. Simulator output is not this stream.","side_channel_risks":"Silent bind to a software PRNG. The STM32 TRNG object may still be present in the binary.","theoretical_output_bits":null},{"assumptions":"Independent full-entropy inputs. Either party failing still leaves the other side's 256 bits.","claimed_input_bits":512,"construction":"SHA-256(device_entropy[32] || host_entropy[32]) → BIP39","notes":"Trezor mixes STM32 TRNG (or equivalent) with 256 bits from the host. Simulator output is firmware_sim_trng.","side_channel_risks":"Host entropy is visible to a compromised computer; device TRNG quality is not proven by a simulator.","theoretical_output_bits":256}],"tool_versions":{"dieharder":"/usr/bin/dieharder","ea_iid":"","ea_non_iid":"","ent":"/usr/bin/ent","node":"/usr/local/bin/node","python3":"/usr/bin/python3","rngtest":"/usr/bin/rngtest","semgrep":"/usr/local/bin/semgrep","syft":"/usr/local/bin/syft"},"verdict_reason":"Coldcard seed generation calls ngu.random while MICROPY_HW_ENABLE_RNG is 0 and libngu tests #ifndef (defined?), so rng_get resolves to MicroPython's Yasmarang software PRNG. Construction flaw — not a measured bit count. Entropy source is not cryptographic. Construction graded flawed.","verdict_references":[],"version_tag":"2026-07-31T1248-v4.2.0"}
