1. Nov 03, 2022
  2. Sep 25, 2022
  3. Aug 11, 2022
  4. Jul 22, 2022
  5. Jul 11, 2022
  6. Jul 02, 2022
  7. May 25, 2022
  8. May 23, 2022
  9. May 05, 2022
  10. Feb 08, 2022
  11. Feb 06, 2022
  12. Jan 10, 2022
    • Vitaly Chikunov's avatar
      gost_prov: OPENSSL_free what is OPENSSL_zalloc'd · da0c648b
      Vitaly Chikunov authored
      
      
        *** CID 345254:  API usage errors  (ALLOC_FREE_MISMATCH)
        /gost_prov.c: 71 in provider_ctx_new()
        65             && populate_gost_engine(ctx->e)) {
        66             ctx->core_handle = core;
        67
        68             /* Ugly hack */
        69             err_handle = ctx->proverr_handle;
        70         } else {
        >>>     CID 345254:  API usage errors  (ALLOC_FREE_MISMATCH)
        >>>     Calling "provider_ctx_free" frees "ctx" using "free" but it should have been freed using "CRYPTO_free".
        71             provider_ctx_free(ctx);
        72             ctx = NULL;
        73         }
        74         return ctx;
        75     }
      
      Fixes: f5a3951 ("gost_prov: Avoid access to unallocated memory")
      Signed-off-by: default avatarVitaly Chikunov <vt@altlinux.org>
      da0c648b
  13. Jan 09, 2022
    • Vitaly Chikunov's avatar
      gost_prov: Avoid access to unallocated memory · eea1e27c
      Vitaly Chikunov authored
      
      
      This should fix Coverity warning:
      
        *** CID 345245:    (UNINIT)
        /gost_prov.c: 71 in provider_ctx_new()
        65             && populate_gost_engine(ctx->e)) {
        66             ctx->core_handle = core;
        67
        68             /* Ugly hack */
        69             err_handle = ctx->proverr_handle;
        70         } else {
        >>>     CID 345245:    (UNINIT)
        >>>     Using uninitialized value "ctx->e" when calling "provider_ctx_free".
        71             provider_ctx_free(ctx);
        72             ctx = NULL;
        73         }
        74         return ctx;
        75     }
      
      Signed-off-by: default avatarVitaly Chikunov <vt@altlinux.org>
      Issue: #380
      eea1e27c
    • Vitaly Chikunov's avatar
      gost_ec_keyx: Check CTX data before it's really used · 5dc8f91c
      Vitaly Chikunov authored
      
      
      This should fix Coverity warning:
      
        *** CID 345243:  Null pointer dereferences  (REVERSE_INULL)
        /gost_ec_keyx.c: 681 in pkey_gost2018_decrypt()
        675        o  Q_eph is on the same curve as server public key;
        676
        677        o  Q_eph is not equal to zero point;
        678
        679        o  q * Q_eph is not equal to zero point.
        680     */
        >>>     CID 345243:  Null pointer dereferences  (REVERSE_INULL)
        >>>     Null-checking "data" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
        681         if (eph_key == NULL || priv == NULL || data == NULL) {
        682            GOSTerr(GOST_F_PKEY_GOST2018_DECRYPT,
        683                    GOST_R_ERROR_COMPUTING_EXPORT_KEYS);
        684            ret = 0;
        685            goto err;
        686         }
      
      Signed-off-by: default avatarVitaly Chikunov <vt@altlinux.org>
      Issue: #380
      5dc8f91c
  14. Jan 08, 2022
  15. Jan 07, 2022
  16. Dec 21, 2021
  17. Dec 20, 2021
  18. Dec 15, 2021
  19. Dec 12, 2021