Skip to content

Commit

Permalink
test: move x448 keypairs to fixtures/keys/
Browse files Browse the repository at this point in the history
PR-URL: #27962
Reviewed-By: Sam Roberts <[email protected]>
Reviewed-By: Ujjwal Sharma <[email protected]>
Reviewed-By: Rich Trott <[email protected]>
  • Loading branch information
reasonablytall authored and BridgeAR committed Jun 17, 2019
1 parent 4155bba commit 03b92e9
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 11 deletions.
8 changes: 8 additions & 0 deletions test/fixtures/keys/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,8 @@ all: \
x25519_public.pem \
ed448_private.pem \
ed448_public.pem \
x448_private.pem \
x448_public.pem \

#
# Create Certificate Authority: ca1
Expand Down Expand Up @@ -682,6 +684,12 @@ ed448_private.pem:
ed448_public.pem: ed448_private.pem
openssl pkey -in ed448_private.pem -pubout -out ed448_public.pem

x448_private.pem:
openssl genpkey -algorithm x448 -out x448_private.pem

x448_public.pem: x448_private.pem
openssl pkey -in x448_private.pem -pubout -out x448_public.pem

clean:
rm -f *.pfx *.pem *.srl ca2-database.txt ca2-serial fake-startcom-root-serial *.print *.old fake-startcom-root-issued-certs/*.pem
@> fake-startcom-root-database.txt
Expand Down
4 changes: 4 additions & 0 deletions test/fixtures/keys/x448_private.pem
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-----BEGIN PRIVATE KEY-----
MEYCAQAwBQYDK2VvBDoEOLTDbazv6vHZWOmODQ3kk8TUOQgApB4j75rpInT5zSLl
/xJHK8ixF7f+4uo+mGTCrK1sktI5UmCZ
-----END PRIVATE KEY-----
4 changes: 4 additions & 0 deletions test/fixtures/keys/x448_public.pem
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-----BEGIN PUBLIC KEY-----
MEIwBQYDK2VvAzkAioHSHVpTs6hMvghosEJDIR7ceFiE3+Xccxati64oOVJ7NWjf
ozE7ae31PXIUFq6cVYgvSKsDFPA=
-----END PUBLIC KEY-----
4 changes: 0 additions & 4 deletions test/fixtures/test_x448_privkey.pem

This file was deleted.

4 changes: 0 additions & 4 deletions test/fixtures/test_x448_pubkey.pem

This file was deleted.

6 changes: 3 additions & 3 deletions test/parallel/test-crypto-key-objects.js
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,9 @@ const privateDsa = fixtures.readKey('dsa_private_encrypted_1025.pem',
{ private: fixtures.readKey('x25519_private.pem', 'ascii'),
public: fixtures.readKey('x25519_public.pem', 'ascii'),
keyType: 'x25519' },
{ private: fixtures.readSync('test_x448_privkey.pem', 'ascii'),
public: fixtures.readSync('test_x448_pubkey.pem', 'ascii'),
keyType: 'x448' }
{ private: fixtures.readKey('x448_private.pem', 'ascii'),
public: fixtures.readKey('x448_public.pem', 'ascii'),
keyType: 'x448' },
].forEach((info) => {
const keyType = info.keyType;

Expand Down

0 comments on commit 03b92e9

Please sign in to comment.