Add init_api_secure function (#206)

* adding initial version of init_secure_api

* rustfmt

* fix ECDH algo

* rustfmt

* trying to figure out best way of doing encryption

* refactor secure requests and responses into json-rpc responses, with base64 payload for encrypted messages

* rustfmt

* return proper errors from encrypted api, include tests covering encrypted API error cases

* rustfmt

* add test for normal error (unencrypted)

* rustfmt

* change ports for test, add foreign listener to V2 sanity tests, add ability to select owner api port via command line

* rustfmt

* turn it to 11

* explicit teardown after rpc tests

* update tests with explicit teardowns

* update tests to perform explicit teardown

* fix warnings, ensure all tests teardown

* log output to diagnose CI windows build failures

* disable owner api doctests on windows

* rustfmt
This commit is contained in:
Yeastplume
2019-08-19 13:05:21 +01:00
committed by GitHub
parent 62d976f9ef
commit a58cae651e
33 changed files with 1224 additions and 294 deletions
+2 -1
View File
@@ -30,7 +30,7 @@ use grin_wallet_impls::DefaultLCProvider;
use grin_wallet_util::grin_keychain::ExtKeychain;
mod common;
use common::{execute_command, initial_setup_wallet, instantiate_wallet, setup};
use common::{clean_output_dir, execute_command, initial_setup_wallet, instantiate_wallet, setup};
/// command line tests
fn command_line_test_impl(test_dir: &str) -> Result<(), grin_wallet_controller::Error> {
@@ -482,6 +482,7 @@ fn command_line_test_impl(test_dir: &str) -> Result<(), grin_wallet_controller::
// let logging finish
thread::sleep(Duration::from_millis(200));
clean_output_dir(test_dir);
Ok(())
}