iPXE
ecdsa.h File Reference

Elliptic curve digital signature algorithm (ECDSA). More...

#include <ipxe/crypto.h>

Go to the source code of this file.

Macros

#define ECDSA_UNCOMPRESSED   0x04
 Uncompressed curve point.

Functions

 FILE_LICENCE (GPL2_OR_LATER_OR_UBDL)
 FILE_SECBOOT (PERMITTED)

Variables

struct pubkey_algorithm ecdsa_algorithm
 ECDSA public-key algorithm.

Detailed Description

Elliptic curve digital signature algorithm (ECDSA).

Definition in file ecdsa.h.

Macro Definition Documentation

◆ ECDSA_UNCOMPRESSED

#define ECDSA_UNCOMPRESSED   0x04

Uncompressed curve point.

Definition at line 16 of file ecdsa.h.

Referenced by ecdsa_parse_key().

Function Documentation

◆ FILE_LICENCE()

FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )

◆ FILE_SECBOOT()

FILE_SECBOOT ( PERMITTED )

Variable Documentation

◆ ecdsa_algorithm

struct pubkey_algorithm ecdsa_algorithm
extern

ECDSA public-key algorithm.

Definition at line 911 of file ecdsa.c.

911 {
912 .name = "ecdsa",
913 .encrypt = pubkey_null_encrypt,
914 .decrypt = pubkey_null_decrypt,
915 .sign = ecdsa_sign,
916 .verify = ecdsa_verify,
917 .match = ecdsa_match,
918};
int pubkey_null_decrypt(struct pubkey_algorithm *pubkey __unused, const struct asn1_cursor *key __unused, const struct asn1_cursor *ciphertext __unused, struct asn1_builder *plaintext __unused)
int pubkey_null_encrypt(struct pubkey_algorithm *pubkey __unused, const struct asn1_cursor *key __unused, const struct asn1_cursor *plaintext __unused, struct asn1_builder *ciphertext __unused)
static int ecdsa_match(struct pubkey_algorithm *pubkey __unused, const struct asn1_cursor *private_key, const struct asn1_cursor *public_key)
Check for matching ECDSA public/private key pair.
Definition ecdsa.c:884
static int ecdsa_sign(struct pubkey_algorithm *pubkey __unused, const struct asn1_cursor *key, struct digest_algorithm *digest, const void *value, struct asn1_builder *signature)
Sign digest value using ECDSA.
Definition ecdsa.c:778
static int ecdsa_verify(struct pubkey_algorithm *pubkey __unused, const struct asn1_cursor *key, struct digest_algorithm *digest, const void *value, const struct asn1_cursor *signature)
Verify signed digest using ECDSA.
Definition ecdsa.c:836

Referenced by __tls_cipher_suite(), __tls_cipher_suite(), __tls_cipher_suite(), __tls_cipher_suite(), __tls_cipher_suite(), __tls_cipher_suite(), PUBKEY_SIGN_TEST(), PUBKEY_SIGN_TEST(), PUBKEY_SIGN_TEST(), and PUBKEY_SIGN_TEST().