Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for using AWS encrypted BLS key files #2650

Merged
merged 2 commits into from
Apr 1, 2020

Conversation

coolcottontail
Copy link
Contributor

@coolcottontail coolcottontail commented Mar 31, 2020

Added support for using AWS encrypted BLS key files... There are two ways to use it:

  1. use command line option : -aws_encrypted_blskey [BLS_KEY_FILE]
  2. put all bls key files (.bls) under .hmy/blskeys/.bls and use multi bls key

Also the aws credentials are needed to use aws CMK to decrypt the bls key files. Aws credentials are a JSON string passed through stdin when the program runs, like below:

 echo "{\"aws-access-key-id\":\"AKIAZRWVEKULJHTOQ45I\", \"aws-secret-access-key\":\"xxxxxxxxxxxxxxxxxxxxxxxxxxxx\", \"aws-region\":\"us-east-1\"}"
 |  ./bin/harmony -aws_blskey 812db0d4ca7c74b587eddf11ae820d9909f0783b8ad17f40d828e0017ad35fe9f194564927e1819bfc682e25099e7f83.bls

or put all bls key files under .hmy/blskeys/

ls .hmy/blskeys/
04c892ac4d7fcc447187f66a8ca2cbd507d2b60d789029e1653758619cb8296731f344eda5275419e4f34e4ed3e9ea82.bls
812db0d4ca7c74b587eddf11ae820d9909f0783b8ad17f40d828e0017ad35fe9f194564927e1819bfc682e25099e7f83.bls

@coolcottontail coolcottontail requested a review from LeoHChen March 31, 2020 18:34
@fxfactorial
Copy link
Contributor

@coolcottontail sorry, seems like merge conflicts now, can you fix please.

cmd/harmony/main.go Outdated Show resolved Hide resolved
cmd/harmony/main.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
internal/blsgen/lib.go Outdated Show resolved Hide resolved
Copy link
Contributor

@fxfactorial fxfactorial left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

excellent, thank you

@fxfactorial fxfactorial merged commit a6929dd into harmony-one:master Apr 1, 2020
fxfactorial added a commit that referenced this pull request Apr 2, 2020
* Added support for using AWS encrypted BLS key files (#2650)

* added bls support, cleaned the code

* fixed code per review

* [build] fix the release action for static build

Signed-off-by: Leo Chen <leo@harmony.one>

* [build] remove double / in FOLDER

Signed-off-by: Leo Chen <leo@harmony.one>

* [blsgen] LoadFromKey with passphrase more robustly (#2675)

* [project] Remove txgen, prefer stack based init & map literals (#2678)

* [project] Remove unused internal memprofiling, profiling, metrics service (#2679)

* [project] Remove unused internal memprofiling, profiling

* [internal] Unused attack package

* [internal] More dead metrics related code

* [offchain] Forgot removal of ! which did not write the reward-per-key to work (#2681)

* [project] Fix first round issue from static analysis check (#2682)

* RPC for staking txns and txns history queries (#2554)

* staking txn. look up by hash fix on api backend rawdb storage

* node explorer staking txn 'history' RPC layer support

* fix unit test

* add error log when explorer node db instance cannot be fetched

* revert unwanted merge changes during rebase

* use already encoded tx message fields for get staking txn rpc

* update explorer node storage service for staking txns

* use hex string for staking transaction data field

* revert transaction pool apiv1 changes

* [blockchain] More info in failed validator voting power update (#2685)

Co-authored-by: coolcottontail <50373379+coolcottontail@users.noreply.github.com>
Co-authored-by: Leo Chen <leo@harmony.one>
Co-authored-by: Edgar Aroutiounian <edgar.factorial@gmail.com>
Co-authored-by: Jong Hyuck Won <denniswon@users.noreply.github.com>
fxfactorial added a commit that referenced this pull request Apr 4, 2020
* Merge master t3 0402 (#2686)

* Added support for using AWS encrypted BLS key files (#2650)

* added bls support, cleaned the code

* fixed code per review

* [build] fix the release action for static build

Signed-off-by: Leo Chen <leo@harmony.one>

* [build] remove double / in FOLDER

Signed-off-by: Leo Chen <leo@harmony.one>

* [blsgen] LoadFromKey with passphrase more robustly (#2675)

* [project] Remove txgen, prefer stack based init & map literals (#2678)

* [project] Remove unused internal memprofiling, profiling, metrics service (#2679)

* [project] Remove unused internal memprofiling, profiling

* [internal] Unused attack package

* [internal] More dead metrics related code

* [offchain] Forgot removal of ! which did not write the reward-per-key to work (#2681)

* [project] Fix first round issue from static analysis check (#2682)

* RPC for staking txns and txns history queries (#2554)

* staking txn. look up by hash fix on api backend rawdb storage

* node explorer staking txn 'history' RPC layer support

* fix unit test

* add error log when explorer node db instance cannot be fetched

* revert unwanted merge changes during rebase

* use already encoded tx message fields for get staking txn rpc

* update explorer node storage service for staking txns

* use hex string for staking transaction data field

* revert transaction pool apiv1 changes

* [blockchain] More info in failed validator voting power update (#2685)

Co-authored-by: coolcottontail <50373379+coolcottontail@users.noreply.github.com>
Co-authored-by: Leo Chen <leo@harmony.one>
Co-authored-by: Edgar Aroutiounian <edgar.factorial@gmail.com>
Co-authored-by: Jong Hyuck Won <denniswon@users.noreply.github.com>

* [validator] Hide one field from JSON (#2705)

* [rpc] Show both latest header of beacon chain and shard chain (#2714)

Co-authored-by: Leo Chen <leo@harmony.one>
Co-authored-by: coolcottontail <50373379+coolcottontail@users.noreply.github.com>
Co-authored-by: Edgar Aroutiounian <edgar.factorial@gmail.com>
Co-authored-by: Jong Hyuck Won <denniswon@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants