[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: [PATCH 3/3] bcrypt: Added BCRYPT_ALGORITHM_NAME property implementation.
From:       Hans Leidekker <hans () codeweavers ! com>
Date:       2016-01-29 8:56:18
Message-ID: 1454057778.20764.137.camel () codeweavers ! com
[Download RAW message or body]

Hi Jacek,
> --- a/dlls/bcrypt/bcrypt_main.c
> +++ b/dlls/bcrypt/bcrypt_main.c
> @@ -182,11 +182,12 @@ enum alg_id
>  
>  struct {
>      ULONG hash_length;
> +    WCHAR alg_name[16];
>  } alg_props[] = {
> -    /* ALG_ID_SHA1   */ { 20 },
> -    /* ALG_ID_SHA256 */ { 32 },
> -    /* ALG_ID_SHA384 */ { 48 },
> -    /* ALG_ID_SHA512 */ { 64 }
> +    /* ALG_ID_SHA1   */ { 20, {'S','H','A','1'} },
> +    /* ALG_ID_SHA256 */ { 32, {'S','H','A','2','5','6'} },
> +    /* ALG_ID_SHA384 */ { 48, {'S','H','A','3','8','4'} },
> +    /* ALG_ID_SHA512 */ { 64, {'S','H','A','5','1','2'} }
>  };

I would use BCRYPT_SHA1_ALGORITHM, etc here and make alg_props static const. 




[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic