Bitcoin Core  0.20.99
P2P Digital Currency
Public Member Functions | Private Attributes | List of all members
XOnlyPubKey Class Reference

#include <pubkey.h>

Collaboration diagram for XOnlyPubKey:
[legend]

Public Member Functions

 XOnlyPubKey (Span< const unsigned char > bytes)
 Construct an x-only pubkey from exactly 32 bytes. More...
 
bool VerifySchnorr (const uint256 &msg, Span< const unsigned char > sigbytes) const
 Verify a Schnorr signature against this public key. More...
 
bool CheckPayToContract (const XOnlyPubKey &base, const uint256 &hash, bool parity) const
 
const unsigned char & operator[] (int pos) const
 
const unsigned char * data () const
 
size_t size () const
 

Private Attributes

uint256 m_keydata
 

Detailed Description

Definition at line 210 of file pubkey.h.

Constructor & Destructor Documentation

◆ XOnlyPubKey()

XOnlyPubKey::XOnlyPubKey ( Span< const unsigned char >  bytes)

Construct an x-only pubkey from exactly 32 bytes.

Definition at line 170 of file pubkey.cpp.

Here is the call graph for this function:

Member Function Documentation

◆ CheckPayToContract()

bool XOnlyPubKey::CheckPayToContract ( const XOnlyPubKey base,
const uint256 hash,
bool  parity 
) const

Definition at line 184 of file pubkey.cpp.

Here is the call graph for this function:

◆ data()

const unsigned char* XOnlyPubKey::data ( ) const
inline

Definition at line 227 of file pubkey.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ operator[]()

const unsigned char& XOnlyPubKey::operator[] ( int  pos) const
inline

Definition at line 226 of file pubkey.h.

Here is the call graph for this function:

◆ size()

size_t XOnlyPubKey::size ( ) const
inline

Definition at line 228 of file pubkey.h.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ VerifySchnorr()

bool XOnlyPubKey::VerifySchnorr ( const uint256 msg,
Span< const unsigned char >  sigbytes 
) const

Verify a Schnorr signature against this public key.

sigbytes must be exactly 64 bytes.

Definition at line 176 of file pubkey.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ m_keydata

uint256 XOnlyPubKey::m_keydata
private

Definition at line 213 of file pubkey.h.


The documentation for this class was generated from the following files: