I think every OS should ask you to press a freshly generated sequence of keys when connecting a keyboard to prevent BadUSB attacks. Does any system do this?
That would break credit card readers, barcode scanners, and special purpose keyboards (like video workstations).
I suppose you could rely on a binary code, where the user is instructed to press any two keys to repeat the code, or if there is only one key (or it's a barcode scanner), to enter the same input multiple times, separated by long and short pauses.
Still seems like it would be difficult for the average user.
That would break credit card readers, barcode scanners, and special purpose keyboards (like video workstations).
I suppose you could rely on a binary code, where the user is instructed to press any two keys to repeat the code, or if there is only one key (or it's a barcode scanner), to enter the same input multiple times, separated by long and short pauses.
Still seems like it would be difficult for the average user.