---
title: llarp::IdentitySecret
summary: IdentitySecret is a secret key from a service node secret seed. 

---

# llarp::IdentitySecret



[IdentitySecret]() is a secret key from a service node secret seed. 


`#include <types.hpp>`

Inherits from [llarp::AlignedBuffer< 32 >](Classes/structllarp_1_1AlignedBuffer.md)

## Public Functions

|                | Name           |
| -------------- | -------------- |
| | **[IdentitySecret](Classes/structllarp_1_1IdentitySecret.md#function-identitysecret)**() |
| | **[IdentitySecret](Classes/structllarp_1_1IdentitySecret.md#function-identitysecret)**(const [IdentitySecret](Classes/structllarp_1_1IdentitySecret.md) & ) =delete<br>no copy constructor  |
| | **[IdentitySecret](Classes/structllarp_1_1IdentitySecret.md#function-identitysecret)**(const byte_t * ) =delete |
| bool | **[LoadFromFile](Classes/structllarp_1_1IdentitySecret.md#function-loadfromfile)**(const fs::path & fname)<br>load service node seed from file  |
| std::string_view | **[ToString](Classes/structllarp_1_1IdentitySecret.md#function-tostring)**() const |

## Additional inherited members

**Public Types inherited from [llarp::AlignedBuffer< 32 >](Classes/structllarp_1_1AlignedBuffer.md)**

|                | Name           |
| -------------- | -------------- |
| using std::array< byte_t, SIZE > | **[Data](Classes/structllarp_1_1AlignedBuffer.md#using-data)**  |

**Public Functions inherited from [llarp::AlignedBuffer< 32 >](Classes/structllarp_1_1AlignedBuffer.md)**

|                | Name           |
| -------------- | -------------- |
| virtual | **[~AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md#function-~alignedbuffer)**() =default |
| | **[AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md#function-alignedbuffer)**() |
| | **[AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md#function-alignedbuffer)**(const byte_t * data) |
| | **[AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md#function-alignedbuffer)**(const Data & buf) |
| [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & | **[operator=](Classes/structllarp_1_1AlignedBuffer.md#function-operator=)**(const byte_t * data) |
| [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md)< sz > | **[operator~](Classes/structllarp_1_1AlignedBuffer.md#function-operator~)**() const<br>bitwise NOT  |
| bool | **[operator==](Classes/structllarp_1_1AlignedBuffer.md#function-operator==)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| bool | **[operator!=](Classes/structllarp_1_1AlignedBuffer.md#function-operator!=)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| bool | **[operator<](Classes/structllarp_1_1AlignedBuffer.md#function-operator<)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| bool | **[operator>](Classes/structllarp_1_1AlignedBuffer.md#function-operator>)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| bool | **[operator<=](Classes/structllarp_1_1AlignedBuffer.md#function-operator<=)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| bool | **[operator>=](Classes/structllarp_1_1AlignedBuffer.md#function-operator>=)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) | **[operator^](Classes/structllarp_1_1AlignedBuffer.md#function-operator^)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) const |
| [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & | **[operator^=](Classes/structllarp_1_1AlignedBuffer.md#function-operator^=)**(const [AlignedBuffer](Classes/structllarp_1_1AlignedBuffer.md) & other) |
| byte_t & | **[operator[]](Classes/structllarp_1_1AlignedBuffer.md#function-operator[])**(size_t idx) |
| const byte_t & | **[operator[]](Classes/structllarp_1_1AlignedBuffer.md#function-operator[])**(size_t idx) const |
| void | **[Fill](Classes/structllarp_1_1AlignedBuffer.md#function-fill)**(byte_t f) |
| Data & | **[as_array](Classes/structllarp_1_1AlignedBuffer.md#function-as-array)**() |
| const Data & | **[as_array](Classes/structllarp_1_1AlignedBuffer.md#function-as-array)**() const |
| byte_t * | **[data](Classes/structllarp_1_1AlignedBuffer.md#function-data)**() |
| const byte_t * | **[data](Classes/structllarp_1_1AlignedBuffer.md#function-data)**() const |
| bool | **[IsZero](Classes/structllarp_1_1AlignedBuffer.md#function-iszero)**() const |
| void | **[Zero](Classes/structllarp_1_1AlignedBuffer.md#function-zero)**() |
| virtual void | **[Randomize](Classes/structllarp_1_1AlignedBuffer.md#function-randomize)**() |
| Data::iterator | **[begin](Classes/structllarp_1_1AlignedBuffer.md#function-begin)**() |
| Data::iterator | **[end](Classes/structllarp_1_1AlignedBuffer.md#function-end)**() |
| Data::const_iterator | **[begin](Classes/structllarp_1_1AlignedBuffer.md#function-begin)**() const |
| Data::const_iterator | **[end](Classes/structllarp_1_1AlignedBuffer.md#function-end)**() const |
| bool | **[FromBytestring](Classes/structllarp_1_1AlignedBuffer.md#function-frombytestring)**([llarp_buffer_t](Classes/structllarp__buffer__t.md) * buf) |
| bool | **[BEncode](Classes/structllarp_1_1AlignedBuffer.md#function-bencode)**([llarp_buffer_t](Classes/structllarp__buffer__t.md) * buf) const |
| bool | **[BDecode](Classes/structllarp_1_1AlignedBuffer.md#function-bdecode)**([llarp_buffer_t](Classes/structllarp__buffer__t.md) * buf) |
| std::string_view | **[ToView](Classes/structllarp_1_1AlignedBuffer.md#function-toview)**() const |
| std::string | **[ToHex](Classes/structllarp_1_1AlignedBuffer.md#function-tohex)**() const |
| std::string | **[ShortHex](Classes/structllarp_1_1AlignedBuffer.md#function-shorthex)**() const |
| bool | **[FromHex](Classes/structllarp_1_1AlignedBuffer.md#function-fromhex)**(std::string_view str) |
| constexpr size_t | **[size](Classes/structllarp_1_1AlignedBuffer.md#function-size)**() |

**Public Attributes inherited from [llarp::AlignedBuffer< 32 >](Classes/structllarp_1_1AlignedBuffer.md)**

|                | Name           |
| -------------- | -------------- |
| constexpr size_t | **[SIZE](Classes/structllarp_1_1AlignedBuffer.md#variable-size)**  |


## Public Functions Documentation

### function IdentitySecret

```cpp
inline IdentitySecret()
```


### function IdentitySecret

```cpp
explicit IdentitySecret(
    const IdentitySecret & 
) =delete
```

no copy constructor 

### function IdentitySecret

```cpp
explicit IdentitySecret(
    const byte_t * 
) =delete
```


### function LoadFromFile

```cpp
bool LoadFromFile(
    const fs::path & fname
)
```

load service node seed from file 

### function ToString

```cpp
inline std::string_view ToString() const
```


-------------------------------

Updated on 2023-01-09 at 16:43:38 +0000