purify
C++ Purify implementation with native circuit and BPP support
Loading...
Searching...
No Matches
legacy.cpp File Reference

Purify-derived BIP340 signing helpers with prepared nonces and wire-format artifacts. More...

#include "purify/puresign/legacy.hpp"
#include <algorithm>
#include <cstring>
#include "bulletproof_internal.hpp"
#include "detail/common.hpp"
#include "purify/bppp.hpp"
#include "purify/curve.hpp"

Go to the source code of this file.

Namespaces

namespace  purify
 
namespace  purify::puresign
 
namespace  purify::puresign::api_impl
 

Functions

Result< Signaturepurify::puresign::api_impl::sign_message_with_prepared (const SecretKey &secret, std::span< const unsigned char > message, PreparedNonce &&prepared, purify_secp_context *secp_context)
 
Result< Signaturepurify::puresign::api_impl::sign_with_prepared_topic (const SecretKey &secret, std::span< const unsigned char > message, PreparedNonce &&prepared, purify_secp_context *secp_context)
 
Result< PublicKeypurify::puresign::api_impl::derive_public_key (const SecretKey &secret, purify_secp_context *secp_context)
 
Result< MessageProofCachepurify::puresign::api_impl::build_message_proof_cache (std::span< const unsigned char > message)
 
Result< TopicProofCachepurify::puresign::api_impl::build_topic_proof_cache (std::span< const unsigned char > topic)
 
Result< PreparedNoncepurify::puresign::api_impl::prepare_message_nonce (const SecretKey &secret, std::span< const unsigned char > message, purify_secp_context *secp_context)
 
Result< PreparedNonceWithProofpurify::puresign::api_impl::prepare_message_nonce_with_proof (const SecretKey &secret, std::span< const unsigned char > message, purify_secp_context *secp_context)
 
Result< PreparedNonceWithProofpurify::puresign::api_impl::prepare_message_nonce_with_proof (const SecretKey &secret, const MessageProofCache &cache, purify_secp_context *secp_context)
 
Result< PreparedNoncepurify::puresign::api_impl::prepare_topic_nonce (const SecretKey &secret, std::span< const unsigned char > topic, purify_secp_context *secp_context)
 
Result< PreparedNonceWithProofpurify::puresign::api_impl::prepare_topic_nonce_with_proof (const SecretKey &secret, std::span< const unsigned char > topic, purify_secp_context *secp_context)
 
Result< PreparedNonceWithProofpurify::puresign::api_impl::prepare_topic_nonce_with_proof (const SecretKey &secret, const TopicProofCache &cache, purify_secp_context *secp_context)
 
Result< Signaturepurify::puresign::api_impl::sign_message (const SecretKey &secret, std::span< const unsigned char > message, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_message_with_prepared_proof (const SecretKey &secret, std::span< const unsigned char > message, PreparedNonceWithProof &&prepared, purify_secp_context *secp_context)
 
Result< Signaturepurify::puresign::api_impl::sign_with_topic (const SecretKey &secret, std::span< const unsigned char > message, std::span< const unsigned char > topic, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_with_prepared_topic_proof (const SecretKey &secret, std::span< const unsigned char > message, PreparedNonceWithProof &&prepared, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_message_with_proof (const SecretKey &secret, std::span< const unsigned char > message, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_message_with_proof (const SecretKey &secret, const MessageProofCache &cache, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_with_topic_proof (const SecretKey &secret, std::span< const unsigned char > message, std::span< const unsigned char > topic, purify_secp_context *secp_context)
 
Result< ProvenSignaturepurify::puresign::api_impl::sign_with_topic_proof (const SecretKey &secret, std::span< const unsigned char > message, const TopicProofCache &cache, purify_secp_context *secp_context)
 
Result< bool > purify::puresign::api_impl::verify_signature (const PublicKey &public_key, std::span< const unsigned char > message, const Signature &signature, purify_secp_context *secp_context)
 
Result< bool > purify::puresign::api_impl::verify_message_nonce_proof (const PublicKey &public_key, std::span< const unsigned char > message, const NonceProof &nonce_proof, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_message_nonce_proof (const MessageProofCache &cache, const PublicKey &public_key, const NonceProof &nonce_proof, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_topic_nonce_proof (const PublicKey &public_key, std::span< const unsigned char > topic, const NonceProof &nonce_proof, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_topic_nonce_proof (const TopicProofCache &cache, const PublicKey &public_key, const NonceProof &nonce_proof, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_message_signature_with_proof (const PublicKey &public_key, std::span< const unsigned char > message, const ProvenSignature &signature, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_message_signature_with_proof (const MessageProofCache &cache, const PublicKey &public_key, const ProvenSignature &signature, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_topic_signature_with_proof (const PublicKey &public_key, std::span< const unsigned char > message, std::span< const unsigned char > topic, const ProvenSignature &signature, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 
Result< bool > purify::puresign::api_impl::verify_topic_signature_with_proof (const TopicProofCache &cache, const PublicKey &public_key, std::span< const unsigned char > message, const ProvenSignature &signature, purify_secp_context *secp_context, ExperimentalBulletproofBackendCache *circuit_cache)
 

Variable Documentation

◆ binding_digest

XOnly32 binding_digest {}

◆ eval_input

Bytes eval_input

Definition at line 132 of file legacy.cpp.

◆ nonce

Nonce nonce {}

Definition at line 129 of file legacy.cpp.

Referenced by purify::puresign::PreparedNonce::from_parts().

◆ scalar

Scalar32 scalar {}

Definition at line 128 of file legacy.cpp.

Referenced by purify::puresign::PreparedNonce::from_parts().

◆ scope

PreparedNonce::Scope scope

Definition at line 127 of file legacy.cpp.

Referenced by purify::puresign::PreparedNonce::from_parts().

◆ signer_pubkey

XOnly32 signer_pubkey {}

Definition at line 130 of file legacy.cpp.

Referenced by purify::puresign::PreparedNonce::from_parts().