#
# Copyright 2022 The OpenSSL Project Authors. All Rights Reserved.
#
# Licensed under the Apache License 2.0 (the "License").  You may not use
# this file except in compliance with the License.  You can obtain a copy
# in the file LICENSE in the source distribution or at
# https://www.openssl.org/source/license.html

# Tests start with one of these keywords
#       Cipher Decrypt Derive Digest Encoding KDF MAC PBE
#       PrivPubKeyPair Sign Verify VerifyRecover
# and continue until a blank line. Lines starting with a pound sign are ignored.

Title = RFC 6979 deterministic DSA_1024 tests

PrivateKey=DSA_1024_PRIV
-----BEGIN PRIVATE KEY-----
MIIBSgIBADCCASsGByqGSM44BAEwggEeAoGBAIb1ygPc/rIlBj/4MKDHabndnWFT
rZHXzif3h8QyeLRH5lM7hrGL7W6KSLeEoUwlLFvg2/YLhtY4W9LxL7dj7Yhzq/0/
W6LgqMClkILqwFaTXlKdr3xhBGeJnHet7fyEbIgYcLexmytY+b4FIaFwAuO91rhm
he6Qs9mhsCt4Kxd5AhUAmW+Wf2yOOI2eKNAeIF+6lXpWmLECgYAHsPklRhULYlFL
t3HioMDOOH8DvabFa1BSCf8l/TwTPYm7zZfpBOCRFNmn3v3q38kHjqVE0uQBruzE
C7n7v3j9h5laEKHCfLd4m1lLp++1xDJqn+WaBw4TbbdxdUZK3KQXvl3OL0DRCkaj
o5Q/Jqt/2cA5j/jHbuClaCaoqI8dvQQWAhRBFgLLGabMw0SU152Y7x5+1a8l9w==
-----END PRIVATE KEY-----

PublicKey=DSA_1024_PUB
-----BEGIN PUBLIC KEY-----
MIIBtjCCASsGByqGSM44BAEwggEeAoGBAIb1ygPc/rIlBj/4MKDHabndnWFTrZHX
zif3h8QyeLRH5lM7hrGL7W6KSLeEoUwlLFvg2/YLhtY4W9LxL7dj7Yhzq/0/W6Lg
qMClkILqwFaTXlKdr3xhBGeJnHet7fyEbIgYcLexmytY+b4FIaFwAuO91rhmhe6Q
s9mhsCt4Kxd5AhUAmW+Wf2yOOI2eKNAeIF+6lXpWmLECgYAHsPklRhULYlFLt3Hi
oMDOOH8DvabFa1BSCf8l/TwTPYm7zZfpBOCRFNmn3v3q38kHjqVE0uQBruzEC7n7
v3j9h5laEKHCfLd4m1lLp++1xDJqn+WaBw4TbbdxdUZK3KQXvl3OL0DRCkajo5Q/
Jqt/2cA5j/jHbuClaCaoqI8dvQOBhAACgYBd9eAd7THQKX4nThaRwZL+WGj++eGa
hHdkVLEAzxb2U5IZWji5BSPiVC7mGHHARAy4fDIvxLTS7F4efsdm4b6NTOk1Q33B
HDyP1CYziTPr/nOcs0ZfTTZoxeRzUIJTseaC9ly9xPrpPC6iEjkOVJBahuIiMXC0
Tqp9pd2f/Pt/Ow==
-----END PUBLIC KEY-----

PrivPubKeyPair=DSA_1024_PRIV:DSA_1024_PUB

DigestSign = SHA1
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "sample"
Output = 302C02142E1A0C2562B2912CAAF89186FB0F42001585DA55021429EFB6B0AFF2D7A68EB70CA313022253B9A88DF5

DigestVerify = SHA1
Key = DSA_1024_PUB
Input = "sample"
Output = 302C02142E1A0C2562B2912CAAF89186FB0F42001585DA55021429EFB6B0AFF2D7A68EB70CA313022253B9A88DF5

DigestSign = SHA224
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "sample"
Output = 302C02144BC3B686AEA70145856814A6F1BB53346F02101E0214410697B92295D994D21EDD2F4ADA85566F6F94C1

DigestVerify = SHA224
Key = DSA_1024_PUB
Input = "sample"
Output = 302C02144BC3B686AEA70145856814A6F1BB53346F02101E0214410697B92295D994D21EDD2F4ADA85566F6F94C1

DigestSign = SHA256
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "sample"
Output = 302D02150081F2F5850BE5BC123C43F71A3033E9384611C54502144CDD914B65EB6C66A8AAAD27299BEE6B035F5E89

DigestVerify = SHA256
Key = DSA_1024_PUB
Input = "sample"
Output = 302D02150081F2F5850BE5BC123C43F71A3033E9384611C54502144CDD914B65EB6C66A8AAAD27299BEE6B035F5E89

DigestSign = SHA384
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "sample"
Output = 302C021407F2108557EE0E3921BC1774F1CA9B410B4CE65A021454DF70456C86FAC10FAB47C1949AB83F2C6F7595

DigestVerify = SHA384
Key = DSA_1024_PUB
Input = "sample"
Output = 302C021407F2108557EE0E3921BC1774F1CA9B410B4CE65A021454DF70456C86FAC10FAB47C1949AB83F2C6F7595

DigestSign = SHA512
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "sample"
Output = 302C021416C3491F9B8C3FBBDD5E7A7B667057F0D8EE8E1B021402C36A127A7B89EDBB72E4FFBC71DABC7D4FC69C

DigestVerify = SHA512
Key = DSA_1024_PUB
Input = "sample"
Output = 302C021416C3491F9B8C3FBBDD5E7A7B667057F0D8EE8E1B021402C36A127A7B89EDBB72E4FFBC71DABC7D4FC69C

DigestSign = SHA1
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "test"
Output = 302C021442AB2052FD43E123F0607F115052A67DCD9C5C770214183916B0230D45B9931491D4C6B0BD2FB4AAF088

DigestVerify = SHA1
Key = DSA_1024_PUB
Input = "test"
Output = 302C021442AB2052FD43E123F0607F115052A67DCD9C5C770214183916B0230D45B9931491D4C6B0BD2FB4AAF088

DigestSign = SHA224
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "test"
Output = 302C02146868E9964E36C1689F6037F91F28D5F2C30610F2021449CEC3ACDC83018C5BD2674ECAAD35B8CD22940F

DigestVerify = SHA224
Key = DSA_1024_PUB
Input = "test"
Output = 302C02146868E9964E36C1689F6037F91F28D5F2C30610F2021449CEC3ACDC83018C5BD2674ECAAD35B8CD22940F

DigestSign = SHA256
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "test"
Output = 302C021422518C127299B0F6FDC9872B282B9E70D079081202146837EC18F150D55DE95B5E29BE7AF5D01E4FE160

DigestVerify = SHA256
Key = DSA_1024_PUB
Input = "test"
Output = 302C021422518C127299B0F6FDC9872B282B9E70D079081202146837EC18F150D55DE95B5E29BE7AF5D01E4FE160

DigestSign = SHA384
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "test"
Output = 302E021500854CF929B58D73C3CBFDC421E8D5430CD6DB5E6602150091D0E0F53E22F898D158380676A871A157CDA622

DigestVerify = SHA384
Key = DSA_1024_PUB
Input = "test"
Output = 302E021500854CF929B58D73C3CBFDC421E8D5430CD6DB5E6602150091D0E0F53E22F898D158380676A871A157CDA622

DigestSign = SHA512
Key = DSA_1024_PRIV
NonceType = deterministic
Input = "test"
Output = 302D0215008EA47E475BA8AC6F2D821DA3BD212D11A3DEB9A002147C670C7AD72B6C050C109E1790008097125433E8

DigestVerify = SHA512
Key = DSA_1024_PUB
Input = "test"
Output = 302D0215008EA47E475BA8AC6F2D821DA3BD212D11A3DEB9A002147C670C7AD72B6C050C109E1790008097125433E8

Title = RFC 6979 deterministic DSA_2048 tests

