Packages

package crypto

Ordering
  1. Alphabetic
Visibility
  1. Public
  2. All

Type Members

  1. sealed trait AesDecryptionException extends Exception
  2. final case class AesEncryptedData(cipherText: ByteVector, iv: AesIV) extends Product with Serializable

    Represents a encrypted cipher text with it's accompanying initialization vector (IV).

    Represents a encrypted cipher text with it's accompanying initialization vector (IV). Both the cipher text and the IV is needed to decrypt the cipher text.

  3. final case class AesIV extends NetworkElement with Product with Serializable

    Represents an initialization vector (IV) used in AES encryption.

  4. final case class AesKey extends NetworkElement with Product with Serializable

    Represents a encryption/decryption key.

    Represents a encryption/decryption key. AES keys can be converted to SecretKeys, and have certain length requirements.

  5. final case class AesPassword extends AnyVal with Product with Serializable
  6. final case class AesSalt(bytes: ByteVector) extends AnyVal with Product with Serializable

    Represents a salt used to derive a AES key from a human-readable passphrase.

  7. sealed abstract class BIP39Seed extends NetworkElement
  8. sealed abstract class BaseECKey extends NetworkElement with Sign

    Created by chris on 2/16/16.

  9. sealed abstract class BaseTxSigComponent extends TxSigComponent

    The TxSigComponent used to evaluate the the original Satoshi transaction digest algorithm.

    The TxSigComponent used to evaluate the the original Satoshi transaction digest algorithm. Basically this is every spk that is not a WitnessScriptPubKey EXCEPT in the case of a P2SH(witness script) ScriptPubKey

  10. sealed abstract class ChainCode extends NetworkElement
  11. sealed abstract class CryptoParams extends AnyRef

    Created by chris on 3/29/16.

    Created by chris on 3/29/16. This trait represents all of the default parameters for our elliptic curve

  12. sealed abstract class DERSignatureUtil extends AnyRef

    Created by chris on 3/23/16.

  13. sealed trait DoubleSha256Digest extends HashDigest

    Represents the result of SHA256(SHA256())

  14. sealed trait DoubleSha256DigestBE extends HashDigest

    The big endian version of DoubleSha256Digest

  15. sealed abstract class ECDigitalSignature extends BitcoinSLogger

    Created by chris on 2/26/16.

  16. sealed abstract class ECPrivateKey extends BaseECKey

    Created by chris on 2/16/16.

  17. sealed abstract class ECPublicKey extends BaseECKey

    Created by chris on 2/16/16.

  18. sealed abstract class ExtKey extends NetworkElement

    Represents an extended key as defined by BIP32 https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki

  19. sealed abstract class ExtKeyPrivVersion extends ExtKeyVersion
  20. sealed abstract class ExtKeyPubVersion extends ExtKeyVersion
  21. sealed abstract class ExtKeyVersion extends NetworkElement
  22. sealed abstract class ExtPrivateKey extends ExtKey
  23. sealed abstract class ExtPublicKey extends ExtKey
  24. sealed trait HashDigest extends NetworkElement

    Created by chris on 5/24/16.

  25. sealed abstract class MnemonicCode extends AnyRef

    A mnemonic code conforming to BIP39.

    A mnemonic code conforming to BIP39. BIP39 mnemonic codes consist of a varying number of words (most often English, possible with other languages as well) that can be used to generate an ExtPrivateKey which again can be the root of a BIP32 HD wallet.

  26. sealed trait RipeMd160Digest extends HashDigest

    Represents the result of RIPEMD160()

  27. sealed trait RipeMd160DigestBE extends HashDigest

    Represents the result of RIPEMD160() big endian

  28. sealed trait Sha1Digest extends HashDigest

    Represents the result of SHA1()

  29. sealed trait Sha1DigestBE extends HashDigest
  30. sealed trait Sha256Digest extends HashDigest

    Represents the result of SHA256()

  31. sealed trait Sha256DigestBE extends HashDigest

    Represents the result of SHA256()

  32. sealed trait Sha256Hash160Digest extends HashDigest

    Represents the result of RIPEMD160(SHA256())

  33. sealed trait Sha256Hash160DigestBE extends HashDigest

    Represents the result of RIPEMD160(SHA256()) big endian

  34. trait Sign extends AnyRef

    This is meant to be an abstraction for a org.bitcoins.core.crypto.ECPrivateKey, sometimes we will not have direct access to a private key in memory -- for instance if that key is on a hardware device -- so we need to create an abstraction of the signing process.

    This is meant to be an abstraction for a org.bitcoins.core.crypto.ECPrivateKey, sometimes we will not have direct access to a private key in memory -- for instance if that key is on a hardware device -- so we need to create an abstraction of the signing process. Fundamentally a private key takes in a scodec.bits.ByteVector and returns a ECDigitalSignature That is what this abstraction is meant to represent. If you have a ECPrivateKey in your application, you can get it's Sign type by doing this:

    val key = ECPrivateKey() val sign: scodec.bits.ByteVector => Future[ECDigitalSignature] = key.signFunction

    If you have a hardware wallet, you will need to implement the protocol to send a message to the hardware device. The type signature of the function you implement must be scodec.bits.ByteVector => Future[ECDigitalSignature]

  35. sealed trait SignatureValidationError extends TransactionSignatureCheckerResult

    Indicates that there was an error when evaluating the signature of a transaction

  36. trait TransactionSignatureChecker extends BitcoinSLogger

    Created by chris on 2/16/16.

    Created by chris on 2/16/16. Responsible for checking digital signatures on inputs against their respective public keys

  37. sealed trait TransactionSignatureCheckerResult extends AnyRef

    The result type returned by checking a signature

  38. sealed abstract class TransactionSignatureCreator extends AnyRef

    Created by chris on 7/21/16.

  39. sealed abstract class TransactionSignatureSerializer extends AnyRef

    Created by chris on 2/16/16.

    Created by chris on 2/16/16. Wrapper that serializes like Transaction, but with the modifications required for the signature hash done https://github.com/bitcoin/bitcoin/blob/93c85d458ac3e2c496c1a053e1f5925f55e29100/src/script/interpreter.cpp#L1016-L1105 bitcoinj version of this https://github.com/bitcoinj/bitcoinj/blob/master/core/src/main/java/org/bitcoinj/core/Transaction.java#L924-L1008

  40. sealed abstract class TxSigComponent extends AnyRef

    Created by chris on 4/6/16.

    Created by chris on 4/6/16. Represents a transaction whose input is being checked against the spending conditions of a ScriptPubKey

  41. sealed abstract class WitnessTxSigComponent extends TxSigComponent

    The TxSigComponent used to represent all the components necessarily for BIP143.

    The TxSigComponent used to represent all the components necessarily for BIP143. Examples of these ScriptPubKey's are P2WPKHWitnessSPKV0, P2WSHWitnessSPKV0, and P2SH(witness script)

  42. sealed abstract class WitnessTxSigComponentP2SH extends WitnessTxSigComponent

    This represents checking the WitnessTransaction against a P2SH(P2WSH) or P2SH(P2WPKH) scriptPubKey

  43. sealed abstract class WitnessTxSigComponentRaw extends WitnessTxSigComponent

    This represents checking the WitnessTransaction against a P2WPKHWitnessSPKV0 or a P2WSHWitnessSPKV0

  44. sealed abstract class WitnessTxSigComponentRebuilt extends TxSigComponent

    This represents a 'rebuilt' ScriptPubKey that was constructed from WitnessScriptPubKey After the ScriptPubKey is rebuilt, we need to use that rebuilt scriptpubkey to evaluate the ScriptSignature See BIP141 for more info on rebuilding P2WSH and P2WPKH scriptpubkeys

Value Members

  1. object AesCrypt

    Provides functionality for encrypting and decrypting with AES

  2. object AesEncryptedData extends Serializable
  3. object AesException
  4. object AesIV extends Serializable
  5. object AesKey extends Serializable
  6. object AesPassword extends Serializable
  7. object AesSalt extends Factory[AesSalt] with Serializable
  8. object BIP39Seed extends Factory[BIP39Seed]

    See also

    BIP32

  9. object BaseTxSigComponent
  10. object ChainCode extends Factory[ChainCode]
  11. object CryptoParams extends CryptoParams
  12. object DERSignatureUtil extends DERSignatureUtil
  13. object DoubleSha256Digest extends Factory[DoubleSha256Digest]
  14. object DoubleSha256DigestBE extends Factory[DoubleSha256DigestBE]
  15. object DummyECDigitalSignature extends ECDigitalSignature with Product with Serializable

    The point of this case object is to help with fee estimation an average ECDigitalSignature is 72 bytes in size Technically this number can vary, 72 bytes is the most likely though according to https://en.bitcoin.it/wiki/Elliptic_Curve_Digital_Signature_Algorithm

  16. object ECDigitalSignature extends Factory[ECDigitalSignature]
  17. object ECPrivateKey extends Factory[ECPrivateKey]
  18. object ECPublicKey extends Factory[ECPublicKey]
  19. object EmptyDigitalSignature extends ECDigitalSignature with Product with Serializable
  20. object ExtKey extends Factory[ExtKey]
  21. object ExtKeyVersion

    See also

    SLIP132 for a list of registered HD version bytes

  22. object ExtPrivateKey extends Factory[ExtPrivateKey]
  23. object ExtPublicKey extends Factory[ExtPublicKey]
  24. object MnemonicCode

    See also

    BIP39

  25. object PBKDF2

  26. object RipeMd160Digest extends Factory[RipeMd160Digest]
  27. object RipeMd160DigestBE extends Factory[RipeMd160DigestBE]
  28. object Sha1Digest extends Factory[Sha1Digest]
  29. object Sha1DigestBE extends Factory[Sha1DigestBE]
  30. object Sha256Digest extends Factory[Sha256Digest]
  31. object Sha256DigestBE extends Factory[Sha256DigestBE]
  32. object Sha256Hash160Digest extends Factory[Sha256Hash160Digest]
  33. object Sha256Hash160DigestBE extends Factory[Sha256Hash160DigestBE]
  34. object Sign
  35. object SignatureValidationErrorHashType extends SignatureValidationError with Product with Serializable

    Fails the script if the hash type is not defined on a digital signature

  36. object SignatureValidationErrorHighSValue extends SignatureValidationError with Product with Serializable

    This indicates that the digital signature did not have a Low S value as per BIP62 https://github.com/bitcoin/bips/blob/master/bip-0062.mediawiki#Low_S_values_in_signatures

  37. object SignatureValidationErrorIncorrectSignatures extends SignatureValidationError with Product with Serializable

    Signature validation failed because there were not enough correct signatures for the transaction we were given

  38. object SignatureValidationErrorNotStrictDerEncoding extends SignatureValidationError with Product with Serializable

    Signature validation failed because a signature was not encoded per the BIP66 rules https://github.com/bitcoin/bips/blob/master/bip-0066.mediawiki#specification

  39. object SignatureValidationErrorNullFail extends SignatureValidationError with Product with Serializable

    Fails the script if a an invalid signature is not an empty byte vector See BIP146 https://github.com/bitcoin/bips/blob/master/bip-0146.mediawiki#nullfail

  40. object SignatureValidationErrorPubKeyEncoding extends SignatureValidationError with Product with Serializable

    This indicates that the public key was not encoded correctly according to this function https://github.com/bitcoin/bitcoin/blob/528472111b4965b1a99c4bcf08ac5ec93d87f10f/src/script/interpreter.cpp#L214-L223

  41. object SignatureValidationErrorSignatureCount extends SignatureValidationError with Product with Serializable

    This indicates that the signature validation failed because we have more signatures left to check than public keys remaining to check them against see https://github.com/bitcoin/bitcoin/blob/master/src/script/interpreter.cpp#L914-915

  42. object SignatureValidationErrorWitnessPubKeyType extends SignatureValidationError with Product with Serializable

    Fails the script if the given public key was not compressed and the org.bitcoins.core.script.flag.ScriptVerifyWitnessPubKeyType flag was set

  43. object SignatureValidationSuccess extends TransactionSignatureCheckerResult with Product with Serializable

    Represents the case that the signatures checked inside of the transaction were all validly encoded as per the script verify flag & that the signatures were valid when checked against the public keys

  44. object TransactionSignatureChecker extends TransactionSignatureChecker
  45. object TransactionSignatureCreator extends TransactionSignatureCreator
  46. object TransactionSignatureSerializer extends TransactionSignatureSerializer
  47. object WitnessTxSigComponent
  48. object WitnessTxSigComponentP2SH
  49. object WitnessTxSigComponentRaw
  50. object WitnessTxSigComponentRebuilt

Ungrouped