I believe modern Thunderbolt already has this sort of cryptographic device authentication, which means not only physical access but at least a bit of reverse engineering skill, a much higher barrier than knowing their keyboard model.
https://www.phoronix.com/scan.php?page=news_item&px=Linux-5....
I believe the major missing piece for desktop Linux at this point is that many input devices (including my own) are USB based. Without a way for the device to cryptographically attest its identity, you either have to accept vulnerability from wired external devices during boot or do without input until user space has been started.
Edit: My mistake. It appears that it was opt-in as of January, will become on-by-default at some point in the future, and only blocks devices during boot and while the screen is locked. It appears to trust all devices plugged into it once you've logged in. (https://www.forbes.com/sites/leemathews/2019/01/07/google-sh...)
For linux you can actually require USB devices to be authorized first by changing a few kernel settings.
A friend of mine wrote a few shellscripts a few years ago to do exactly that:
https://git.quitesimple.org/usbfilter/tree/
As you can see it's something that's very simple to do, there's just no good "normal user" UI for it.