PrivateKey=DSA_2048_PRIV
-----BEGIN PRIVATE KEY-----
MIICZAIBADCCAjkGByqGSM44BAEwggIsAoIBAQCdtvtZUbZrtv4eFA8dLOVQI3QW
H9ZTjfFkghhkLwtcSMj3pBqt+hhzJLh2dPoYIrAPHs+BNpQ9fFV1cmTloaRP/gEu
mTbgDB0+kxCwHH0XmAXTBYsqn0u2+XFr/mEXxrWzzE2b40EQStSoCtbJTgBfS5k+
FPCR61F0O/MwUMON4jVWfhs0w9alwM6qGg82ghPD0ZhD0LSwncufxy05yN5B8b8U
1LtFY8ooNxYhytMyS2otOSFFvr+sdIgFI29cov6SuHHNj5w20ykrVQnKjKp3oq38
e/133ab3ESWnRW/qFT5DMlaiJhxqBu02k3l+eZX61aq7z74+2idB43VASuJbAiEA
8sMRk3TOdsk1aZC0ZTdKF/I/ntNQib2Wn2HG3emZjB8CggEAXH/2sG+PFD/oKIQz
ST5HacTZiKzlviWg4kgJZwcWxhPXsM7mky+PqnxE0sskUj2lP75PbsNZWJLRqljE
MooGxGoVZi5+qnA6Hez4u7LQXb4uuVbBQqM4Zh0QRhwNE1RyCFBX80lDCf+nPGEf
eLMq27V0DDYcnzW+kJl9sgFOLvWqYXgvU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AGZwmMZUQmx41/ggHqxsID7wMNQ2BQMsLx+pN+Ujfb2UnzSgolZP
4Sbci3FcUUGALOCXnIJGRjxA5ra9qiUT+mEXKHFsLk/VO8lbieaZSdllEuhzucj4
39SZzDEoglYa3ssx9ljpNMDBl/LE2WsFy61nOB57doiR5No4Q9JNlM37USbpuL8h
6DWO4OCjDvE/1qZkwNzjcx9/tJpIRaT9glRoeXKi04JZnJusTg7XmYGTB4kTAyVY
E0l2QQuJ0sFx0SOsNf2XchlZeqfRXBqaQo5ZGU91xyHry8+uRGlqSZr6dOBCmfEy
AmYBY4y4ereRkNSgmGMV2o7sZWHJOJlr6t8=
-----END PUBLIC KEY-----

PrivPubKeyPair=DSA_2048_PRIV:DSA_2048_PUB

DigestSign = SHA1
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "sample"
Output = 304502203A1B2DBD7489D6ED7E608FD036C83AF396E290DBD602408E8677DAABD6E7445A022100D26FCBA19FA3E3058FFC02CA1596CDBB6E0D20CB37B06054F7E36DED0CDBBCCF

DigestVerify = SHA1
Key = DSA_2048_PUB
Input = "sample"
Output = 304502203A1B2DBD7489D6ED7E608FD036C83AF396E290DBD602408E8677DAABD6E7445A022100D26FCBA19FA3E3058FFC02CA1596CDBB6E0D20CB37B06054F7E36DED0CDBBCCF

DigestSign = SHA224
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "sample"
Output = 3046022100DC9F4DEADA8D8FF588E98FED0AB690FFCE858DC8C79376450EB6B76C24537E2C022100A65A9C3BC7BABE286B195D5DA68616DA8D47FA0097F36DD19F517327DC848CEC

DigestVerify = SHA224
Key = DSA_2048_PUB
Input = "sample"
Output = 3046022100DC9F4DEADA8D8FF588E98FED0AB690FFCE858DC8C79376450EB6B76C24537E2C022100A65A9C3BC7BABE286B195D5DA68616DA8D47FA0097F36DD19F517327DC848CEC

DigestSign = SHA256
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "sample"
Output = 3045022100EACE8BDBBE353C432A795D9EC556C6D021F7A03F42C36E9BC87E4AC7932CC80902207081E175455F9247B812B74583E9E94F9EA79BD640DC962533B0680793A38D53

DigestVerify = SHA256
Key = DSA_2048_PUB
Input = "sample"
Output = 3045022100EACE8BDBBE353C432A795D9EC556C6D021F7A03F42C36E9BC87E4AC7932CC80902207081E175455F9247B812B74583E9E94F9EA79BD640DC962533B0680793A38D53

