[Touch-packages] [Bug 1810129] Re: blake2b512 / sha3-512 invalid digest type

2019-06-10 Thread Dimitri John Ledkov
(specifically published RFCs defining the relevant digest-algo /
signature types format to be used in x.509 certificates / or any pki
generically. Just the definition of the math to calculate the digest is
not enough)

** Changed in: openssl (Ubuntu)
   Status: Incomplete => Opinion

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to openssl in Ubuntu.
https://bugs.launchpad.net/bugs/1810129

Title:
  blake2b512 / sha3-512 invalid digest type

Status in openssl package in Ubuntu:
  Opinion

Bug description:
  cosmic | openssl 1.1.1-1

  Since 1.1.1.a-1 provides support for blake2b512 / sha3-512 it would be
  expected such to work when generating certificates which however does
  not.

  OpenSSL> list -digest-commands
  blake2b512 blake2s256 gost md4
  md5 mdc2 rmd160 sha1
  sha224 sha256 sha3-224 sha3-256
  sha3-384 sha3-512 sha384 sha512
  sha512-224 sha512-256 shake128 shake256
  sm3

  OpenSSL> list -digest-algorithms
  ...
  BLAKE2b512
  ...
  SHA3-512
  ...

  

  Steps to reproduce:

  in openssl_ca.conf set 'default_md = blake2b512' or 'default_md =
  sha3-512'

  generating a certificate ends with

  'error:100C508A:elliptic curve routines:pkey_ec_ctrl:invalid digest
  type:crypto/ec/ec_pmeth.c:327:'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/1810129/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1810129] Re: blake2b512 / sha3-512 invalid digest type

2019-06-10 Thread Dimitri John Ledkov
I don't think it follows.

For example, with an RSA key I can use SHA3-512.

Signature Algorithm: RSA-SHA3-512

The point is, that digests are not independant, and one cannot just use
any as they need to have well known identifiers as specified in the
relevant RFCs.

Ie.
https://tools.ietf.org/html/rfc5280
https://tools.ietf.org/html/rfc3279
https://tools.ietf.org/html/rfc4055

And similar.

The SHA3 algorithms are being added in this draft:
https://tools.ietf.org/html/draft-turner-lamps-adding-sha3-to-pkix-01#ref-I-D.ietf-curdle-pkix

But it looks like it has expired 
https://datatracker.ietf.org/doc/draft-turner-lamps-adding-sha3-to-pkix/

So i'm not sure what openssl is basing their implementation on. Maybe
something published by IEEE?!

For elliptic curve keys it seems like the supported digests are all the usual 
suspects:
if (EVP_MD_type((const EVP_MD *)p2) != NID_sha1 &&
EVP_MD_type((const EVP_MD *)p2) != NID_ecdsa_with_SHA1 &&
EVP_MD_type((const EVP_MD *)p2) != NID_sha224 &&
EVP_MD_type((const EVP_MD *)p2) != NID_sha256 &&
EVP_MD_type((const EVP_MD *)p2) != NID_sha384 &&
EVP_MD_type((const EVP_MD *)p2) != NID_sha512) {
ECerr(EC_F_PKEY_EC_CTRL, EC_R_INVALID_DIGEST_TYPE);
return 0;
}

For RSA keys slightly larger list:
case NID_sha1:
case NID_sha224:
case NID_sha256:
case NID_sha384:
case NID_sha512:
case NID_md5:
case NID_md5_sha1:
case NID_md2:
case NID_md4:
case NID_mdc2:
case NID_ripemd160:
case NID_sha3_224:
case NID_sha3_256:
case NID_sha3_384:
case NID_sha3_512:
return 1;

If there are algos for which there are published RFCs please open a bug
upstream about adding those. If there are none defined, please submit
RFC to IETF to get them defined such that new digest algos can be added
across the internet - and not be specific to just openssl.

It's not up to Ubuntu to define new digest types in x.509, thus i'm
closing this bug report as opinion.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to openssl in Ubuntu.
https://bugs.launchpad.net/bugs/1810129

