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

Wrong address tried to connect to other nodes #129

Closed
phmarek opened this issue Nov 27, 2020 · 4 comments
Closed

Wrong address tried to connect to other nodes #129

phmarek opened this issue Nov 27, 2020 · 4 comments

Comments

@phmarek
Copy link

phmarek commented Nov 27, 2020

I generate an address with very few rights, and pass that on so that other nodes can connect to my blockchain (via -initprivkey) and register themselves (in a stream), to be granted rights for their "own" (newly generated) address by the master node.

That works fine so far; but as soon as the "invitation" address gets revoked and a blockchain node restarted, it still tries to use that (-initprivkey) address to connect - although it "knows" that this is already invalidated, and there's another address locally available with enough rights.

This could be solved via #126 - or by having multichain checking permissions for the address it's trying to use for connect.

@gidgreen
Copy link
Contributor

First I'm not sure it knows the address has been revoked. Since it connected with this address, it might have had its connections dropped before it found out. In any event please see the handshakelocal runtime parameter:

https://www.multichain.com/developers/runtime-parameters/

Also in general please ask these sorts of questions on the Q&A:

https://www.multichain.com/qa/

@phmarek
Copy link
Author

phmarek commented Nov 27, 2020

Well, first of all I can make sure that the local Multichain knows it's gone, by waiting for the permission to be gone.

Second, even without any additional information, Multichain might (should) try to use other available private keys to connect if the current one isn't accepted.

handshakelocal is a good tip, thanks - but that depends on the caller knowing which one is the "right" key; an automated solution (like trying keys round-robin) is surely preferable. (Or #126, at least.)

@gidgreen
Copy link
Contributor

It's not really viable to round-robin all the keys in the wallet, because in some circumstances this is not information that a node will want to share with others.

@phmarek
Copy link
Author

phmarek commented Nov 29, 2020 via email

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

No branches or pull requests

2 participants