Skip to content

Commit 41ee580

Browse files
authored
Add App Check to the GHA logic (#691)
* Add App Check to the GHA logic * Add App Check secrets * Update guids.json * Update android_dependencies.cmake * Update BuiltInProviderWrapper.cs * Update readme.md
1 parent 3e85862 commit 41ee580

19 files changed

+63
-18
lines changed

.github/workflows/build_android.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:

.github/workflows/build_ios.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:

.github/workflows/build_linux.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:

.github/workflows/build_macos.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:

.github/workflows/build_starter.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ on:
2828
required: true
2929
apis:
3030
description: 'CSV of apis to build and test'
31-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
31+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
3232
required: true
3333
# Additional CMake flags to use
3434
additional_cmake_flags:
@@ -102,7 +102,7 @@ jobs:
102102
echo "platform='Android,iOS,tvOS,Windows,macOS,Linux,Playmode'" >> $GITHUB_OUTPUT
103103
echo "release_label=nightly-$(date "+%Y%m%d-%H%M%S")" >> $GITHUB_OUTPUT
104104
echo "release_version=NoVersion" >> $GITHUB_OUTPUT
105-
echo "apis='analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'" >> $GITHUB_OUTPUT
105+
echo "apis='analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'" >> $GITHUB_OUTPUT
106106
echo "unity_version=2020" >> $GITHUB_OUTPUT
107107
echo "should_trigger_package=true" >> $GITHUB_OUTPUT
108108
echo "firebase_cpp_sdk_version=" >> $GITHUB_OUTPUT

.github/workflows/build_tvos.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:
@@ -47,7 +47,7 @@ on:
4747
type: string
4848
apis:
4949
description: 'CSV of apis to build and test'
50-
default: 'analytics,auth,crashlytics,database,firestore,functions,installations,messaging,remote_config,storage'
50+
default: 'analytics,app_check,auth,crashlytics,database,firestore,functions,installations,messaging,remote_config,storage'
5151
required: true
5252
type: string
5353
unity_platform_name:

.github/workflows/build_windows.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on:
2020
type: string
2121
apis:
2222
description: 'CSV of apis to build and test'
23-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
23+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2424
required: true
2525
type: string
2626
unity_platform_name:

.github/workflows/generate_swig.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ on:
1616
type: string
1717
apis:
1818
description: 'CSV of apis to build and test'
19-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
19+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2020
required: true
2121
type: string
2222
# Additional CMake flags to use

.github/workflows/integration_tests.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ on:
1818
required: true
1919
apis:
2020
description: 'CSV of apis to build and test'
21-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
21+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
2222
required: true
2323
mobile_test_on:
2424
description: 'Run mobile tests on real and/or virtual devices? (value: real, virtual. separated by commas)'

.github/workflows/package.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ on:
3333
type: string
3434
apis:
3535
description: 'CSV of apis to build and test'
36-
default: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
36+
default: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
3737
required: true
3838
type: string
3939

4040

4141
env:
4242
# Use SHA256 for hashing files.
4343
hashCommand: "sha256sum"
44-
default_apis: 'analytics,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
44+
default_apis: 'analytics,app_check,auth,crashlytics,database,dynamic_links,firestore,functions,installations,messaging,remote_config,storage'
4545

4646
jobs:
4747
package_sdks:

README.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ iOS, and desktop platforms. Note that desktop is ***only supported for developme
55
purposes***. It includes the following Firebase libraries:
66

77
- [Google Analytics for Firebase](https://firebase.google.com/docs/analytics/)
8+
- [Firebase App Check](https://firebase.google.com/docs/app-check/)
89
- [Firebase Authentication](https://firebase.google.com/docs/auth/)
910
- [Firebase Crashlytics](https://firebase.google.com/docs/crashlytics)
1011
- [Firebase Realtime Database](https://firebase.google.com/docs/database/)
@@ -85,7 +86,7 @@ Expected output artifact is
8586
python scripts/build_scripts/build_zips.py --platform=<target platform> --targets=<lib1> --targets=<lib2>
8687
```
8788

88-
> **Note:** Supported library names: analytics, auth, crashlytics, database, dynamic_links, firestore, functions, installations, messaging, remote_config, storage
89+
> **Note:** Supported library names: analytics, app_check, auth, crashlytics, database, dynamic_links, firestore, functions, installations, messaging, remote_config, storage
8990
9091
## Packaging
9192

app_check/src/BuiltInProviderWrapper.cs

+1
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ public System.Threading.Tasks.Task<AppCheckToken> GetTokenAsync() {
6363
}
6464

6565
// This is called from the C++ implementation, on the Unity main thread.
66+
[MonoPInvokeCallback(typeof(AppCheckUtil.CompleteBuiltInGetTokenDelegate))]
6667
private static void CompleteBuiltInGetTokenMethod(int key, System.IntPtr tokenCPtr,
6768
int error, string errorMessage) {
6869
TaskCompletionSource<AppCheckToken> tcs;

cmake/android_dependencies.cmake

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ set(FIREBASE_ANALYTICS_ANDROID_DEPS
2525
)
2626

2727
set(FIREBASE_APP_CHECK_ANDROID_DEPS
28-
"com.google.firebase:firebase-appcheck"
29-
"com.google.firebase:firebase-appcheck-debug"
30-
"com.google.firebase:firebase-appcheck-playintegrity"
28+
"com.google.firebase:firebase-appcheck:17.0.0"
29+
"com.google.firebase:firebase-appcheck-debug:17.0.0"
30+
"com.google.firebase:firebase-appcheck-playintegrity:17.0.0"
3131
"com.google.firebase:firebase-analytics:21.2.1"
3232
)
3333

docs/readme.md

+5
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ Note: Firebase Dynamic Links is not supported on tvOS.
99
| Feature | Unity Package |
1010
|:----------------------------------:|:---------------------------------:|
1111
| Firebase Analytics | FirebaseAnalytics.unitypackage |
12+
| Firebase App Check | FirebaseAppCheck.unitypackage |
1213
| Firebase Authentication | FirebaseAuth.unitypackage |
1314
| Firebase Crashlytics | FirebaseCrashlytics.unitypackage |
1415
| Firebase Dynamic Links | FirebaseDynamicLinks.unitypackage |
@@ -31,6 +32,7 @@ desktop builds on Windows, OS X, and Linux:
3132
| Feature | Unity Package |
3233
|:----------------------------------:|:---------------------------------:|
3334
| Firebase Authentication | FirebaseAuth.unitypackage |
35+
| Firebase App Check | FirebaseAppCheck.unitypackage |
3436
| Firebase Realtime Database* | FirebaseDatabase.unitypackage |
3537
| Cloud Firestore | FirebaseFirestore.unitypackage |
3638
| Firebase Functions | FirebaseFunctions.unitypackage |
@@ -71,6 +73,9 @@ Release Notes
7173
-------------
7274
### 11.0.0
7375
- Changes
76+
- App Check: Adds support for Firebase App Check on Android, iOS, tvOS,
77+
and desktop platforms. To learn more, see
78+
https://firebase.google.com/docs/app-check
7479
- Messaging: Remove deprecated calls `Send`, `Subscribe`, and `Unsubscribe`.
7580
- Remote Config (Android/iOS): Added support for real-time config updates. Use the new
7681
`OnConfigUpdateListener` API to get real-time updates. Existing

scripts/gha-encrypted/app_check/GoogleService-Info.plist.gpg

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
� �
2+
^��E?��������m�H��N/�R/�_�6��T^��t~�ki�<t��Q2�@텷���d.�,̅�8�\��f�Bt���>�;���\��S��r@! �I:{����G�i�'�����P������<�;�AiD(ι'B?�}�v-vZc{����ח�`��a@�?
3+
M���*n���D���7����
4+
C��"�|L߀禱��������
5+
�^��m���J���^��U�|����| ���apgB�5^�v����������i(T�OE����TYٱ�p��]+G��75�KN�s�!��1��'��`�f.@k�ٽ{S��'��g'��8�C�����i�ֳ=��5#�e+�~�_�i�&[`�Q+F ^I����8R��W�5�j��dK�B!��n�檭�ǫ�Nh]{��nUJ���=u*�|w�PVY�q�F6�;N]m�u�s���b����e�ޏ�W����M7��5V��('��<�����*� ��ork�0�G �Olm���Ød��'����B���}�����M�>7HIJ��c���7�ox��Ć��- ^-�

scripts/gha-encrypted/app_check/app_check_token.txt.gpg

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
� J��G����Z���P�$�ɤ�-g/�Op�+�
2+
���,췆;�����[��)���F�&D����Q�'�6��w�GE�p��t���m����Q�b^���
Binary file not shown.

scripts/gha/integration_testing/build_testapps.json

+17
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,23 @@
1717
"com.google.firebase.analytics-*.tgz"
1818
]
1919
},
20+
{
21+
"name": "app_check",
22+
"full_name": "FirebaseAppCheck",
23+
"captial_name": "AppCheck",
24+
"bundle_id": "com.google.firebase.unity.appcheck.testapp",
25+
"testapp_path": "app_check/testapp",
26+
"platforms": ["Android", "Playmode", "iOS", "tvOS", "Windows", "macOS", "Linux"],
27+
"plugins": [
28+
"FirebaseAppCheck.unitypackage"
29+
],
30+
"provision": "Firebase_Dev_Wildcard.mobileprovision",
31+
"upm_packages": [
32+
"com.google.external-dependency-manager-*.tgz",
33+
"com.google.firebase.app-*.tgz",
34+
"com.google.firebase.app-check-*.tgz"
35+
]
36+
},
2037
{
2138
"name": "auth",
2239
"full_name": "FirebaseAuth",

unity_packer/guids.json

+15-1
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,9 @@
561561
"Firebase/m2repository/com/google/firebase/firebase-storage-unity/10.6.0/firebase-storage-unity-10.6.0.srcaar": "5f54445760624ee5ab11bb6f5615115c"
562562
},
563563
"10.7.0": {
564+
"Firebase/Editor/AppCheckDependencies.xml": "7b93a7e6be01479aa8e1324390059c11",
564565
"Firebase/Editor/FirebaseAnalytics_version-10.7.0_manifest.txt": "5647178bc2234ee9b462ee89aad60164",
566+
"Firebase/Editor/FirebaseAppCheck_version-10.7.0_manifest.txt": "8cb7c1b045ff4adbb02d0e5744768f2c",
565567
"Firebase/Editor/FirebaseAuth_version-10.7.0_manifest.txt": "1b9747f01af94eba9e13952b3da2d98f",
566568
"Firebase/Editor/FirebaseCrashlytics_version-10.7.0_manifest.txt": "dd650d318aa348f6b63ced7bb12aab75",
567569
"Firebase/Editor/FirebaseDatabase_version-10.7.0_manifest.txt": "81824f18800d4aa78b304ac67e6d8310",
@@ -572,13 +574,23 @@
572574
"Firebase/Editor/FirebaseMessaging_version-10.7.0_manifest.txt": "bda71acea1bb45a69b1b76414e3b7694",
573575
"Firebase/Editor/FirebaseRemoteConfig_version-10.7.0_manifest.txt": "25698e27e61f46038de3f11079a39a3c",
574576
"Firebase/Editor/FirebaseStorage_version-10.7.0_manifest.txt": "9361dcf560624487add8fcbb5ada6a9a",
577+
"Firebase/Plugins/Firebase.AppCheck.dll": "0c5ed333710d4b75be4ba64948387242",
578+
"Firebase/Plugins/Firebase.AppCheck.pdb": "0e6c428fc2dd48d7b1fc3653ddec5296",
579+
"Firebase/Plugins/iOS/Firebase.AppCheck.dll": "11bf1ad4bd3a4140a8d619ca62dd1299",
580+
"Firebase/Plugins/iOS/Firebase.AppCheck.pdb": "aa0d407b7dc94437989bd21dbcb8129f",
575581
"Firebase/Plugins/x86_64/FirebaseCppApp-10_7_0.bundle": "4a3bbb72957c46019fe2621122a551a9",
576582
"Firebase/Plugins/x86_64/FirebaseCppApp-10_7_0.dll": "bbac55f201f6491c90bb05b9b43b9fe4",
577583
"Firebase/Plugins/x86_64/FirebaseCppApp-10_7_0.so": "5d20bfd113704760b8a0ed2a1f1c4a11",
584+
"Firebase/Plugins/x86_64/FirebaseCppAppCheck.bundle": "e67484c6c4644e6ab030360a71bfa7da",
585+
"Firebase/Plugins/x86_64/FirebaseCppAppCheck.dll": "b45f6eb22b224bd4a0a45d3ddc8b9c7d",
586+
"Firebase/Plugins/x86_64/FirebaseCppAppCheck.so": "97216acd9a6147259ea13b994ccb9fa2",
578587
"Firebase/m2repository/com/google/firebase/firebase-analytics-unity/10.7.0/firebase-analytics-unity-10.7.0.pom": "3c2422820e1c4b068b1ecf4eceb0bd1d",
579588
"Firebase/m2repository/com/google/firebase/firebase-analytics-unity/10.7.0/firebase-analytics-unity-10.7.0.srcaar": "688278569b0542bb82e3f41b17b72d89",
580589
"Firebase/m2repository/com/google/firebase/firebase-app-unity/10.7.0/firebase-app-unity-10.7.0.pom": "07cca069edd1437893c73b709a06e93f",
581590
"Firebase/m2repository/com/google/firebase/firebase-app-unity/10.7.0/firebase-app-unity-10.7.0.srcaar": "49b2ec82a6a547b798d83ad03539ac0d",
591+
"Firebase/m2repository/com/google/firebase/firebase-appcheck-unity/10.7.0/firebase-appcheck-unity-10.7.0.pom": "c924ce820ef247b897eeb6824c6f0563",
592+
"Firebase/m2repository/com/google/firebase/firebase-appcheck-unity/10.7.0/firebase-appcheck-unity-10.7.0.srcaar": "02d59478132246a99d6de647a0e91099",
593+
"Firebase/m2repository/com/google/firebase/firebase-appcheck-unity/maven-metadata.xml": "cfa09eb6ba5647618b29c553fda150f3",
582594
"Firebase/m2repository/com/google/firebase/firebase-auth-unity/10.7.0/firebase-auth-unity-10.7.0.pom": "f73f7865eca04b4a95567e01d13f3a8d",
583595
"Firebase/m2repository/com/google/firebase/firebase-auth-unity/10.7.0/firebase-auth-unity-10.7.0.srcaar": "af0e404dab3e4d5c85b97ed8a0f3f3f8",
584596
"Firebase/m2repository/com/google/firebase/firebase-config-unity/10.7.0/firebase-config-unity-10.7.0.pom": "51b15c12808b46febb470195a72974ec",
@@ -598,7 +610,9 @@
598610
"Firebase/m2repository/com/google/firebase/firebase-messaging-unity/10.7.0/firebase-messaging-unity-10.7.0.pom": "a4490d01030747eeb1682e613a656d8e",
599611
"Firebase/m2repository/com/google/firebase/firebase-messaging-unity/10.7.0/firebase-messaging-unity-10.7.0.srcaar": "9a0ead811b124087af2c7a1d3d475fa5",
600612
"Firebase/m2repository/com/google/firebase/firebase-storage-unity/10.7.0/firebase-storage-unity-10.7.0.pom": "3921798c85b64ab99dfb10d6a83ae0f4",
601-
"Firebase/m2repository/com/google/firebase/firebase-storage-unity/10.7.0/firebase-storage-unity-10.7.0.srcaar": "e9fe5d1c65034cdc8f83eda7dee52264"
613+
"Firebase/m2repository/com/google/firebase/firebase-storage-unity/10.7.0/firebase-storage-unity-10.7.0.srcaar": "e9fe5d1c65034cdc8f83eda7dee52264",
614+
"Plugins/iOS/Firebase/libFirebaseCppAppCheck.a": "5ba930d6364e431c97591fb429b6f553",
615+
"Plugins/tvOS/Firebase/libFirebaseCppAppCheck.a": "adf6c486a27a4acc862f658f7c150dc0"
602616
},
603617
"3.0.0": {
604618
"Firebase/Editor/FirebaseAnalytics_v3.0.0_manifest.txt": "13c9ba8e35174de78ad7ca9a48cba9f0",

0 commit comments

Comments
 (0)