[−][src]Struct safe_core::client::account::Account
Object representing the User Account information on the network.
Fields
maid_keys: ClientKeys
The User Account Keys.
access_container: MDataInfo
The user's access container.
config_root: MDataInfo
The user's configuration directory.
root_dirs_created: bool
Set to true
when all root and standard containers
have been created successfully. false
signifies that
previous attempt might have failed - check on login.
Implementations
impl Account
[src]
pub fn new(maid_keys: ClientKeys) -> Result<Self, CoreError>
[src]
Creates new Account with a provided set of keys.
pub fn encrypt(&self, password: &[u8], pin: &[u8]) -> Result<Vec<u8>, CoreError>
[src]
Symmetrically encrypts Account using User's credentials.
Credentials are passed through key-derivation-function first.
pub fn decrypt(
encrypted_self: &[u8],
password: &[u8],
pin: &[u8]
) -> Result<Self, CoreError>
[src]
encrypted_self: &[u8],
password: &[u8],
pin: &[u8]
) -> Result<Self, CoreError>
Symmetrically decrypts Account using User's credentials.
Credentials are passed through key-derivation-function first.
pub fn generate_network_id(
keyword: &[u8],
pin: &[u8]
) -> Result<XorName, CoreError>
[src]
keyword: &[u8],
pin: &[u8]
) -> Result<XorName, CoreError>
Generates User's Identity for the network using supplied credentials in a deterministic way. This is similar to the username in various places.
Trait Implementations
impl Clone for Account
[src]
impl Debug for Account
[src]
impl<'de> Deserialize<'de> for Account
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl PartialEq<Account> for Account
[src]
impl Serialize for Account
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl StructuralPartialEq for Account
[src]
Auto Trait Implementations
impl RefUnwindSafe for Account
impl Send for Account
impl Sync for Account
impl Unpin for Account
impl UnwindSafe for Account
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> CloneAny for T where
T: Clone + Any,
T: Clone + Any,
fn clone_any(&self) -> Box<dyn CloneAny + 'static>
fn clone_any_send(&self) -> Box<dyn CloneAny + 'static + Send> where
T: Send,
T: Send,
fn clone_any_sync(&self) -> Box<dyn CloneAny + 'static + Sync> where
T: Sync,
T: Sync,
fn clone_any_send_sync(&self) -> Box<dyn CloneAny + 'static + Sync + Send> where
T: Send + Sync,
T: Send + Sync,
impl<T> DebugAny for T where
T: Any + Debug,
T: Any + Debug,
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> UnsafeAny for T where
T: Any,
T: Any,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,