jaros1 / Money-Network

Demo with complementary and alternative money. Implemented in ZeroNet and AngularJS. Focus on privacy, encryption, max data in client and min data on ZeroNet. Work in progress.
GNU General Public License v2.0
4 stars 4 forks source link

API - backup message #304

Open jaros1 opened 6 years ago

jaros1 commented 6 years ago

Could be nice with a integrated MN backup (MN and wallets).

jaros1 commented 6 years ago

Add backup/restore checkboxes to W2 permission list "Grant MoneyNetwork session permission to". Add confirm backup/restore checkbox to W2. See https://github.com/jaros1/Money-Network-W2/issues/51 Add backup/restore permission checkboxes

jaros1 commented 6 years ago

Added json messages request_wallet_ls, wallet_ls and restore_wallet_ls to MoneyNetworkAPI.

Added "Wallets localStorage" to Account export options: screenshot from 2018-01-27 06-33-41

Sending request_wallet_ls request to w2. Receiving "Unknown msgtype request_wallet_ls" error message: screenshot from 2018-01-27 06-36-44

jaros1 commented 6 years ago

First íntegrated backup with wallet data ok.

screenshot from 2018-01-27 08-43-55

jaros1 commented 6 years ago

Adding import option section. Allow the user to see and optional deselect part of import. Most important see connected and not connected wallets. Can only restore collected wallets.

screenshot from 2018-01-27 12-38-49

jaros1 commented 6 years ago

Include wallet.json file in backup/restore? No need to include file in wallet_ls message. Maybe include in restore_wallet_ls message?

jaros1 commented 6 years ago

todo: add export/import spinner + disable ng-click while exporting/importing

jaros1 commented 6 years ago

Added W2 files to wallet_backup message. Maybe better to let MN session fetch W2 files? Encryption/decryption overhead is not required for ZeroNet files. Only required for localStorage data.

jaros1 commented 6 years ago

Moved backup fileGet operations from W2 to MN session

jaros1 commented 6 years ago

OK W2 wallet restore.

127.0.0.1-1517310502471.log

jaros1 commented 6 years ago

Starting import/restore from MN: screenshot from 2018-01-30 12-29-04

W2 notifications: screenshot from 2018-01-30 12-29-19

screenshot from 2018-01-30 12-29-27

screenshot from 2018-01-30 12-29-34

jaros1 commented 6 years ago

OK. First MN+W2 backup/restore OK

jaros1 commented 6 years ago

OK. Update distributed on ZeroNet. Problem with no peer for MoneyNetworkW2 but go distributed witn vpn = netherlands. Export/import test almost OK in "netherlands". Problem with MN-W2 handshake after restore. Had to run a wallet test. Problems with "Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. The response had HTTP status code 403." error message. Not reported in W2 UI. Not reported in wallet test.

all.js:143663 Uncaught TypeError: W2Service.z_wrapper_notification is not a function at z_wrapper_notification (all.js:143663) at all.js:143878 at all.js:137574 at all.js:67015 at flush (all.js:117926) at Item.run (all.js:116990) at drainQueue (all.js:116960)

jaros1 commented 6 years ago

Lost LS data in "torando". Restored MN and W2 from backup. All data was restored but had to do a number of wallet tests from MN before correct MN-W2 handshake after restore ...

Add a restored message to MN. MN should test wallets integration after restore.

jaros1 commented 6 years ago

Changed MN import. Now using page reload instead of log out + log in. No problem with MN-W2 handshake after restore.

screenshot from 2018-02-03 17-03-40

screenshot from 2018-02-03 17-03-45

jaros1 commented 6 years ago

todo: add export/import spinner + disable ng-click while exporting/importing