create account

Account model, Wallet model and Security on the DEX part 1 of 2 by clockwork

View this thread on: hive.blogpeakd.comecency.com
· @clockwork ·
$21.98
Account model, Wallet model and Security on the DEX part 1 of 2
I decided to write this post because there is a lot of confusion on how the DEX handles security and what the different models mean.

Let's start this off by mentioning the basics. DEX means Decentralised Exchange. 

The key word here is DECENTRALISED. There is no central server performing authentication, no central authority that EVER sees your private keys or your wallet.

Both the reference web wallet and reference wallet application (as well as the various gateway branded versions of them) run LOCALLY on your computer.

The web wallet simply downloads a web application (the reference wallet) from the internet and then runs it locally in your browser. 

The wallet (web and standalone) then communicate DIRECTLY with the various API nodes and only SIGNED transactions  and operations are sent through the network. The signing itself takes place locally on your computer and keys are NEVER, I repeat NEVER, sent through the network.

Clear enough I think.

Now let's continue.

Wallet model is pretty much the same as any other cryptocurrency wallet (think bitcoin standard client, electrum etc.).

You choose your wallet file from your computer (which contains encrypted keys), unlock it with your password and perform transactions.

A wallet can contain multiple account entries, each with its own set of keys similar to other cryptocurrency wallets.

The main difference is that the Bitshares wallet (web or otherwise) ALSO provides exchange functionality and not just transactions.

The subtle difference is that while in other cryptos there is a 1-1 relation between Private Key and Address, in bitshares there is an "account name" (address) which abstracts this. 

In fact, each account name has 3 private key types (all of which can have multiple entries and can be changed):

An **active key** that has full access over the account (but cannot change the owner key)
An **owner key** that is the absolute master key
And a **memo key** that is used to decrypt memos in transfers

When you create an account in Wallet Model, one set of those 3 keys is randomly generated (locally) for that account and is then backed up to your wallet file and encrypted with the password you choose. Hence you need the wallet file in order to gain access to the private keys.

When you create an account in Account Model, the set of those 3 keys is derived from the password you choose through a standard one-way hashing function. This is why an auto-generated very long/complex password is auto-generated for convenience, but it allows you to regenerate those keys on the fly anywhere simply by entering your password. Still, the keys are NEVER stored or transmitted anywhere online.

However since in account model , your password corresponds to one set of keys, you can only use one account at a time.

Seeing as account keys can be changed, you can always set things up so your wallet contains multiple accounts, each of which has a set of keys derived from a password (From the Cloud Wallet tab when you select View Keys for the account in question from Settings -> Accounts). This will allow you to keep a wallet file with all your accounts and their keys encrypted but also allow cloud access for one or more of those accounts by using the seed password)

Once again, the important thing to remember is that there is NO central authority that holds your Private Keys. If you lose your wallet file, lose its password, or lose the seed password (if you're using cloud model keys) , there is NO WAY to get your private keys back.

Since there is no centralised authority, there is no Google Authenticator-type 2FA either.

If you want slightly more piece of mind, you may want to consider a multi-sig account but I'll leave that for part 2.
👍  , , , , , , , , , , , , , ,
properties (23)
authorclockwork
permlinkaccount-model-wallet-model-and-security-on-the-dex-part-1-of-2
categorybitshares
json_metadata{"tags":["bitshares","graphene"],"app":"steemit/0.1","format":"markdown"}
created2018-02-12 09:44:45
last_update2018-02-12 09:44:45
depth0
children6
last_payout2018-02-19 09:44:45
cashout_time1969-12-31 23:59:59
total_payout_value16.630 HBD
curator_payout_value5.353 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length3,743
author_reputation2,206,574,983,916
root_title"Account model, Wallet model and Security on the DEX part 1 of 2"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd0
post_id36,892,104
net_rshares2,978,998,319,136
author_curate_reward""
vote details (15)
@john-robert ·
$0.03
Good post.  And here lies the double edged sword.  Ultimate security and sovereignty over your digital assets comes at the cost of absolute responsibility.  I think it would be worth bringing up with any future core dev team whether to include some compromises in the wallet model to allow general population a "forgot my password" function.  What do you think?
👍  ,
properties (23)
authorjohn-robert
permlinkre-clockwork-account-model-wallet-model-and-security-on-the-dex-part-1-of-2-20180212t124902558z
categorybitshares
json_metadata{"tags":["bitshares"],"app":"steemit/0.1"}
created2018-02-12 12:48:51
last_update2018-02-12 12:48:51
depth1
children4
last_payout2018-02-19 12:48:51
cashout_time1969-12-31 23:59:59
total_payout_value0.028 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length361
author_reputation2,529,767,637,749
root_title"Account model, Wallet model and Security on the DEX part 1 of 2"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id36,929,007
net_rshares4,147,354,919
author_curate_reward""
vote details (2)
@clockwork ·
$0.03
"Forgot my password" automatically implies that it also exists (or can be reset) with a 3rd party/centralized entity. It pretty much defeats the whole purpose. 

Keeping your private key safe has been the key (pun intended)  instruction for ALL crypto since the beginning.  There is some confusion because bitshares' wallet also functions as an exchange(and centralised exchanges have their own auth mechanisms with 2FA and reset functionalities etc. but they do it by virtue of holding on to the private keys.

I think the system as it stands is great. What is lacking is some "ease of use" features / abstractions. For example a Trezor multisig equivalent for bitshares for people needing more security....Or a suggestion to print out your PKs and keep copies in hard form in safe locations etc.
👍  , ,
properties (23)
authorclockwork
permlinkre-john-robert-re-clockwork-account-model-wallet-model-and-security-on-the-dex-part-1-of-2-20180212t125653274z
categorybitshares
json_metadata{"tags":["bitshares"],"app":"steemit/0.1"}
created2018-02-12 12:58:06
last_update2018-02-12 12:58:06
depth2
children3
last_payout2018-02-19 12:58:06
cashout_time1969-12-31 23:59:59
total_payout_value0.028 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length797
author_reputation2,206,574,983,916
root_title"Account model, Wallet model and Security on the DEX part 1 of 2"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id36,931,017
net_rshares4,326,701,278
author_curate_reward""
vote details (3)
@john-robert ·
Good response and I agree.  My thought is that perhaps there's a way to accommodate the 5 billion people who are not at this moment willing/capable to take total control and responsibility.  Perhaps there is a way to have a similar ease of use feature a la a third party gateway with a degree of centralization for people who want to opt in to handcuffs and want a Coinbase like experience.

You seem to be going the other way and I think I agree with you.  We should focus on making it easier for people to take responsibility and not enabling them to take the easy way out.
👍  
properties (23)
authorjohn-robert
permlinkre-clockwork-re-john-robert-re-clockwork-account-model-wallet-model-and-security-on-the-dex-part-1-of-2-20180212t130421609z
categorybitshares
json_metadata{"tags":["bitshares"],"app":"steemit/0.1"}
created2018-02-12 13:04:21
last_update2018-02-12 13:04:21
depth3
children2
last_payout2018-02-19 13:04:21
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length575
author_reputation2,529,767,637,749
root_title"Account model, Wallet model and Security on the DEX part 1 of 2"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id36,932,325
net_rshares583,029,724
author_curate_reward""
vote details (1)
@resteemy ·
Congratulations, you were selected for a random upvote! Follow @resteemy and upvote this post to increase your chance of being upvoted again!
Read more about @resteemy [here](https://steemit.com/resteemy/@resteemy/introducting-resteemy).
properties (22)
authorresteemy
permlink20180212t095314529z
categorybitshares
json_metadata{}
created2018-02-12 09:53:15
last_update2018-02-12 09:53:15
depth1
children0
last_payout2018-02-19 09:53:15
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length237
author_reputation26,467,584,277
root_title"Account model, Wallet model and Security on the DEX part 1 of 2"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id36,893,771
net_rshares0