net.corda.core.crypto

## Class SignatureScheme

- net.corda.core.crypto.SignatureScheme

-     public class SignatureScheme

  This class is used to define a digital signature scheme.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `SignatureScheme(int schemeNumberID, java.lang.String schemeCodeName, java.lang.String algorithmName, java.security.Signature sig, java.security.KeyFactory keyFactory, java.security.KeyPairGeneratorSpi keyPairGenerator, java.security.spec.AlgorithmParameterSpec algSpec, int keySize, java.lang.String desc)` This class is used to define a digital signature scheme.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `component1()`
    `java.lang.String` | `component2()`
    `java.lang.String` | `component3()`
    `java.security.Signature` | `component4()`
    `java.security.KeyFactory` | `component5()`
    `java.security.KeyPairGeneratorSpi` | `component6()`
    `java.security.spec.AlgorithmParameterSpec` | `component7()`
    `int` | `component8()`
    `java.lang.String` | `component9()`
    `SignatureScheme` | `copy(int schemeNumberID, java.lang.String schemeCodeName, java.lang.String algorithmName, java.security.Signature sig, java.security.KeyFactory keyFactory, java.security.KeyPairGeneratorSpi keyPairGenerator, java.security.spec.AlgorithmParameterSpec algSpec, int keySize, java.lang.String desc)` This class is used to define a digital signature scheme.
    `boolean` | `equals(java.lang.Object p)`
    `java.security.spec.AlgorithmParameterSpec` | `getAlgSpec()`
    `java.lang.String` | `getAlgorithmName()`
    `java.lang.String` | `getDesc()`
    `java.security.KeyFactory` | `getKeyFactory()`
    `java.security.KeyPairGeneratorSpi` | `getKeyPairGenerator()`
    `int` | `getKeySize()`
    `java.lang.String` | `getSchemeCodeName()`
    `int` | `getSchemeNumberID()`
    `java.security.Signature` | `getSig()`
    `int` | `hashCode()`
    `java.lang.String` | `toString()`

- - ### Constructor Detail

    - #### SignatureScheme

          public SignatureScheme(int schemeNumberID,
                                 java.lang.String schemeCodeName,
                                 java.lang.String algorithmName,
                                 java.security.Signature sig,
                                 java.security.KeyFactory keyFactory,
                                 java.security.KeyPairGeneratorSpi keyPairGenerator,
                                 java.security.spec.AlgorithmParameterSpec algSpec,
                                 int keySize,
                                 java.lang.String desc)

      This class is used to define a digital signature scheme.

      Parameters:
        `schemeNumberID` - we assign a number ID for more efficient on-wire serialisation. Please ensure uniqueness between schemes.
        `schemeCodeName` - code name for this signature scheme (e.g. RSA_SHA256, ECDSA_SECP256K1_SHA256, ECDSA_SECP256R1_SHA256, EDDSA_ED25519_SHA512, SPHINCS-256_SHA512).
        `algorithmName` - which signature algorithm is used (e.g. RSA, ECDSA. EdDSA, SPHINCS-256).
        `sig` - the Signature class that provides the functionality of a digital signature scheme. eg. Signature.getInstance("SHA256withECDSA", "BC").
        `keyFactory` - the KeyFactory for this scheme (e.g. KeyFactory.getInstance("RSA", "BC")).
        `keyPairGenerator` - defines the Service Provider Interface (SPI) for the {@code KeyPairGenerator} class. e.g. KeyPairGenerator.getInstance("ECDSA", "BC").
        `algSpec` - parameter specs for the underlying algorithm. Note that RSA is defined by the key size rather than algSpec. eg. ECGenParameterSpec("secp256k1").
        `keySize` - the private key size (currently used for RSA only).
        `desc` - a human-readable description for this scheme.

  - ### Method Detail

    - #### getSchemeNumberID

          public int getSchemeNumberID()

    - #### getSchemeCodeName

          public java.lang.String getSchemeCodeName()

    - #### getAlgorithmName

          public java.lang.String getAlgorithmName()

    - #### getSig

          public java.security.Signature getSig()

    - #### getKeyFactory

          public java.security.KeyFactory getKeyFactory()

    - #### getKeyPairGenerator

          public java.security.KeyPairGeneratorSpi getKeyPairGenerator()

    - #### getAlgSpec

          public java.security.spec.AlgorithmParameterSpec getAlgSpec()

    - #### getKeySize

          public int getKeySize()

    - #### getDesc

          public java.lang.String getDesc()

    - #### component1

          public int component1()

    - #### component2

          public java.lang.String component2()

    - #### component3

          public java.lang.String component3()

    - #### component4

          public java.security.Signature component4()

    - #### component5

          public java.security.KeyFactory component5()

    - #### component6

          public java.security.KeyPairGeneratorSpi component6()

    - #### component7

          public java.security.spec.AlgorithmParameterSpec component7()

    - #### component8

          public int component8()

    - #### component9

          public java.lang.String component9()

    - #### copy

          public SignatureScheme copy(int schemeNumberID,
                                      java.lang.String schemeCodeName,
                                      java.lang.String algorithmName,
                                      java.security.Signature sig,
                                      java.security.KeyFactory keyFactory,
                                      java.security.KeyPairGeneratorSpi keyPairGenerator,
                                      java.security.spec.AlgorithmParameterSpec algSpec,
                                      int keySize,
                                      java.lang.String desc)

      This class is used to define a digital signature scheme.

      Parameters:
        `schemeNumberID` - we assign a number ID for more efficient on-wire serialisation. Please ensure uniqueness between schemes.
        `schemeCodeName` - code name for this signature scheme (e.g. RSA_SHA256, ECDSA_SECP256K1_SHA256, ECDSA_SECP256R1_SHA256, EDDSA_ED25519_SHA512, SPHINCS-256_SHA512).
        `algorithmName` - which signature algorithm is used (e.g. RSA, ECDSA. EdDSA, SPHINCS-256).
        `sig` - the Signature class that provides the functionality of a digital signature scheme. eg. Signature.getInstance("SHA256withECDSA", "BC").
        `keyFactory` - the KeyFactory for this scheme (e.g. KeyFactory.getInstance("RSA", "BC")).
        `keyPairGenerator` - defines the Service Provider Interface (SPI) for the {@code KeyPairGenerator} class. e.g. KeyPairGenerator.getInstance("ECDSA", "BC").
        `algSpec` - parameter specs for the underlying algorithm. Note that RSA is defined by the key size rather than algSpec. eg. ECGenParameterSpec("secp256k1").
        `keySize` - the private key size (currently used for RSA only).
        `desc` - a human-readable description for this scheme.

    - #### toString

          public java.lang.String toString()

    - #### hashCode

          public int hashCode()

    - #### equals

          public boolean equals(java.lang.Object p)