rippled
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | List of all members
ripple::SecretKey Class Reference

A secret key. More...

#include <SecretKey.h>

Collaboration diagram for ripple::SecretKey:
Collaboration graph
[legend]

Public Types

using const_iterator = std::uint8_t const *
 

Public Member Functions

 SecretKey ()=delete
 
 SecretKey (SecretKey const &)=default
 
SecretKeyoperator= (SecretKey const &)=default
 
 ~SecretKey ()
 
 SecretKey (std::array< std::uint8_t, 32 > const &data)
 
 SecretKey (Slice const &slice)
 
std::uint8_t const * data () const
 
std::size_t size () const
 
std::string to_string () const
 Convert the secret key to a hexadecimal string.
 
const_iterator begin () const noexcept
 
const_iterator cbegin () const noexcept
 
const_iterator end () const noexcept
 
const_iterator cend () const noexcept
 

Private Attributes

std::uint8_t buf_ [32]
 

Detailed Description

A secret key.

Definition at line 37 of file SecretKey.h.

Member Typedef Documentation

◆ const_iterator

Definition at line 43 of file SecretKey.h.

Constructor & Destructor Documentation

◆ SecretKey() [1/4]

ripple::SecretKey::SecretKey ( )
delete

◆ SecretKey() [2/4]

ripple::SecretKey::SecretKey ( SecretKey const &  )
default

◆ ~SecretKey()

ripple::SecretKey::~SecretKey ( )

Definition at line 51 of file SecretKey.cpp.

◆ SecretKey() [3/4]

ripple::SecretKey::SecretKey ( std::array< std::uint8_t, 32 > const &  data)

Definition at line 56 of file SecretKey.cpp.

◆ SecretKey() [4/4]

ripple::SecretKey::SecretKey ( Slice const &  slice)

Definition at line 61 of file SecretKey.cpp.

Member Function Documentation

◆ operator=()

SecretKey & ripple::SecretKey::operator= ( SecretKey const &  )
default

◆ data()

std::uint8_t const * ripple::SecretKey::data ( ) const

Definition at line 56 of file SecretKey.h.

◆ size()

std::size_t ripple::SecretKey::size ( ) const

Definition at line 62 of file SecretKey.h.

◆ to_string()

std::string ripple::SecretKey::to_string ( ) const

Convert the secret key to a hexadecimal string.

Note
The operator<< function is deliberately omitted to avoid accidental exposure of secret key material.

Definition at line 69 of file SecretKey.cpp.

◆ begin()

const_iterator ripple::SecretKey::begin ( ) const
noexcept

Definition at line 76 of file SecretKey.h.

◆ cbegin()

const_iterator ripple::SecretKey::cbegin ( ) const
noexcept

Definition at line 82 of file SecretKey.h.

◆ end()

const_iterator ripple::SecretKey::end ( ) const
noexcept

Definition at line 88 of file SecretKey.h.

◆ cend()

const_iterator ripple::SecretKey::cend ( ) const
noexcept

Definition at line 94 of file SecretKey.h.

Member Data Documentation

◆ buf_

std::uint8_t ripple::SecretKey::buf_[32]
private

Definition at line 40 of file SecretKey.h.