Skip to content

feat(android): Add ability to configure key store - #692

Merged
tido64 merged 4 commits into
microsoft:trunkfrom
sveinar:sveinar/android_keystore
Jan 7, 2022
Merged

feat(android): Add ability to configure key store#692
tido64 merged 4 commits into
microsoft:trunkfrom
sveinar:sveinar/android_keystore

Conversation

@sveinar

@sveinar sveinar commented Jan 6, 2022

Copy link
Copy Markdown
Contributor

The ability to configure the key store is required for enabling certain features such as MSAL's auth broker.

Description

We need to add signingConfigs property to the Android specific section in the app manifest.

I tried as much to match the DSL of the app manifest itself.
In the code, I have 'landed' on a fixed set of flavors, debug and release.

The trouble to make this generic on the fly in the 'android' section of the gradle is that the signingConfigs are ReadOnly object when first created. If I tried to use closures inside the 'android' section with .each { flavor -> ... } then there was a mismatch with the closure and the DSL, even if I tried to use a proper Java class for the SigningConfig. Alas, two flavors for now.

Resolves #691.

Platforms affected

  • Android
  • iOS
  • macOS
  • Windows

Test plan

Tested with overwriting the 'debug' flavor using a debug.keystore.
Tested with a release keystore.
Tested without any signingConfig in the app.json.
Tested with signingConfig with a

  • missing keystore
  • keystore just as '..' or any other folder
  • keystore empty

TODO

  • Update the Android documentation
  • Update the Manifest documentation

The ability to configure the key store is required for enabling certain features such as MSAL's auth broker.
@sveinar
sveinar force-pushed the sveinar/android_keystore branch from 258216f to 596eecd Compare January 7, 2022 07:55

@tido64 tido64 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great! Just a few nitpicks and it will be good to go.

Comment thread android/app/build.gradle Outdated
Comment thread schema.json Outdated
Comment thread android/test-app-util.gradle Outdated
Comment thread android/app/build.gradle Outdated
Comment thread android/test-app-util.gradle
Comment thread android/test-app-util.gradle Outdated

@tido64 tido64 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again for this ❤️

@tido64
tido64 merged commit 6268328 into microsoft:trunk Jan 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Android: Add ability to configure key store

2 participants