Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EC Public key expansion does not prefix with 4 #2036

Open
berendsliedrecht opened this issue Sep 13, 2024 · 0 comments
Open

EC Public key expansion does not prefix with 4 #2036

berendsliedrecht opened this issue Sep 13, 2024 · 0 comments

Comments

@berendsliedrecht
Copy link
Contributor

Looking here:

export function expand(publicKey: Uint8Array, curve: 'P-256' | 'P-384' | 'P-521' | 'secp256k1'): Uint8Array {

This code does not seem to add the required 4 as a prefix for an EC expanded public key.

"The older uncompressed keys are 65 bytes, consisting of constant prefix (0x04), followed by two 256-bit integers called x and y (2 * 32 bytes)."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant