Functions

  • zx_status_t HexToBuf (const char * hex, uint8_t * buf, size_t max)

    Defined at line 22 of file ../../src/security/lib/fcrypto/test/utils.cc

  • zx_status_t HexToBytes (const char * hex, Bytes * out)

    Resizes |out| and sets its contents to match the given |hex| string.

    Defined at line 48 of file ../../src/security/lib/fcrypto/test/utils.cc

  • zx_status_t HexToSecret (const char * hex, Secret * out)

    Defined at line 61 of file ../../src/security/lib/fcrypto/test/utils.cc

  • zx_status_t GenerateKeyMaterial (Cipher::Algorithm cipher, Secret * key, Bytes * iv)

    Fills the given |key| and |iv| with as much random data as indicated by |Cipher::GetKeyLen| and

    |Cipher::GetIVLen| for the given |cipher|. |iv| may be null.

    Defined at line 75 of file ../../src/security/lib/fcrypto/test/utils.cc

  • zx_status_t GenerateKeyMaterial (AEAD::Algorithm aead, Secret * key, Bytes * iv)

    Fills the given |key|, |iv| with as much random data as indicated by |AEAD::GetKeyLen| and

    |AEAD::GetIVLen| for the given |aead|. |iv| may be null.

    Defined at line 95 of file ../../src/security/lib/fcrypto/test/utils.cc

  • bool AllEqual (const Bytes & bufuint8_t valzx_off_t offsize_t len)

    Returns true if and only if |len| bytes starting from |off| in |buf| match |val|.

    Defined at line 113 of file ../../src/security/lib/fcrypto/test/utils.cc