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

Incorrect key pulled for Electron using TCP #280

Closed
towynlin opened this issue Sep 17, 2016 · 2 comments
Closed

Incorrect key pulled for Electron using TCP #280

towynlin opened this issue Sep 17, 2016 · 2 comments
Labels

Comments

@towynlin
Copy link
Contributor

Given I have an Electron using TCP
When I run particle keys save electron-key-filename
Then I expect to receive the RSA key for the TCP server
But instead I currently receive the EC key for the UDP server

@brycekahle
Copy link
Contributor

@m-mcgowan m-mcgowan added the bug label Jan 25, 2017
@m-mcgowan
Copy link
Contributor

m-mcgowan commented Jan 26, 2017

The keys commands expects a --protocol tcp argument. So, not sure this is a bug other than missing documentation?

So the question is what to do when --protocol is not provided. Here's a few options:

  • for devices with a single protocol, default to that (current behaviour on Core/Photon/P1)
  • for devices with multiple protocol support:
    • raise an error if --protocol is not specified. This makes it clear there are multiple protocols and that the user needs to be clear which one they mean. (But this is inconvenient for the majority who never change from the default.)
    • a more friendly alternative - inspect the device to determine the current protocol in use and default to that. Only raise the error above if for some reason the protocol cannot be determined.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants