Skip to content

ECDSA verification support#98

Merged
titanous merged 2 commits intomasterfrom
ecdsa
Aug 13, 2016
Merged

ECDSA verification support#98
titanous merged 2 commits intomasterfrom
ecdsa

Conversation

@titanous
Copy link
Copy Markdown
Contributor

  • verify: Don't assume signature method, use key type

    It is unsafe to use the signature method field, as it could result in a key confusion attack. Use the key type instead.
    Also, don't assume that we're only working with Ed25519.

  • verify: Add support for ecdsa-sha2-p256 signatures

It is unsafe to use the signature method field, as it could result
in a key confusion attack. Use the key type instead.

Also, don't assume that we're only working with Ed25519.

Signed-off-by: Jonathan Rudenberg <jonathan@titanous.com>
Signed-off-by: Jonathan Rudenberg <jonathan@titanous.com>
@titanous titanous changed the title Ecdsa ECDSA verification support Aug 12, 2016
func (ecdsaSigner) Type() string {
return data.KeyTypeECDSA_SHA2_P256
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do these definitions belong in the test file?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah. This patch intentionally implements only verification in the exposed code. This is in preparation for supporting ECDSA signing keys via PKCS11 in external devices like the Yubikey and HSMs. If you can store keys locally, Ed25519 should be used. We're only adding support for ECDSA because the dedicated hardware devices do not support Ed25519.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gotcha.

@lmars
Copy link
Copy Markdown
Contributor

lmars commented Aug 12, 2016

LGTM

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

Successfully merging this pull request may close these issues.

2 participants