libfprint is an open source library to provide access to fingerprint scanning devices. For more info, see the libfprint project homepage.
This documentation is aimed at application developers who wish to integrate fingerprint-related functionality into their software. libfprint has been designed so that you only have to do this once - by integrating your software with libfprint, you'll be supporting all the fingerprint readers that we have got our hands on. As such, the API is rather general (and therefore hopefully easy to comprehend!), and does it's best to hide the technical details that required to operate the hardware.
This documentation is not aimed at developers wishing to develop and contribute fingerprint device drivers to libfprint.
Feedback on this API and it's associated documentation is appreciated. Was anything unclear? Does anything seem unreasonably complicated? Is anything missing? Let us know on the mailing list.
The process of enrolling a finger is where you effectively scan your finger for the purposes of teaching the system what your finger looks like. This means that you scan your fingerprint, then the system processes it and stores some data about your fingerprint to refer to later.
As an example scenario, verification can be used to implement what people would picture as fingerprint login (i.e. fingerprint replaces password). For example:
In other words, verification might be seen as a one-to-one fingerprint comparison where you know the identity of the user that you wish to authenticate, whereas identification is a one-to-many comparison where you do not know the identity of the user that you wish to authenticate.
libfprint deals with a whole variety of different fingerprint readers and the design includes considerations of compatibility and interoperability between multiple devices. Your application should also be prepared to work with more than one type of fingerprint reader and should consider that enrolled fingerprint X may not be compatible with the device the user has plugged in today.
libfprint implements the principle that fingerprints from different devices are not necessarily compatible. For example, different devices may see significantly different areas of fingerprint surface, and comparing images between the devices would be unreliable. Also, devices can stretch and distort images in different ways.
libfprint also implements the principle that in some cases, fingerprints are compatible between different devices. If you go and buy two identical fingerprint readers, it seems logical that you should be able to enroll on one and verify on another without problems.
libfprint takes a fairly simplistic approach to these issues. Internally, fingerprint hardware is driven by individual drivers. libfprint enforces that a fingerprint that came from a device backed by driver X is never compared to a fingerprint that came from a device backed by driver Y.
Additionally, libfprint is designed for the situation where a single driver may support a range of devices which differ in imaging or scanning properties. For example, a driver may support two ranges of devices which even though are programmed over the same interface, one device sees substantially less of the finger flesh, therefore images from the two device types should be incompatible despite being from the same driver. To implement this, each driver assigns a device type to each device that it detects based on its imaging characteristics. libfprint ensures that two prints being compared have the same device type.
In summary, libfprint represents fingerprints in several internal structures and each representation will offer you a way of determining the driver ID and devtype of the print in question. Prints are only compatible if the driver ID and devtypes match. libfprint does offer you some "is this print compatible?" helper functions, so you don't have to worry about these details too much.
Alternative asynchronous/non-blocking functionality will be offered in future but has not been implemented yet.
Usually the first thing you want to do is determine which fingerprint devices are present. This is done through device discovery.
Once you have found a device you would like to operate, you should open it. Refer to device operations. This section also details enrollment, image capture, and verification.
That should be enough to get you started, but do remember there are documentation pages on other aspects of libfprint's API (see the modules page).