Closed dusanjp closed 2 years ago
The custompreset used in this validation is:
`privateKeySecurityMode: PROMPT_MAIN
#mainPrivateKey: 8B7B3769C2D1CD6B82E01AE6B5B0CC6723FB9ADEE5E70B98580C942FAA75D7A4
mainPublicKey: B473A112CCFFBB60E9A816DC86D97D4C41CED0D2067A1A105313A63E39E3BD5A
Until v1.1.3, the above problems have not occurred.
@fboucquez I investigated the issue. The error happens in this line: https://github.com/fboucquez/symbol-bootstrap/blob/dev/src/service/BootstrapAccountResolver.ts#L57
I was able to fix it by copy same method isValidPrivateKey
into BootstrapAccountResolver and replace CommandUtils.isValidPrivateKey
with BootstrapAccountResolver.isValidPrivateKey
Not sure what is cause but would be good to check other prompts with validation too.
Thanks @dusanjp for reporting this issue.
@cryptoBeliever, thanks for the suggestion! It's one of those ugly circular dependencies that are hard to detect, related to how imports work, if the files import more than it should. Could you have a look at pr #379 ?
Hello, @fboucquez I missed your comment. I've checked, and I'm able to:
with strategy PROMPT_MAIN :+1: :+1:
When with bootstrap v1.1.4 renewCertificates does not work properly on nodes built using "privateKeySecurityMode: PROMPT_MAIN"![image](https://user-images.githubusercontent.com/62555389/154819251-1d15dc90-7021-4d48-bf90-01b6f4dd0ae3.png)
Also, if "privateKeySecurityMode: PROMPT_MAIN" is used and built new node with config / start is executed, an error will be issued and the process will end.![image](https://user-images.githubusercontent.com/62555389/154819485-d521a669-823a-4b5c-ba9f-ecb37460028d.png)