* added the removed RPC delete account to accounts.go and the rpc in proto
* reverted the 3 unit tests namely the failed derived delete, no pub keys provided and the successful imported account with provided public keys; also brought back the createImportedWalletWithAccounts back in wallet_test.go
* strong password defined elsewhere- removed
* Update validator/rpc/accounts_test.go
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
* added PublicKeys Nil test case
* changed ss to s. ss was a bad name inthe first place
* goimports -w root
* fixed the goimports before running the proto scripts, also changed the deleterequest variable to PublicKeysToDelete
* removed unneeded comment
* added test case for derived, changed delete account to be for both imported and derived
* gofmt
* unrelated files
* unrelated files
* unrelatedfiles restored
* revert unrelated files
* changed the last ss
* adding slashign endpoints
* adding the rpc export and import funcs, still need more testing and add unit tests
* added import slashing unit test
* clean up
* remove less
* Update proto/validator/accounts/v2/web_api.proto
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update proto/validator/accounts/v2/web_api.proto
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update proto/validator/accounts/v2/web_api.proto
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update proto/validator/accounts/v2/web_api.proto
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* camelCase Proto
* update slashing_protection_json
* update proto
* register in validator/rpc/gateway
* removed the server db creation, the validator cannot begin with a null db
* round trip test
* gofmt
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
* Update validator/rpc/slashing.go
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* recover wallet rpc support - first attempt
* removed redundant check
* separate createwallet into imported and derived. Recover is derived
* added unit test for recover. Recover is the createWallet for derived
* so proto does CamelCase!
* fixed issues related to unit testing
* expose ValidateMnemonic from accounts to be used by the rpc module
* added Mnemonic25Support and test to ensure it is not et is not empty
* added skipMnemonic25thword support and unit test
* Update proto/validator/accounts/v2/web_api.proto
Proper naming convention
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* ran goimports,changed variable to SkipMnemonic_25ThWord
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* Update validator/rpc/wallet.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* fixed variable and text msgs naming convention as per the review
* added unit test for strong password on recover
* Update proto/validator/accounts/v2/web_api.proto
Co-authored-by: Nishant Das <nish1993@hotmail.com>
* Update validator/rpc/wallet.go
Co-authored-by: Nishant Das <nish1993@hotmail.com>
* goimports -w on root proto
* added comments after exposing ValidateMnemonic to by used by rpc.RecoverWallet
* language should be case insensitive
* need to goimports before update protobuf scripts
* Update validator/rpc/wallet.go
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update validator/rpc/wallet.go
comments need to be consistant
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update validator/rpc/wallet_test.go
consistent comments
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* fix comments
* remove the skipMnemonic from rpc, just check if passphrase is empyt
* defer call to set the writePassword flag on web boarding
* gofmt
* fixed the password write test after recovering a wallet. Needed to have two defers. One to set to true then one back to false
* restore powchain.pb.go and finalized_block_root_container.pb.go
* revert beacon messages.pb.go
* revert unrelated files
* revert unrelated files
* revert unrelated files
* unlreated files
* restored the imports
* Update validator/rpc/wallet_test.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
Co-authored-by: Nishant Das <nish1993@hotmail.com>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* added the removed RPC delete account to accounts.go and the rpc in proto
* reverted the 3 unit tests namely the failed derived delete, no pub keys provided and the successful imported account with provided public keys; also brought back the createImportedWalletWithAccounts back in wallet_test.go
* strong password defined elsewhere- removed
* Update validator/rpc/accounts_test.go
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
* added PublicKeys Nil test case
* changed ss to s. ss was a bad name inthe first place
* goimports -w root
* fixed the goimports before running the proto scripts, also changed the deleterequest variable to PublicKeysToDelete
* removed unneeded comment
* added test case for derived, changed delete account to be for both imported and derived
* gofmt
* unrelated files
* unrelated files
* unrelatedfiles restored
* revert unrelated files
* changed the last ss
* restore imports
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Add a tool to split a series of mnemonic keys into distinct wallets
* split func
* keysplit tool
* gaz/viz
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Use a bolt cursor instead of bucket.ForEach, exit early when applicable
* Refactor to reuse the same code
* gofmt
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
* Update rules_go and fix proto conflicts
* gaz
* Update generated code
* more emptypb fixes
* gaz
Co-authored-by: Victor Farazdagi <simple.square@gmail.com>
* begin a simpler pruning process
* shorter pruning
* pass all pruning tests
* passing tests
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
* Add metrics per keys for next scheduled attestation and proposal
* Found a better place where to update the counters
* Wrap with emitAccountMetrics flag
* refactor / move waiting for activation updates
* Commentary
* Update test to follow the full code path
* gofmt and goimports
* manual imports fixes
* Apply suggestions from code review
typo fixes
* Remove redundant handleAccountsChanged and chan. Thanks @nisdas
* var sub = to sub :=
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
* validator cmd
* imports
* more imports
* e2e viz
* alias
* use native alias
* add actual
* fix macro
* work on fix e2e
* add viz
* gaz
Co-authored-by: Preston Van Loon <preston@prysmaticlabs.com>
* Make 1 occurence of 'foo', 'bar' and 'fizz!'
* Make 1 occurence of 'merkleizing list that is too large, over limit' string
* Limit password occurrences
* Make only 1 occurence of 'strongPass'
* Limit testMnemonic occurrences
* Limit expected epoch error messages
* Rename errors and use constant
* Update bazel dependencies
Co-authored-by: Radosław Kapka <rkapka@wp.pl>
* Update to go 1.16
* Also update go.mod
* rm go.sum then run go mod tidy
* go mod tidy with go 1.16
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Added ordered option to graffiti file
* Updated validator to use Ordered graffiti
* Track graffiti ordered index in db
* Update `ordered` to only emit each graffiti once
Co-authored-by: pinglamb <pinglambs@gmail.com>
* initial implementation
* remove listening for changes from wallet creation
* goimports
* test fix
* more goimports
* listen for changes when initializing wallet through gRPC
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
* Use ValidtorIndex across Prysm. Build ok
* First take at fixing tests
* Clean up e2e, fuzz... etc
* Fix new lines
* Update beacon-chain/cache/proposer_indices_test.go
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update beacon-chain/core/helpers/rewards_penalties.go
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update beacon-chain/core/helpers/shuffle.go
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Update validator/graffiti/parse_graffiti_test.go
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* Raul's feedback
* Fix downcast int -> uint64
* Victor's feedback
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
* Use types.CommitteeIndex
* Go fmt
* Update validator pkg
* Fix e2e
* Happy fuzz tests
* Sync with upstream ethereumapi
* Go mod tidy
Co-authored-by: Raul Jordan <raul@prysmaticlabs.com>
* include migration and logic for stopping early in slashing protection checks
* remove commented code
* extract methods
* migration logic tested up
* migration up and down tests
* Update validator/db/kv/attester_protection.go
Co-authored-by: terence tsao <terence@prysmaticlabs.com>
* added in pruning and batched migrations
Co-authored-by: Victor Farazdagi <simple.square@gmail.com>
Co-authored-by: terence tsao <terence@prysmaticlabs.com>