From 8f66750d07c62fe45927336e4dc6215312c313c2 Mon Sep 17 00:00:00 2001 From: Fabian Vogelsteller Date: Tue, 28 Mar 2017 16:08:37 +0200 Subject: [PATCH] imporved encryption API --- docs/web3-eth-accounts.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/web3-eth-accounts.rst b/docs/web3-eth-accounts.rst index 3adfb7c..ac92397 100644 --- a/docs/web3-eth-accounts.rst +++ b/docs/web3-eth-accounts.rst @@ -365,7 +365,7 @@ Example .. code-block:: javascript web3.eth.accounts.encrypt('0x4c0883a69102937d6231471b5dbb6204fe5129617082792ae468d01a3f362318', 'test!$@'); - > "0b5dbb6204fe512x4c0883a69102937d62314719617082792x4c0883a69102937d6231471ae468d01a3f362318" + > {"address":"4bf2a80d5c7b337da05b446081f95d0a34f79e7f","Crypto":{"cipher":"aes-128-ctr","ciphertext":"acfe42eed2d102e9bd2383c5c3f9bfdcb346a152dd7b9a3d18bab270f323f683","cipherparams":{"iv":"22cb99fa11a257f3c5b7d19ddb8bb5a4"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":261144,"p":1,"r":5,"salt":"81e332698874fc168bfde32f1529648df2fb5d9b2494e7c418ff563f18cbce86"},"mac":"0e82211205dcfb8deaff19e8433f9e966f2d72c488ac54b0b4f6ab1cf594a542"},"id":"e1268f6b-1220-4f7a-a6de-f2ad695831dc","version":3} @@ -400,7 +400,7 @@ Example .. code-block:: javascript - web3.eth.accounts.decrypt('0b5dbb6204fe512x4c0883a69102937d62314719617082792x4c0883a69102937d6231471ae468d01a3f362318', 'test!$@'); + web3.eth.accounts.decrypt({"address":"4bf2a80d5c7b337da05b446081f95d0a34f79e7f","Crypto":{"cipher":"aes-128-ctr","ciphertext":"acfe42eed2d102e9bd2383c5c3f9bfdcb346a152dd7b9a3d18bab270f323f683","cipherparams":{"iv":"22cb99fa11a257f3c5b7d19ddb8bb5a4"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":261144,"p":1,"r":5,"salt":"81e332698874fc168bfde32f1529648df2fb5d9b2494e7c418ff563f18cbce86"},"mac":"0e82211205dcfb8deaff19e8433f9e966f2d72c488ac54b0b4f6ab1cf594a542"},"id":"e1268f6b-1220-4f7a-a6de-f2ad695831dc","version":3}, 'test!$@'); > "0x4c0883a69102937d6231471b5dbb6204fe5129617082792ae468d01a3f362318"