Title:
  blake2b512 / sha3-512 invalid digest type

Status in openssl package in Ubuntu:
  Opinion

Bug description:
  cosmic | openssl 1.1.1-1

  Since 1.1.1.a-1 provides support for blake2b512 / sha3-512 it would be
  expected such to work when generating certificates which however does
  not.

  OpenSSL> list -digest-commands
  blake2b512 blake2s256 gost md4
  md5 mdc2 rmd160 sha1
  sha224 sha256 sha3-224 sha3-256
  sha3-384 sha3-512 sha384 sha512
  sha512-224 sha512-256 shake128 shake256
  sm3

  OpenSSL> list -digest-algorithms
  ...
  BLAKE2b512
  ...
  SHA3-512
  ...

  

  Steps to reproduce:

  in openssl_ca.conf set 'default_md = blake2b512' or 'default_md =
  sha3-512'

  generating a certificate ends with

  'error:100C508A:elliptic curve routines:pkey_ec_ctrl:invalid digest
  type:crypto/ec/ec_pmeth.c:327:'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/1810129/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1810129] Re: blake2b512 / sha3-512 invalid digest type

2019-04-19 Thread km
> did you try to use sha3-512 and did that work?

please see the initial report:

> or 'default_md = sha3-512'

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to openssl in Ubuntu.
https://bugs.launchpad.net/bugs/1810129

Title:
  blake2b512 / sha3-512 invalid digest type

Status in openssl package in Ubuntu:
  Incomplete

Bug description:
  cosmic | openssl 1.1.1-1

  Since 1.1.1.a-1 provides support for blake2b512 / sha3-512 it would be
  expected such to work when generating certificates which however does
  not.

  OpenSSL> list -digest-commands
  blake2b512 blake2s256 gost md4
  md5 mdc2 rmd160 sha1
  sha224 sha256 sha3-224 sha3-256
  sha3-384 sha3-512 sha384 sha512
  sha512-224 sha512-256 shake128 shake256
  sm3

  OpenSSL> list -digest-algorithms
  ...
  BLAKE2b512
  ...
  SHA3-512
  ...

  

  Steps to reproduce:

  in openssl_ca.conf set 'default_md = blake2b512' or 'default_md =
  sha3-512'

  generating a certificate ends with

  'error:100C508A:elliptic curve routines:pkey_ec_ctrl:invalid digest
  type:crypto/ec/ec_pmeth.c:327:'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/1810129/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1810129] Re: blake2b512 / sha3-512 invalid digest type

2019-04-01 Thread Dimitri John Ledkov
Not sure if blake support is in TLS certificates.

I see many more constants for sha3, than for blake:
https://paste.ubuntu.com/p/gjzTwVTCBX/

did you try to use sha3-512 and did that work?

** Changed in: openssl (Ubuntu)
   Status: New => Incomplete

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to openssl in Ubuntu.
https://bugs.launchpad.net/bugs/1810129

Title:
  blake2b512 / sha3-512 invalid digest type

Status in openssl package in Ubuntu:
  Incomplete

Bug description:
  cosmic | openssl 1.1.1-1

  Since 1.1.1.a-1 provides support for blake2b512 / sha3-512 it would be
  expected such to work when generating certificates which however does
  not.

  OpenSSL> list -digest-commands
  blake2b512 blake2s256 gost md4
  md5 mdc2 rmd160 sha1
  sha224 sha256 sha3-224 sha3-256
  sha3-384 sha3-512 sha384 sha512
  sha512-224 sha512-256 shake128 shake256
  sm3

  OpenSSL> list -digest-algorithms
  ...
  BLAKE2b512
  ...
  SHA3-512
  ...

  

  Steps to reproduce:

  in openssl_ca.conf set 'default_md = blake2b512' or 'default_md =
  sha3-512'

  generating a certificate ends with

  'error:100C508A:elliptic curve routines:pkey_ec_ctrl:invalid digest
  type:crypto/ec/ec_pmeth.c:327:'

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openssl/+bug/1810129/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp