-
Notifications
You must be signed in to change notification settings - Fork 179
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
[Feature request] run the Yield Generator without a password #767
Comments
Password is used to encrypt .jmdat wallet files, so no way you can do anything without password in JM. |
I think: if a person has access to the executable script, then they have access to the code, so I'm not sure in what sense you ever have a guarantee that the code will do what you believe it will do (in this case, only sign transactions strictly increasing balance). So as @kristapsk says the only defence we have is for the secrecy of the privileged wallet information (keys) in the encrypted wallet file, not the code execution. So our security model is that we ensure it's the valid/trusted user who accesses the keys AND starts execution. Of course if the environment in which the code is executing is not safe, running Joinmarket is not safe, but if you removed password protection from starting that execution it would be a lot worse/less secure, and would require leaving the keys (or the encryption key protecting the keys :) ) in plaintext somewhere at rest. So I think this idea would only make sense if we were running the maker against a hardware wallet signer, as has been discussed before. In that scenario, I think it makes sense (and indeed, it is different from the two other main wallet use scenarios: read only, no unlock required, and spend, where unlocking is unconditionally required - it exists in a third scenario, perhaps shared with lightning and other smart contracts: open for spending, but spending constrained with limits). |
@AdamISZ Thank you for the detailed answer. It makes sense that the most viable option would be to remove the signing keys from the machine running the scripts so the topic is related to the hardware wallet support. The challenge here is that only the unmixed change (and fees) are being returned to the same mixdepth and the coinjoined amount would move to the next account. This would require the hardware wallet to check for self-payments in multiple accounts. There are two candidates which might be able to develop this in the future:
|
The Yield Generator does not ask for a password at startup if your wallet file is not encrypted. 😉 |
I think LND solves this in a nice way that would be an easy add here I think: Add a flag This makes it trivial to just pipe it into the command at the entrypoint. That way, operators who have secrets management systems like Vault can do automatic unlocking without needing to store the keys in cleartext, or the passphrase on disk (to clarify, the file path could exist on a ramfs). |
Well what do you know, totally missed that one, thanks @kristapsk ! Doesn't that solve your use-case @openom? For a budget setup you could have the passphrase on an encrypted USB key that is piped in from the systemd unit file. Keeping the passphrase and encrypted wallet on separate volumes is at least better than storing it in cleartext. |
Yes, as per what I said above :
Your idea is to finesse that a bit, it may well be of interest in some contexts, but the general principle applies. Either it's available at rest or there's interaction.
Joinmarket does not allow that; it does not even allow a password of "". Maybe you're thinking of an older version of the code? I feel like this issue stays open; it's a valid thought and ultimately quite connected with the whole idea of a hardware wallet signer. |
JoinMarket doesn't allow creating a wallet with no encryption, but it'll still open and use one just fine. It's not hard (if one has any programming experience) to figure out how to create an unencrypted wallet by calling the right functions manually. |
Yes good point (and relevant, here). |
It won't get perfect, but what about something like this @openoms
If A poor man's version of this would be to have a plaintext password stored on an USB stick that is set up in |
Was thinking about a safe way for YieldGenerator to restart safely in: openoms/joininbox#17
Question is if the Maker would not sign a transaction resulting to losing funds does it need to be password protected at all?
There could be a config option in the joinmarket.cfg to allow the Yield Generator to run (even this might be unnecessary.)
Starting the YG is an active process so no user would participate in transactions unwillingly, but could be easily automated with a systemd process as it happens in JoininBox for example: https://github.com/openoms/joininbox/blob/master/scripts/start.service.sh
The text was updated successfully, but these errors were encountered: