1. 13 Aug, 2024 1 commit
    • Peter Züger's avatar
      extmod/modtls_mbedtls: Fix DER parsing and calculation of key/cert len. · 4d6d8498
      Peter Züger authored
      `mbedtls_pk_parse_key()` expects `key_len` to include the NULL terminator
      for PEM data but not for DER encoded data.  This also applies to
      `mbedtls_x509_crt_parse()` and `cert_len`.
      
      Since all PEM data contains "-----BEGIN" this is used to check if the data
      is PEM (as per mbedtls code).
      
      This can be done for both v2 and v3 of mbedtls since the fundamental
      behaviour/expectation did not change.  What changed is that in v3 the
      PKCS#8 DER parser now checks that the passed key buffer is fully utilized
      and no bytes are remaining (all other DER formats still do not check this).
      Signed-off-by: default avatarPeter Züger <zueger.peter@icloud.com>
      4d6d8498
  2. 12 Aug, 2024 2 commits
  3. 08 Aug, 2024 8 commits
  4. 07 Aug, 2024 10 commits
  5. 02 Aug, 2024 8 commits
  6. 01 Aug, 2024 3 commits
  7. 31 Jul, 2024 3 commits
  8. 26 Jul, 2024 5 commits