The branch master has been updated
       via  f523ca66612e6712f287aa4b4ed722a5f2d4d960 (commit)
      from  914db66d2337d560b042ac710817c69b89045d52 (commit)


- Log -----------------------------------------------------------------
commit f523ca66612e6712f287aa4b4ed722a5f2d4d960
Author: Tomas Mraz <[email protected]>
Date:   Mon May 11 17:15:40 2020 +0200

    Replace misleading error message when loading PEM
    
    The error message "short header" when the end line
    of PEM data cannot be identified is misleading.
    Replace it with already existing "bad end line" error.
    
    Fixes #8815
    
    Reviewed-by: Ben Kaduk <[email protected]>
    (Merged from https://github.com/openssl/openssl/pull/11793)

-----------------------------------------------------------------------

Summary of changes:
 crypto/pem/pem_lib.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/crypto/pem/pem_lib.c b/crypto/pem/pem_lib.c
index f5ed70d6b4..40a31dec97 100644
--- a/crypto/pem/pem_lib.c
+++ b/crypto/pem/pem_lib.c
@@ -824,7 +824,7 @@ static int get_header_and_data(BIO *bp, BIO **header, BIO 
**data, char *name,
         flags_mask = ~0u;
         len = BIO_gets(bp, linebuf, LINESIZE);
         if (len <= 0) {
-            PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_SHORT_HEADER);
+            PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_BAD_END_LINE);
             goto err;
         }
 

Reply via email to