Clone this repo:
  1. 2150ddb Never write to response before reading request by Howard Yang · 2 years, 5 months ago main
  2. aadc19b pinweaver: fix pw_handle_block_generate_ba_pk definition by Edward Hill · 2 years, 6 months ago
  3. 19fa7b1 pinweaver: Adjust v2 eal interfaces by Howard Yang · 2 years, 6 months ago release-R111-15329.B stabilize-15335.B
  4. 1d4c585 pinweaver/ti50: workaround to build with Clang-15 in Ti50 SDK by Vadim Sukhomlinov · 2 years, 8 months ago firmware-ti50-prepvt-15315.B release-R110-15278.B stabilize-15300.B stabilize-15301.B stabilize-15317.B
  5. fc9efb6 DIR_METADATA: Add V2 Test Plans. by Navil Perez · 2 years, 10 months ago factory-brya-15231.B firmware-nissa-15217.45.B firmware-nissa-15217.B release-R109-15236.B stabilize-15236.66.B stabilize-15245.B stabilize-15251.B

Common PinWeaver Code

This directory contains reference PinWeaver code that can be used across implementation platforms.

It consists of:

  • PinWeaver reference code:
    • pinweaver.h - PinWeaver embedded API definition
    • pinweaver.c - implementation
    • pinweaver_eal.h - API for Environment Abstraction Layer (EAL) used by PinWeaver
      • note that some types used in this API are platform-specific and are defined in eal/**/pinweaver_eal_types.h
    • pinweaver_types.h - header that is shared by PinWeaver implementation and PinWeaver clients that call it through platform-specific interface.
  • Environment Abstraction Layer (EAL) implementations - in eal/ folder
    • eal/cr50 - implementation for cr50
      • pinweaver_eal_types.h - cr50-specific EAL API types
      • pinweaver_eal.c - cr50 implementation of EAL
    • eal/tpm_storage - implementation for platforms that use TPM as PinWeaver data storage
      • pinweaver_eal_types.h - TPM-storage-specific EAL API types
      • pinweaver_eal_tpm.h - additional EAL functions required by TPM storage
      • pinweaver_eal_linux.c - implementation of non-storage EAL methods for Linux case
      • tpm_storage_stubs.c - empty implementation of storage EAL methods
      • tpm_storage.c - implementation of storage EAL methods on top of TSS
      • mini_trunks/ - mini-TSS (TPM client software stack) used by TPM storage implementation
        • created from trunks TSS used by ChromeOS reduced to the minimal required set of TPM commands and ported from C++ to C
        • relies on pinweaver_eal.h + pinweaver_eal_tpm.h EAL methods
        • TSS API is defined in tss.h + *authorization_delegate.h

A platform implementation that uses TPM storage EAL option needs to implement all EAL methods implemented in pinweaver_eal_linux.c (or use it as-is, if Linux compatible).