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

KeyHandleMatcher might theoretically not handle re-used dev_refs correctly #47

Closed
ttaubert opened this issue Sep 21, 2017 · 1 comment
Closed

Comments

@ttaubert
Copy link
Contributor

From KeyHandleMatcher.update():

// TODO In theory, it might be possible to replace a token between
// `update()` calls while reusing the device_ref/path. We should refactor
// this part of the code and probably merge the KeyHandleMatcher into the
// DeviceMap and Monitor somehow so that we query key handle/token
// assignments right when we start tracking a new device.

I'd certainly favor coming up with a nicer structure for the KHM, DevMap, and Monitor that fits the runloop we have better, yet still maintains some separation of concern.

@ttaubert
Copy link
Contributor Author

I'd probably favor a solution like in #52, that would allow us to get rid of the KHM completely. Haven't thought about how easy that is with either Windows/Linux. macOS doesn't use the KHM anymore.

ttaubert pushed a commit to ttaubert/u2f-hid-rs that referenced this issue Nov 20, 2017
ttaubert pushed a commit to ttaubert/u2f-hid-rs that referenced this issue Nov 20, 2017
ttaubert added a commit that referenced this issue Nov 20, 2017
Linux-part of #47: Implement per-device threads, don't use the KeyHandleMatcher
ttaubert added a commit that referenced this issue Nov 21, 2017
Remove KeyHandleMatcher, Implement per-device threads on Windows, fixes #47
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

1 participant