Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/html/extensions/Variables/includes/ExtVariables.php on line 198

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/html/extensions/Variables/includes/ExtVariables.php on line 198

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /var/www/html/extensions/Variables/includes/ExtVariables.php on line 198
BiometricKit.framework: Difference between revisions - iPhone Development Wiki

BiometricKit.framework: Difference between revisions

From iPhone Development Wiki
m (Cleanup)
Line 6: Line 6:


'''BiometricKit''' is the framework relating to the TouchID debuted on the iPhone 5s. The TouchID has an internal codename ''Mesa''. It is a private framework compiled only for arm64. You can also Google "Biokit.h", and from the Gist you can find the headers for the BiometricKit.framework. (You can also dump them yourselves, it is shipped with the iPhoneOS 7.0 SDK on Xcode and of course on an iPhone 5s.)
'''BiometricKit''' is the framework relating to the TouchID debuted on the iPhone 5s. The TouchID has an internal codename ''Mesa''. It is a private framework compiled only for arm64. You can also Google "Biokit.h", and from the Gist you can find the headers for the BiometricKit.framework. (You can also dump them yourselves, it is shipped with the iPhoneOS 7.0 SDK on Xcode and of course on an iPhone 5s.)
Note that if you decide to use the <tt>BiometricKit</tt> class and the <tt>BiometricKitDelegate</tt> in your own app, the app needs the entitlements of <tt>com.apple.private.biometrickit.allow</tt> and <tt>com.apple.private.bmk.allow</tt>.


== Classes ==
== Classes ==
=== BiometricKitIdentity ===
=== BiometricKitIdentity ===


<tt>BiometricKitIdentity</tt> represents the enrolled fingerprints on the device. Properties for the user-defined name and UUID are available. You can get an array of all identities with <tt>[[BiometricKit manager] identities:nil]</tt>.
<tt>BiometricKitIdentity</tt> represents the enrolled fingerprints on the device. Properties for the user-defined name and UUID are available.


=== BiometricKitMatchInfo ===
=== BiometricKitMatchInfo ===
Line 26: Line 24:
=== BiometricKitEnrollProgressCoordinates ===
=== BiometricKitEnrollProgressCoordinates ===


A <tt>BiometricKitEnrollProgressCoordinates</tt> object is suspected record to the x and y coordinates and the angle (probably in radians) of the a particular fingerprint distinguishing feature.
A <tt>BiometricKitEnrollProgressCoordinates</tt> object is suspected to record the x and y coordinates and the angle (probably in radians) of the a particular fingerprint distinguishing feature.


== Uses ==
== Uses ==
=== Querying the enrolled fingerprints ===
You can get an array of all <tt>BiometricKitIdentity</tt>'s on file with <tt>[[BiometricKit manager] identities:nil]</tt>. ''Note that this will only give you the user-defined names and UUIDs, but not the actual fingerprint characteristics as in <tt>BiometricKitEnrollProgressInfo</tt>.''
=== Getting scan results ===
=== Getting scan results ===


<tt>- (void)biometricEventMonitor:(SBUIBiometricEventMonitor *) handleBiometricEvent:(unsigned)</tt> from <tt>SBLockScreenManager</tt> would be invoked always after the screen is on and a fingerprint is registered. One exception is when the user enters the TouchID settings under <tt>Preferences.app</tt>, where the app took control of all the callbacks, and we have to lock and unlock the screen again in order to receive messages from the aforementioned callback again.
There are at least three ways you can get the scan results from the TouchID sensor.
 
==== BiometricKit manager and delegate methods ====
Simple to set up in your own apps. Note that if you decide to use the <tt>BiometricKit</tt> class and the <tt>BiometricKitDelegate</tt> in your own app, the app needs the entitlements of <tt>com.apple.private.biometrickit.allow</tt> and <tt>com.apple.private.bmk.allow</tt>.
 
==== SBLockScreenManager of SpringBoardUIServices ====
<tt>SBLockScreenManager</tt> <tt>- (void)biometricEventMonitor:(SBUIBiometricEventMonitor *) handleBiometricEvent:(unsigned)</tt> would always be invoked after the screen is on and a fingerprint is registered.
 
==== XPC ====
<tt>BiometricKitXPCClient</tt> <tt>- (void)matchResult:(BiometricKitIdentity *)result withDictionary:(NSDictionary *)dictionary</tt>
 
==== Issues after going into the TouchID settings ====
 
For some unknown reason, no further message would be called upon scanning if the user enters the TouchID settings under <tt>Preferences.app</tt>. The device has to be slept and unlocked in order to receive messages from the aforementioned methods again.
 
(If you find a workaround please edit this out. --[[User:Jdoe|Jdoe]] ([[User talk:Jdoe|talk]]) 07:06, 4 January 2014 (PST))
 
=== Enrollment ===


This issue happens if you hook up to the <tt>BiometricKitXPCClient</tt>'s <tt>- (void)matchResult:(BiometricKitIdentity *)result withDictionary:(NSDictionary *)dictionary</tt>; or if you go the good old delegate way with <tt>[BiometricKit manager]</tt>. ''I'm still trying to figure out how to revive that, if you found any way around this please do share with everyone.''
(Not investigated, but there are some methods regarding enrollment in this framework. Also refer to the <tt>BiometricKitUI.framework</tt> --[[User:Jdoe|Jdoe]] ([[User talk:Jdoe|talk]]) 07:06, 4 January 2014 (PST))


{{Navbox Frameworks}}
{{Navbox Frameworks}}

Revision as of 15:06, 4 January 2014

BiometricKit.framework
Private Framework
Availabile 7.0 – present
Class Prefix BiometricKit
Headers [headers.cynder.me]


BiometricKit is the framework relating to the TouchID debuted on the iPhone 5s. The TouchID has an internal codename Mesa. It is a private framework compiled only for arm64. You can also Google "Biokit.h", and from the Gist you can find the headers for the BiometricKit.framework. (You can also dump them yourselves, it is shipped with the iPhoneOS 7.0 SDK on Xcode and of course on an iPhone 5s.)

Classes

BiometricKitIdentity

BiometricKitIdentity represents the enrolled fingerprints on the device. Properties for the user-defined name and UUID are available.

BiometricKitMatchInfo

A BiometricKitMatchInfo object has two properties:

  • A dictionary of details, including (presumably) the area of the enrolled fingerprint, the number of nodes on file, and whether the enrollment data have been updated just now from the latest scan.
  • An array of topology's of class BiometricKitEnrollProgressInfo. Currently observed to contain up to 15 "topology nodes".

BiometricKitEnrollProgressInfo

A BiometricKitEnrollProgressInfo object contains presumably the actual fingerprint digital representation as BiometricKitEnrollProgressCoordinates objects in its BKEPDNewNodeCoordinates key of messageDetails dictionary.

BiometricKitEnrollProgressCoordinates

A BiometricKitEnrollProgressCoordinates object is suspected to record the x and y coordinates and the angle (probably in radians) of the a particular fingerprint distinguishing feature.

Uses

Querying the enrolled fingerprints

You can get an array of all BiometricKitIdentity's on file with [[BiometricKit manager] identities:nil]. Note that this will only give you the user-defined names and UUIDs, but not the actual fingerprint characteristics as in BiometricKitEnrollProgressInfo.

Getting scan results

There are at least three ways you can get the scan results from the TouchID sensor.

BiometricKit manager and delegate methods

Simple to set up in your own apps. Note that if you decide to use the BiometricKit class and the BiometricKitDelegate in your own app, the app needs the entitlements of com.apple.private.biometrickit.allow and com.apple.private.bmk.allow.

SBLockScreenManager of SpringBoardUIServices

SBLockScreenManager - (void)biometricEventMonitor:(SBUIBiometricEventMonitor *) handleBiometricEvent:(unsigned) would always be invoked after the screen is on and a fingerprint is registered.

XPC

BiometricKitXPCClient - (void)matchResult:(BiometricKitIdentity *)result withDictionary:(NSDictionary *)dictionary

Issues after going into the TouchID settings

For some unknown reason, no further message would be called upon scanning if the user enters the TouchID settings under Preferences.app. The device has to be slept and unlocked in order to receive messages from the aforementioned methods again.

(If you find a workaround please edit this out. --Jdoe (talk) 07:06, 4 January 2014 (PST))

Enrollment

(Not investigated, but there are some methods regarding enrollment in this framework. Also refer to the BiometricKitUI.framework --Jdoe (talk) 07:06, 4 January 2014 (PST))