[openssl/openssl] d83a50: Fix incomplete error check on ASN1_item_i2d()

Niels Dossche noreply at github.com
Tue Feb 28 03:37:30 UTC 2023


  Branch: refs/heads/openssl-3.0
  Home:   https://github.com/openssl/openssl
  Commit: d83a5043ad49739f87f3d7dc7b12f711191610ac
      https://github.com/openssl/openssl/commit/d83a5043ad49739f87f3d7dc7b12f711191610ac
  Author: ndossche <niels.dossche at ugent.be>
  Date:   2023-02-28 (Tue, 28 Feb 2023)

  Changed paths:
    M crypto/asn1/asn_pack.c

  Log Message:
  -----------
  Fix incomplete error check on ASN1_item_i2d()

According to the documentation and my analysis tool
ASN1_item_i2d() can return a negative value on error,
but this is not checked. Fix it by changing the error check condition.

CLA: trivial

Reviewed-by: Tomas Mraz <tomas at openssl.org>
Reviewed-by: Paul Dale <pauli at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/20251)

(cherry picked from commit 5df5032ab02d7a17e07435de777d730bae190253)




More information about the openssl-commits mailing list