This prevents the shell user from injecting input as if it were coming
from an existing input device, which in turn makes it easier for malware
/ abuse analysis to detect when someone is injecting input via the
command line vs a real user using a device.
(cherrypick of 95637eb2a332b9a09914b1bf32c10fccfba4a175.)
Bug: 30861057
Test: ran getevent, saw correct output, played with device
Change-Id: Ib53eea1b7767f25510b5d36fe6109101a9fad8e0
- Deal with some signedness issues
- Deal with some size issues
- Deal with NULL pointer issues
- Deal with some -Wunused issues
Change-Id: I1479dd90d690084491bae3475f2c547833519a57
This cleans up most of the size-related problems in system/core.
There are still a few changes needed for a clean 64-bit build,
but they look like they might require changes to things like the
fastboot protocol.
Change-Id: I1560425a289fa158e13e2e3173cc3e71976f92c0
Fixed a bug printing the event value when using labels.
Stop trying to print the available codes for EV_SYN because
we cannot actually query them. EVIOCGBIT(0, size) is a special
case that returns the set of events that are supported, and
EV_SYN == 0.
Change-Id: Iea086ba24300ca0815e4814a3bc5ff60756612c2
Added -l argument to print labels for event types, codes and values.
Added -i argument to print all device info.
Added support for printing input properties.
Change-Id: I3cacb716dbc38f50217b9dfc24ba44d08f352603
Add new -p option to easily get the output showing which events are reported by the devices.
Improve the reported events output a bit by including a name for each event type.
Extend help text to include a description of each options, so I don't have to look in the source code next time. :)