Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Biometric Prompt
Search
Hiroshi Hashimoto
June 13, 2018
Technology
440
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Biometric Prompt
Hiroshi Hashimoto
June 13, 2018
More Decks by Hiroshi Hashimoto
See All by Hiroshi Hashimoto
What's new in Android
hi6484
1
1.5k
メルカリアッテをRxjava2に 載せ換えて。。
hi6484
0
1.7k
Google I/O Extended Tokyo 2017
hi6484
0
240
ヌガー対応 potatotios #33
hi6484
0
80
Other Decks in Technology
See All in Technology
Benchmarking Vector Databases: pgvector vs. LanceDB
tsho
0
140
IoTハンズオンの舞台裏
shirouz
2
130
Backstageでつくるセルフサービスな社内開発基盤
kikunosuke75
1
290
bet_ai_day_2026_session02
agenticsec
1
980
Kiro Crewしか勝たん!?
miu_crescent
PRO
0
180
[RSJ26] AnoleVLA: Lightweight Vision-Language-Action Model with Deep State Space Models for Mobile Manipulation
keio_smilab
PRO
0
120
DINO-EdgeQuery:Edge-First Polygon Decoding for Building Footprint Extraction from Satellite Imagery
lehupa
0
140
V8コントリビュート超入門
riyaamemiya
0
140
生成AI時代の クレデンシャルとパーミッション設計
nrinetcom
PRO
3
1.5k
AI-DLCって実際どう? 〜聞きたいこと全部聞いてみる〜
news_it_enj
0
220
こんなアーキテクチャ図は嫌だ BEYOND THE TIME: 半年後の自分へ贈る15のメッセージ / 15 of Anti-pattern in AWS Architecture Diagrams
naospon
3
230
【Oracle AI Spotlight ウェビナー】AWSか、Azureか、Google Cloudか。その議論にオラクルを含める意義。
oracle4engineer
PRO
2
230
Featured
See All Featured
Building Adaptive Systems
keathley
44
3.2k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2.1k
GitHub's CSS Performance
jonrohan
1033
470k
Leveraging LLMs for student feedback in introductory data science courses - posit::conf(2025)
minecr
1
370
How To Speak Unicorn (iThemes Webinar)
marktimemedia
1
570
Ten Tips & Tricks for a 🌱 transition
stuffmc
0
190
Product Roadmaps are Hard
iamctodd
55
13k
ラッコキーワード サービス紹介資料
rakko
1
4.7M
Rails Girls Zürich Keynote
gr2m
96
14k
Being A Developer After 40
akosma
91
590k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
310
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
400
Transcript
Biometric Prompt 〜Google I/O 2018 わいわい報告会 in 福岡~ Hiroshi Hashimoto
@hi6484 株式会社メルペイ
自己紹介 Hiroshi Hashimoto @hi6484 株式会社メルペイ Android Developer
Biometric Prompt
Biometric Prompt Andorid P(API:28)から Fingerprint Managerが非推奨となり Biometric Promptへ
FingerPrint Manager
Fingerprint Manager <uses-permission android:name="android.permission.USE_FINGERPRINT" />
Fingerprint Manager val fingerprintManager = getSystemService(Context.FINGERPRINT_SERVICE) as FingerprintManager //Fingerprintが搭載端末且つ登録済み if
(manager.isHardwareDetected and fingerprintManager.hasEnrolledFingerprints()) { //認証処理 }
Fingerprint Manager fingerprintManager.authenticate( cryptoObject, cancellationSignal, flags, authenticationCallback, Handler())
Fingerprint Manager object : FingerprintManager.AuthenticationCallback() { override fun onAuthenticationError(errorCode: Int,
errString: CharSequence?) { super.onAuthenticationError(errorCode, errString) } override fun onAuthenticationSucceeded(result: FingerprintManager.AuthenticationResult?) { super.onAuthenticationSucceeded(result) } override fun onAuthenticationFailed() { super.onAuthenticationFailed() } override fun onAuthenticationHelp(helpCode: Int, helpString: CharSequence?) { super.onAuthenticationHelp(helpCode, helpString) } }
Fingerprint Manager ・実装は簡単 ・Fingerprintのみ! ・認証するためのダイアログは各アプリで。
Biometric Prompt
Biometric Prompt <uses-permission android:name="android.permission.USE_BIOMETRIC"/>
Biometric Prompt <uses-permission android:name="android.permission.USE_BIOMETRIC"/> <uses-permission android:name="android.permission.USE_FINGERPRINT"/> Fingerprint Manager
Biometric Prompt if (packageManager.hasSystemFeature( PackageManager.FEATURE_FINGERPRINT)) { //認証処理 }
Biometric Prompt if (packageManager.hasSystemFeature( PackageManager.FEATURE_FINGERPRINT)) { //認証処理 } val manager
= getSystemService(Context.FINGERPRINT_SERVICE) as FingerprintManager //Fingerprintが搭載端末且つ登録済み if (manager.isHardwareDetected and fingerprintManager.hasEnrolledFingerprints()) { //認証処理 } Fingerprint Manager
Biometric Prompt biometricPrompt = BiometricPrompt.Builder(this) .setTitle("タイトル") .setSubtitle("サブ タイトル") .setDescription("指紋認証をお願いします") .setNegativeButton("キャンセル",
mainExecutor, DialogInterface.OnClickListener {dialogInterface, i -> }) .build()
Biometric Prompt biometricPrompt.authenticate( cryptoObject, cancellationSignal, mainExecutor, authenticationCallback) biometricPrompt.authenticate( cancellationSignal, mainExecutor,
authenticationCallback)
Biometric Prompt biometricPrompt.authenticate( cancellationSignal, mainExecutor, authenticationCallback) fingerprintManager.authenticate( cryptoObject, cancellationSignal, flags,
authenticationCallback, Handler()) Fingerprint Manager
Biometric Prompt object : BiometricPrompt.AuthenticationCallback() { override fun onAuthenticationError(errorCode: Int,
errString: CharSequence) { super.onAuthenticationError(errorCode, errString) } override fun onAuthenticationHelp(helpCode: Int, helpString: CharSequence) { super.onAuthenticationHelp(helpCode, helpString) } override fun onAuthenticationSucceeded(result: BiometricPrompt.AuthenticationResult) { super.onAuthenticationSucceeded(result) } override fun onAuthenticationFailed() { super.onAuthenticationFailed()
Biometric Prompt object : BiometricPrompt.AuthenticationCallback() { override fun onAuthenticationError(errorCode: Int,
errString: CharSequence) { } override fun onAuthenticationHelp(helpCode: Int, helpString: CharSequence) { } override fun onAuthenticationSucceeded(result: BiometricPrompt.AuthenticationResult) { } override fun onAuthenticationFailed() { object : FingerprintManager.AuthenticationCallback() { override fun onAuthenticationError(errorCode: Int, errString: CharSequence?) { } override fun onAuthenticationHelp(helpCode: Int, helpString: CharSequence?) { } override fun onAuthenticationSucceeded(result: FingerprintManager.AuthenticationResult?) { } override fun onAuthenticationFailed() { } } Fingerprint Manager
Biometric Prompt ・実装は簡単 ・Fingerprint以外もできるはず! ・認証するためのダイアログは共通になる!!!
Demo
Biometric Prompt けど、 APIレベルは 28以上!!
Biometric Prompt ・P以上はBiometricPromptを使う (使った方が楽) ・M以上N以下はFingerprintManager ・M以上N以下は頑張ってDialogを実装する
Biometric Prompt あとは、 Fingerprint以外の認証方法ができるのを 待つのみ
ご静聴ありがとうございました。