DigitalSignature

DigitalSignature[assoc]

represents a digital signature object.

Details

  • Digital signature is used for verifying the authenticity of a message and is dependent on both the data being signed and the private key.
  • Digital signatures can be created with GenerateDigitalSignature and GenerateFileSignature.
  • DigitalSignature[]["prop"] yields properties of the digital signature.
  • The signing algorithm type is indicated by the "Type" property of the signature. Possible types include "RSA" and "EllipticCurve".
  • Additional properties for "RSA" include:
  • "HashingMethod"hashing method
    "HashName"hash name used in padding
    "Padding"padding scheme
    "Signature"digital signature
  • Additional properties for "EllipticCurve" include:
  • "CurveName"elliptic curve used for calculating digital signature
    "HashingMethod"hashing method
    "SignatureType"mode of digital signature generation
    "R"r, first element of digital signature pair
    "S"s, second element of digital signature pair
  • For a Bitcoin blockchain digital signature, additional properties include:
  • "DER"digital signature in DER format
  • For Ethereum-based blockchain digital signatures, additional properties include:
  • "RecoveryParameter"recovery parameter used for public key recovery
  • DigitalSignature[]["Parameters"] gives all the information contained in the object, as an association.
  • DigitalSignature[]["Properties"] gives a list of available properties.
  • The DigitalSignature of an expr may be verified by using VerifyDigitalSignature.
  • The DigitalSignature of a file may be verified by using VerifyFileSignature.

Examples

open allclose all

Basic Examples  (1)

Get a digital signature object by signing a message:

Get a property of the digital signature object:

Get a list of available properties of this digital signature:

Scope  (2)

Cryptocurrencies  (2)

Get the DER-encoded digital signature typically used in Bitcoin transactions:

Get the recovery parameter used for public key recovery in the Ethereum network:

Applications  (2)

Generate a digital signature compatible with Bitcoin network requirements:

Verify the signature:

Generate a digital signature compatible with Ethereum network requirements:

Verify the signature:

Wolfram Research (2019), DigitalSignature, Wolfram Language function, https://reference.wolfram.com/language/ref/DigitalSignature.html (updated 2020).

Text

Wolfram Research (2019), DigitalSignature, Wolfram Language function, https://reference.wolfram.com/language/ref/DigitalSignature.html (updated 2020).

CMS

Wolfram Language. 2019. "DigitalSignature." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2020. https://reference.wolfram.com/language/ref/DigitalSignature.html.

APA

Wolfram Language. (2019). DigitalSignature. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/DigitalSignature.html

BibTeX

@misc{reference.wolfram_2024_digitalsignature, author="Wolfram Research", title="{DigitalSignature}", year="2020", howpublished="\url{https://reference.wolfram.com/language/ref/DigitalSignature.html}", note=[Accessed: 22-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_digitalsignature, organization={Wolfram Research}, title={DigitalSignature}, year={2020}, url={https://reference.wolfram.com/language/ref/DigitalSignature.html}, note=[Accessed: 22-November-2024 ]}