Open-source aspects of GOST Cryptography
 help / color / mirror / Atom feed
From: Vitaly Chikunov <vt@altlinux.org>
To: oss-gost-crypto@lists.altlinux.org
Subject: [oss-gost-crypto] Тестовые вектора для  gost-engine
Date: Mon, 21 Jan 2019 07:04:38 +0300
Message-ID: <20190121040438.4ms55vuz3f3mmjzr@altlinux.org> (raw)
In-Reply-To: <CADqLbzL0GS6sok0QgPZGp1msWz9iwV+h6fOH8YULY0fTe7fj9Q@mail.gmail.com>

Hi,

JFYI. Я пока предварительно сделал тесты параметров для gost-engine:

  https://github.com/vt-alt/gost-engine/commit/e66833fdbb09e029a3eeb9155f0

Все тестовые вектора которые выдало КриптоПро (с пометкой cp) проходят тесты
на проверку подписи успешно.

Тестовые сертификаты, которые выдал Инфотекс (с пометкой it) пока не тестирую,
но половина их них даже не загружается (запарывается на X509_get0_pubkey), что,
в общем, ожидаемо.


ps. Пока тест выглядит так:

  ~/src/gost-engine/1.1.2-dev (test_params)$ bin/test_params
  Test id-GostR3410-2001-CryptoPro-A-ParamSet (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-GostR3410-2001-CryptoPro-B-ParamSet (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-GostR3410-2001-CryptoPro-C-ParamSet (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-tc26-gost-3410-2012-256-paramSetA (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-tc26-gost-3410-2012-512-paramSetA (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-tc26-gost-3410-2012-512-paramSetB (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test id-tc26-gost-3410-2012-512-paramSetC (cp):
    EVP_PKEY_verify API   correct
    EVP_Verify API        correct
  Test short_cp_a_cer (it):
	  algo gost2012_256
	  curve id-GostR3410-2001-CryptoPro-A-ParamSet
  Test short_cp_b_cer (it):
	  algo gost2012_256
	  curve id-GostR3410-2001-CryptoPro-B-ParamSet
  Test short_cp_c_cer (it):
	  algo gost2012_256
	  curve id-GostR3410-2001-CryptoPro-C-ParamSet
  Test short_tc_a_cer (it):
	  algo gost2012_256
	  curve id-tc26-gost-3410-2012-256-paramSetA
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test short_tc_b_cer (it):
	  algo gost2012_256
	  curve id-tc26-gost-3410-2012-256-paramSetB
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test short_tc_c_cer (it):
	  algo gost2012_256
	  curve id-tc26-gost-3410-2012-256-paramSetC
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test short_tc_d_cer (it):
	  algo gost2012_256
	  curve id-tc26-gost-3410-2012-256-paramSetD
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test long_tc_a_cer (it):
	  algo gost2012_512
	  curve id-tc26-gost-3410-2012-512-paramSetA
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test long_tc_b_cer (it):
	  algo gost2012_512
	  curve id-tc26-gost-3410-2012-512-paramSetB
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)
  Test long_tc_c_cer (it):
	  algo gost2012_512
	  curve id-tc26-gost-3410-2012-512-paramSetC
  140161183687936:error:0D078079:asn1 encoding routines:asn1_item_embed_d2i:field missing:crypto/asn1/tasn_dec.c:406:Field=hash_params, Type=GOST_KEY_PARAMS
  140161183687936:error:80064065:lib(128):decode_gost_algor_params:bad pkey parameters format:/home/vt/src/gost-engine/gost_ameth.c:158:
  140161183687936:error:0B09407D:x509 certificate routines:x509_pubkey_decode:public key decode error:crypto/x509/x_pubkey.c:124:
  Error at /home/vt/src/gost-engine/test_params.c:909 pk = X509_get0_pubkey(x)



       reply	other threads:[~2019-01-21  4:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-21  4:04                   ` Vitaly Chikunov [this message]
2019-01-21  5:41                     ` Vitaly Chikunov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190121040438.4ms55vuz3f3mmjzr@altlinux.org \
    --to=vt@altlinux.org \
    --cc=oss-gost-crypto@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Open-source aspects of GOST Cryptography

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/oss-gost-crypto/0 oss-gost-crypto/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 oss-gost-crypto oss-gost-crypto/ http://lore.altlinux.org/oss-gost-crypto \
		oss-gost-crypto@lists.altlinux.org oss-gost-crypto@lists.altlinux.ru oss-gost-crypto@lists.altlinux.com
	public-inbox-index oss-gost-crypto

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.oss-gost-crypto


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git