DigestSign = SHA384
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "sample"
Output = 3045022100B2DA945E91858834FD9BF616EBAC151EDBC4B45D27D0DD4A7F6A22739F45C00B022019048B63D9FD6BCA1D9BAE3664E1BCB97F7276C306130969F63F38FA8319021B

DigestVerify = SHA384
Key = DSA_2048_PUB
Input = "sample"
Output = 3045022100B2DA945E91858834FD9BF616EBAC151EDBC4B45D27D0DD4A7F6A22739F45C00B022019048B63D9FD6BCA1D9BAE3664E1BCB97F7276C306130969F63F38FA8319021B

DigestSign = SHA512
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "sample"
Output = 304502202016ED092DC5FB669B8EFB3D1F31A91EECB199879BE0CF78F02BA062CB4C942E022100D0C76F84B5F091E141572A639A4FB8C230807EEA7D55C8A154A224400AFF2351

DigestVerify = SHA512
Key = DSA_2048_PUB
Input = "sample"
Output = 304502202016ED092DC5FB669B8EFB3D1F31A91EECB199879BE0CF78F02BA062CB4C942E022100D0C76F84B5F091E141572A639A4FB8C230807EEA7D55C8A154A224400AFF2351

DigestSign = SHA1
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "test"
Output = 3045022100C18270A93CFC6063F57A4DFA86024F700D980E4CF4E2CB65A504397273D98EA00220414F22E5F31A8B6D33295C7539C1C1BA3A6160D7D68D50AC0D3A5BEAC2884FAA

DigestVerify = SHA1
Key = DSA_2048_PUB
Input = "test"
Output = 3045022100C18270A93CFC6063F57A4DFA86024F700D980E4CF4E2CB65A504397273D98EA00220414F22E5F31A8B6D33295C7539C1C1BA3A6160D7D68D50AC0D3A5BEAC2884FAA

DigestSign = SHA224
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "test"
Output = 30450220272ABA31572F6CC55E30BF616B7A265312018DD325BE031BE0CC82AA17870EA3022100E9CC286A52CCE201586722D36D1E917EB96A4EBDB47932F9576AC645B3A60806

DigestVerify = SHA224
Key = DSA_2048_PUB
Input = "test"
Output = 30450220272ABA31572F6CC55E30BF616B7A265312018DD325BE031BE0CC82AA17870EA3022100E9CC286A52CCE201586722D36D1E917EB96A4EBDB47932F9576AC645B3A60806

DigestSign = SHA256
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "test"
Output = 30450221008190012A1969F9957D56FCCAAD223186F423398D58EF5B3CEFD5A4146A4476F002207452A53F7075D417B4B013B278D1BB8BBD21863F5E7B1CEE679CF2188E1AB19E

DigestVerify = SHA256
Key = DSA_2048_PUB
Input = "test"
Output = 30450221008190012A1969F9957D56FCCAAD223186F423398D58EF5B3CEFD5A4146A4476F002207452A53F7075D417B4B013B278D1BB8BBD21863F5E7B1CEE679CF2188E1AB19E

DigestSign = SHA384
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "test"
Output = 30440220239E66DDBE8F8C230A3D071D601B6FFBDFB5901F94D444C6AF56F732BEB954BE02206BD737513D5E72FE85D1C750E0F73921FE299B945AAD1C802F15C26A43D34961

DigestVerify = SHA384
Key = DSA_2048_PUB
Input = "test"
Output = 30440220239E66DDBE8F8C230A3D071D601B6FFBDFB5901F94D444C6AF56F732BEB954BE02206BD737513D5E72FE85D1C750E0F73921FE299B945AAD1C802F15C26A43D34961

DigestSign = SHA512
Key = DSA_2048_PRIV
NonceType = deterministic
Input = "test"
Output = 304602210089EC4BB1400ECCFF8E7D9AA515CD1DE7803F2DAFF09693EE7FD1353E90A68307022100C9F0BDABCC0D880BB137A994CC7F3980CE91CC10FAF529FC46565B15CEA854E1

DigestVerify = SHA512
Key = DSA_2048_PUB
Input = "test"
Output = 304602210089EC4BB1400ECCFF8E7D9AA515CD1DE7803F2DAFF09693EE7FD1353E90A68307022100C9F0BDABCC0D880BB137A994CC7F3980CE91CC10FAF529FC46565B15CEA854E1
