MinaProtocol / mina

Mina is a cryptocurrency protocol with a constant size blockchain, improving scaling while maintaining decentralization and security.
https://minaprotocol.com
Apache License 2.0
1.99k stars 527 forks source link

Node wallet format is not well supported on low memory devices (such as mobile phones) #8364

Open Comdex opened 3 years ago

Comdex commented 3 years ago

https://github.com/MinaProtocol/mina/blob/1b0be2c3b1eadb0f51814410b9e906275a6de4d4/src/lib/secrets/secret_box.ml#L118

I am looking for a solution that can be decrypted or encrypted into a node wallet format on the phone. The node wallet uses the sodium encryption API where the memlimit parameter specified for the password hash will require a lot of memory to calculate, which will make it difficult to decrypt on the phone.

I also tried to use the smaller memlimit parameter to generate the node wallet format on mobile, but found that when the node imported the wallet, the memlimit parameter was not read from the wallet file, but was specified in the code, this seems like a bug, right? Maybe we need to improve the wallet format of the node.

shimkiv commented 1 year ago

@nholland94 can you please take a look when time allows.