[openssl] master update

tmraz at fedoraproject.org tmraz at fedoraproject.org
Wed Feb 26 16:21:33 UTC 2020


The branch master has been updated
       via  38e6c4907e3b81f05d384d2c938c55762221de63 (commit)
      from  7d72644025a109d142861a920baf6d5ada590c6e (commit)


- Log -----------------------------------------------------------------
commit 38e6c4907e3b81f05d384d2c938c55762221de63
Author: Asfak Rahman <asfak.rahman at stoneridge.com>
Date:   Fri Feb 21 09:41:29 2020 +0200

    bugfix in cmac calculation example
    
    The example never executes code inside of the while loop, as read()
    returns bigger number than 0. Thus the end result is wrong.
    
    CLA: trivial
    
    Reviewed-by: Matt Caswell <matt at openssl.org>
    Reviewed-by: Tomas Mraz <tmraz at fedoraproject.org>
    (Merged from https://github.com/openssl/openssl/pull/11143)

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

Summary of changes:
 doc/man3/EVP_MAC.pod | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/doc/man3/EVP_MAC.pod b/doc/man3/EVP_MAC.pod
index 522bda0b45..85025a20f8 100644
--- a/doc/man3/EVP_MAC.pod
+++ b/doc/man3/EVP_MAC.pod
@@ -331,7 +331,7 @@ EVP_MAC_do_all_provided() returns nothing at all.
       if (!EVP_MAC_init(ctx))
           goto err;
 
-      while ( (read_l = read(STDIN_FILENO, buf, sizeof(buf))) < 0) {
+      while ( (read_l = read(STDIN_FILENO, buf, sizeof(buf))) > 0) {
           if (!EVP_MAC_update(ctx, buf, read_l))
               goto err;
       }
@@ -361,7 +361,7 @@ look like this:
 
   $ MY_MAC=cmac MY_KEY=secret0123456789 MY_MAC_CIPHER=aes-128-cbc \
     LD_LIBRARY_PATH=. ./foo < foo.c
-  Result: ECCAAFF041B22A2299EB90A1B53B6D45
+  Result: C5C06683CD9DDEF904D754505C560A4E
 
 (in this example, that program was stored in F<foo.c> and compiled to
 F<./foo>)


More information about the openssl-commits mailing list