summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorFabian Henneke <fabian@henneke.me>2019-08-21 11:17:59 +0200
committerYu Watanabe <watanabe.yu+github@gmail.com>2019-09-06 19:23:58 +0200
commitd45ee2f31a8358db0accde2e7c81777cedadc3c2 (patch)
tree244ca5d8ff1146aa03ab1029b8ba52983ec38be7 /test
parentpstore: fix use after free (diff)
downloadsystemd-d45ee2f31a8358db0accde2e7c81777cedadc3c2.tar.xz
systemd-d45ee2f31a8358db0accde2e7c81777cedadc3c2.zip
udev: Add id program and rule for FIDO security tokens
Add a fido_id program meant to be run for devices in the hidraw subsystem via an IMPORT directive. The program parses the HID report descriptor and assigns the ID_SECURITY_TOKEN environment variable if a declared usage matches the FIDO_CTAPHID_USAGE declared in the FIDO CTAP specification. This replaces the previous approach of whitelisting all known security token models manually. This commit is accompanied by a test suite and a fuzzer target for the descriptor parsing routine. Fixes: #11996.
Diffstat (limited to 'test')
-rw-r--r--test/fuzz/fuzz-fido-id-desc/crash01
-rw-r--r--test/fuzz/fuzz-fido-id-desc/crash11
-rw-r--r--test/fuzz/fuzz-fido-id-desc/report0bin0 -> 71 bytes
-rw-r--r--test/fuzz/fuzz-fido-id-desc/report1bin0 -> 34 bytes
4 files changed, 2 insertions, 0 deletions
diff --git a/test/fuzz/fuzz-fido-id-desc/crash0 b/test/fuzz/fuzz-fido-id-desc/crash0
new file mode 100644
index 0000000000..e066656502
--- /dev/null
+++ b/test/fuzz/fuzz-fido-id-desc/crash0
@@ -0,0 +1 @@
+Ì \ No newline at end of file
diff --git a/test/fuzz/fuzz-fido-id-desc/crash1 b/test/fuzz/fuzz-fido-id-desc/crash1
new file mode 100644
index 0000000000..aef3e18335
--- /dev/null
+++ b/test/fuzz/fuzz-fido-id-desc/crash1
@@ -0,0 +1 @@
+øûøûûÜ \ No newline at end of file
diff --git a/test/fuzz/fuzz-fido-id-desc/report0 b/test/fuzz/fuzz-fido-id-desc/report0
new file mode 100644
index 0000000000..48757cba68
--- /dev/null
+++ b/test/fuzz/fuzz-fido-id-desc/report0
Binary files differ
diff --git a/test/fuzz/fuzz-fido-id-desc/report1 b/test/fuzz/fuzz-fido-id-desc/report1
new file mode 100644
index 0000000000..b70b7fb871
--- /dev/null
+++ b/test/fuzz/fuzz-fido-id-desc/report1
Binary files differ