EGIS 1C7A:0582 support for Samsung Galaxy Book2 Pro
Edit: Originally I think I mixed this device up with the existing ELAN devices, but after looking at it a bit then it seems it is an EGIS device and completely separate from the ELAN devices I had mentioned before. Tweaked the text here a little bit accordingly...
So I have started to reverse engineer how the EGIS 1C7A:0582
works on my Samsung Galaxy Book2 Pro (NP950XED-KA2SE) using a guest Windows environment in QEMU with Wireshark + usbmon
and have even put together the embryo of a PoC in Python which you can find here: https://github.com/joshuagrisham/galaxy-book2-pro-linux/tree/main/fingerprint
This is a MOC device which I had originally mistaken to be ELAN but found that it definitely does not seem to work exactly the same as https://gitlab.freedesktop.org/libfprint/libfprint/-/blob/master/libfprint/drivers/elanmoc/elanmoc.c or the yet-to-be-merged !330 (elanmoc2).
Specifically I feel that this 0582 device actually seems a bit more simple in terms of which events need to be sent to the device, just that maybe there is a bit more complexity within the messages themselves (with some check bytes that need to be sorted out and generating fingerprint identifiers/signatures etc)?
Here is the output of lsusb
(device 024 just because I have been hacking with it a bit and did not yet restart since ;) ):
$ lsusb -v -d 1c7a:0582
Bus 003 Device 024: ID 1c7a:0582 LighTuning Technology Inc. ETU905A80-E
Couldn't open device, some information will be missing
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 255 Vendor Specific Class
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x1c7a LighTuning Technology Inc.
idProduct 0x0582
bcdDevice 11.81
iManufacturer 1 EGIS
iProduct 2 ETU905A80-E
iSerial 3 0E7828PBS393
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x0027
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xa0
(Bus Powered)
Remote Wakeup
MaxPower 100mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 3
bInterfaceClass 255 Vendor Specific Class
bInterfaceSubClass 0
bInterfaceProtocol 0
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x02 EP 2 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 5
There are a few open issues/limitations with my PoC driver which you can read about here if you like: https://github.com/joshuagrisham/galaxy-book2-pro-linux/blob/main/fingerprint/readme.md
Unless there are any objections, I thought to try and take a stab at building and/or (if on the miracle chance it will work out) extending/modifying one of these two existing "elanmoc" libfprint drivers now that I have successfully created a method which generates the payload's "check bytes" in the right way.
Any other tips or feedback otherwise?