pub struct CreateWalletV0 {Show 13 fields
pub security_img: Vec<u8>,
pub security_txt: String,
pub pin: [u8; 4],
pub pazzle_length: u8,
pub send_bootstrap: bool,
pub send_wallet: bool,
pub result_with_wallet_file: bool,
pub local_save: bool,
pub core_bootstrap: BootstrapContentV0,
pub core_registration: Option<[u8; 32]>,
pub additional_bootstrap: Option<BootstrapContentV0>,
pub pdf: bool,
pub device_name: String,
}Expand description
Create Wallet Version 0, used by the API create_wallet_v0 as a list of arguments
Fields§
§security_img: Vec<u8>a vector containing the binary content of an image file that will be used at every login, displayed (on devices that can) to the user so they can check the wallet is theirs and that entering their pazzle and PIN is safe and there is no phishing attack. an attacker would redirect the user to a clone of the wallet opener app, and would try to steal what the user enters but this attacker would not possess the security_img of the user as it is only present locally in the wallet file. the image should be bigger than 150x150px. There is no need to provide more than 400x400px as it will be scaled down anyway. We accept several formats like JPEG, PNG, GIF, WEBP and more. The image should be unique to the user. But it should not be too personal neither. Do not upload face picture, this is not a profile pic. The best would be any picture that the user recognizes as unique. Please be aware that other users who are sharing the same device, will be able to see this image.
security_txt: StringA string of characters of minimum length 10. This phrase will be presented to the user every time they are about to enter their pazzle and PIN in order to unlock their wallet. It should be something the user will remember, but not something too personal. Do not enter full name, nor address, nor phone number. Instead, the user can enter a quote, a small phrase that they like, or something meaningless to others, but unique to them. Please be aware that other users who are sharing the same device, will be able to see this phrase.
pin: [u8; 4]chose a PIN code. We recommend the user to choose a PIN code they already know very well (unlock phone, credit card). The PIN and the rest of the Wallet will never be sent to NextGraph or any other third party (check the source code if you don’t believe us). It cannot be a series like 1234 or 8765. The same digit cannot repeat more than once. By example 4484 is invalid. Try to avoid birth date, last digits of phone number, or zip code for privacy concern
pazzle_length: u8For now, only 9 is supported. 12 and 15 are planned. A value of 0 will deactivate the pazzle mechanism on this Wallet, and only the mnemonic could be used to open it.
send_bootstrap: boolNot implemented yet. Will send the bootstrap to our cloud servers, if needed
send_wallet: boolNot implemented yet. Will send an encrypted Wallet file to our cloud servers, if needed. (and no, it does not contain the user’s pazzle nor PIN)
result_with_wallet_file: boolDo you want a binary file containing the whole Wallet ?
local_save: boolShould the wallet be saved locally on disk, by the LocalBroker. It will not work on a in-memory LocalBroker, obviously.
core_bootstrap: BootstrapContentV0What Broker Server to contact when there is internet and we want to sync.
core_registration: Option<[u8; 32]>What is the registration code at that Broker Server. Only useful the first time you connect to the Server. Can be None the rest of the time, or if your server does not need an Invitation.
additional_bootstrap: Option<BootstrapContentV0>Bootstrap of another server that you might use in order to connect to NextGraph network. It can be another interface on the same core server.
pdf: boolShould generate a recovery PDF containing all the information of the wallet in plain text.
device_name: Stringshort name of the device
Implementations§
Source§impl CreateWalletV0
impl CreateWalletV0
pub fn new( security_img: Vec<u8>, security_txt: String, pin: [u8; 4], pazzle_length: u8, send_bootstrap: bool, send_wallet: bool, core_bootstrap: BootstrapContentV0, core_registration: Option<[u8; 32]>, additional_bootstrap: Option<BootstrapContentV0>, pdf: bool, device_name: String, ) -> CreateWalletV0
Trait Implementations§
Source§impl Clone for CreateWalletV0
impl Clone for CreateWalletV0
Source§fn clone(&self) -> CreateWalletV0
fn clone(&self) -> CreateWalletV0
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CreateWalletV0
impl Debug for CreateWalletV0
Source§impl<'de> Deserialize<'de> for CreateWalletV0
impl<'de> Deserialize<'de> for CreateWalletV0
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<CreateWalletV0, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<CreateWalletV0, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Drop for CreateWalletV0
impl Drop for CreateWalletV0
Source§impl Serialize for CreateWalletV0
impl Serialize for CreateWalletV0
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for CreateWalletV0
impl RefUnwindSafe for CreateWalletV0
impl Send for CreateWalletV0
impl Sync for CreateWalletV0
impl Unpin for CreateWalletV0
impl UnsafeUnpin for CreateWalletV0
impl UnwindSafe for CreateWalletV0
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more