buttplug-csharp icon indicating copy to clipboard operation
buttplug-csharp copied to clipboard

Implement a UUID of sorts for devices

Open bnm12 opened this issue 8 years ago • 1 comments

Having a better identifier for devices would be really nice as this would allow developers to better track when a specific device was found in a scan, when that device dropped and when it was rediscovered. This would also allow things like persisting the UUID across app restarts, reboots, even cloud sync to other hosts for that matter. Allowing the developer to have a settings page of sorts where you select the device you want to use for the app, and then from a user perspective never having to worry about scanning for and selecting your chosen device when you wanted to use your app the next time, the app would simply be able to take the persisted UUID from last time and look for that device again automatically.

In the spirit of preserving privacy I suggest implementing this using something along the lines of UUID = md5(<DeviceType><Device serial>) That way the same device should always get the same UUID without ever exposing its real serial to anyone other than the server which has it anyway. I've included <DeviceType> in there to try to avoid the unlikely case of a user owning 2 devices from separate brands/models which has the exact same serial getting any issues.

bnm12 avatar Jan 18 '18 20:01 bnm12

From Discord:

How about picking your own password for the server, which you can input on all servers you have and then having the hash function be md5(pass<DeviceType><trueID>word) or similar that would only allow servers you've put your keyphrase into to generate comparable hashes

That would work. Although it does introduce a UI problem of how you put the phrase in. But we could generate a new random sting on first start and have somewhere you can change it to sync servers up...

Yeah I'd go for path of least resistance and just asume that a initial random sting will cover 80+% of all usecases And the few people who has a multi-host setup will only have to put in the passphrase once on every device since it's handled by the server, so 5 extra secs after initial setup

blackspherefollower avatar Jan 18 '18 21:01 blackspherefollower

Moving to client only impl. Marking wontfix and closing.

qdot avatar Dec 27 '22 21:12 qdot