@@ -5,76 +5,76 @@ diff -r d80eefe94738 mobile/android/geckoview/build.gradle
5
5
implementation "androidx.annotation:annotation:1.6.0"
6
6
implementation "androidx.legacy:legacy-support-v4:1.0.0"
7
7
8
- - implementation "com.google.android.gms:play-services-fido:20.0.1 "
8
+ - implementation "com.google.android.gms:play-services-fido:21.1.0 "
9
9
+ implementation "org.microg.gms:play-services-fido:0.3.2.240913"
10
10
implementation "org.yaml:snakeyaml:2.2"
11
11
12
12
implementation "androidx.lifecycle:lifecycle-common:2.6.1"
13
- diff -r d80eefe94738 mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java
14
- --- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java Tue Nov 28 21:01:37 2023 +0000
15
- +++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java Fri Dec 15 11:32:38 2023 +0300
16
- @@ -260 ,27 +260,15 @@
13
+ diff -r 14b32d530926 mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java
14
+ --- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java Thu Jul 04 12:11:31 2024 +0000
15
+ +++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/WebAuthnTokenManager.java Tue Jul 09 11:44:11 2024 -0400
16
+ @@ -193 ,27 +193,14 @@
17
17
18
- final Task<PendingIntent> intentTask;
18
+ final Task<PendingIntent> intentTask;
19
19
20
- - if (BuildConfig.MOZILLA_OFFICIAL) {
21
- - // Certain Fenix builds and signing keys are whitelisted for Web Authentication.
22
- - // See https://wiki.mozilla.org/Security/Web_Authentication
23
- - //
24
- - // Third party apps will need to get whitelisted themselves.
25
- - final Fido2PrivilegedApiClient fidoClient =
26
- - Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
27
- + // The privileged FIDO2 API normally is restricted to apps with package
28
- + // names and signatures that Google knows to be a browser. microG does not
29
- + // have such a list, instead it asks the user to confirm that the app doing
30
- + // the request is indeed a browser app (only for the first request from
31
- + // that app).
32
- + final Fido2PrivilegedApiClient fidoClient =
33
- + Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
34
-
35
- - intentTask = fidoClient.getRegisterPendingIntent(browserOptions);
36
- - } else {
37
- - // For non-official builds, websites have to opt-in to permit the
38
- - // particular version of Gecko to perform WebAuthn operations on
39
- - // them. See https://developers.google.com/digital-asset-links
40
- - // for the general form, and Step 1 of
41
- - // https://developers.google.com/identity/fido/android/native-apps
42
- - // for details about doing this correctly for the FIDO2 API.
43
- - final Fido2ApiClient fidoClient =
44
- - Fido.getFido2ApiClient(GeckoAppShell.getApplicationContext());
20
+ - if (BuildConfig.MOZILLA_OFFICIAL) {
21
+ - // Certain Fenix builds and signing keys are whitelisted for Web Authentication.
22
+ - // See https://wiki.mozilla.org/Security/Web_Authentication
23
+ - //
24
+ - // Third party apps will need to get whitelisted themselves.
25
+ - final Fido2PrivilegedApiClient fidoClient =
26
+ - Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
45
27
-
46
- - intentTask = fidoClient.getRegisterPendingIntent(requestOptions);
47
- - }
48
- + intentTask = fidoClient.getRegisterPendingIntent(browserOptions);
49
-
50
- final GeckoResult<MakeCredentialResponse> result = new GeckoResult<>();
28
+ - intentTask = fidoClient.getRegisterPendingIntent(browserOptions);
29
+ - } else {
30
+ - // For non-official builds, websites have to opt-in to permit the
31
+ - // particular version of Gecko to perform WebAuthn operations on
32
+ - // them. See https://developers.google.com/digital-asset-links
33
+ - // for the general form, and Step 1 of
34
+ - // https://developers.google.com/identity/fido/android/native-apps
35
+ - // for details about doing this correctly for the FIDO2 API.
36
+ - final Fido2ApiClient fidoClient =
37
+ - Fido.getFido2ApiClient(GeckoAppShell.getApplicationContext());
38
+ -
39
+ - intentTask = fidoClient.getRegisterPendingIntent(requestOptions);
40
+ - }
41
+ + // The privileged FIDO2 API normally is restricted to apps with package
42
+ + // names and signatures that Google knows to be a browser. microG does not
43
+ + // have such a list, instead it asks the user to confirm that the app doing
44
+ + // the request is indeed a browser app (only for the first request from
45
+ + // that app).
46
+ + final Fido2PrivilegedApiClient fidoClient =
47
+ + Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
48
+ + intentTask = fidoClient.getRegisterPendingIntent(browserOptions);
51
49
52
- @@ -464,19 +452,12 @@
53
- .build();
50
+ intentTask.addOnSuccessListener(
51
+ pendingIntent -> {
52
+ @@ -411,19 +398,12 @@
53
+ .build();
54
54
55
- final Task<PendingIntent> intentTask;
56
- - // See the makeCredential method for documentation about this
57
- - // conditional.
58
- - if (BuildConfig.MOZILLA_OFFICIAL) {
59
- - final Fido2PrivilegedApiClient fidoClient =
60
- - Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
61
- + // See the makeCredential method for documentation about the FIDO2 API and
62
- + // microG.
63
- + final Fido2PrivilegedApiClient fidoClient =
64
- + Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
55
+ final Task<PendingIntent> intentTask;
56
+ - // See the makeCredential method for documentation about this
57
+ - // conditional.
58
+ - if (BuildConfig.MOZILLA_OFFICIAL) {
59
+ - final Fido2PrivilegedApiClient fidoClient =
60
+ - Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
61
+ + // See the makeCredential method for documentation about the FIDO2 API and
62
+ + // microG.
63
+ + final Fido2PrivilegedApiClient fidoClient =
64
+ + Fido.getFido2PrivilegedApiClient(GeckoAppShell.getApplicationContext());
65
65
66
- - intentTask = fidoClient.getSignPendingIntent(browserOptions);
67
- - } else {
68
- - final Fido2ApiClient fidoClient =
69
- - Fido.getFido2ApiClient(GeckoAppShell.getApplicationContext());
66
+ - intentTask = fidoClient.getSignPendingIntent(browserOptions);
67
+ - } else {
68
+ - final Fido2ApiClient fidoClient =
69
+ - Fido.getFido2ApiClient(GeckoAppShell.getApplicationContext());
70
70
-
71
- - intentTask = fidoClient.getSignPendingIntent(requestOptions);
72
- - }
73
- + intentTask = fidoClient.getSignPendingIntent(browserOptions);
71
+ - intentTask = fidoClient.getSignPendingIntent(requestOptions);
72
+ - }
73
+ + intentTask = fidoClient.getSignPendingIntent(browserOptions);
74
74
75
- final GeckoResult<GetAssertionResponse> result = new GeckoResult<>();
76
- intentTask.addOnSuccessListener(
77
- @@ -573 ,15 +554 ,9 @@
75
+ intentTask.addOnSuccessListener(
76
+ pendingIntent -> {
77
+ @@ -557 ,15 +537 ,9 @@
78
78
@WrapForJNI(calledFrom = "gecko")
79
79
private static GeckoResult<Boolean> webAuthnIsUserVerifyingPlatformAuthenticatorAvailable() {
80
80
final Task<Boolean> task;
0 commit comments