Skip to content

Commit 77b1cfa

Browse files
authored
Merge branch 'eu-digital-identity-wallet:main' into feat/add_transaction_data_to_request_screen
2 parents 9fc3154 + 250cd56 commit 77b1cfa

File tree

24 files changed

+511
-230
lines changed

24 files changed

+511
-230
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ The EUDIW project provides, through this repository, an Android app. Please refe
3535

3636
The app consumes the SDK called EUDIW Wallet core [Wallet core](https://github.com/eu-digital-identity-wallet/eudi-lib-android-wallet-core) and a list of available libraries to facilitate remote presentation, proximity, and issuing test/demo functionality following the specification of the [ARF](https://github.com/eu-digital-identity-wallet/eudi-doc-architecture-and-reference-framework), including:
3737

38-
- OpenID4VP - draft 24 (remote presentation), presentation exchange v2.0, DCQL
38+
- OpenID4VP - v1 (remote presentation), DCQL
3939

4040
- ISO18013-5 (proximity presentation),
4141

assembly-logic/src/main/AndroidManifest.xml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
<uses-feature
2323
android:name="android.hardware.nfc"
24-
android:required="true" />
24+
android:required="false" />
2525

2626
<uses-feature
2727
android:name="android.hardware.camera.any"
@@ -30,6 +30,7 @@
3030
<uses-feature
3131
android:name="android.hardware.bluetooth"
3232
android:required="true" />
33+
3334
<uses-feature
3435
android:name="android.hardware.bluetooth_le"
3536
android:required="true" />
@@ -43,16 +44,11 @@
4344
android:maxSdkVersion="30" />
4445

4546
<uses-permission android:name="android.permission.BLUETOOTH_SCAN" />
46-
4747
<uses-permission android:name="android.permission.BLUETOOTH_ADVERTISE" />
48-
4948
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
50-
5149
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
5250
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
53-
5451
<uses-permission android:name="android.permission.CAMERA" />
55-
5652
<uses-permission android:name="android.permission.HIDE_OVERLAY_WINDOWS" />
5753

5854
<application

business-logic/src/dev/java/eu/europa/ec/businesslogic/config/RQESConfigImpl.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class RQESConfigImpl(val context: Context) : EudiRQESUiConfig {
3232
get() = listOf(
3333
QtspData(
3434
name = "Wallet-Centric",
35-
endpoint = "https://walletcentric.signer.eudiw.dev/csc/v2".toUriOrEmpty(),
35+
endpoint = "https://walletcentric.signer.dev.eudiw.dev/csc/v2".toUriOrEmpty(),
3636
tsaUrl = "https://timestamp.sectigo.com/qualified",
3737
clientId = "wallet-client",
3838
clientSecret = "somesecret2",

common-feature/src/main/java/eu/europa/ec/commonfeature/ui/biometric/BiometricScreen.kt

Lines changed: 33 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@ import androidx.compose.foundation.layout.PaddingValues
2222
import androidx.compose.foundation.layout.Row
2323
import androidx.compose.foundation.layout.fillMaxSize
2424
import androidx.compose.foundation.layout.fillMaxWidth
25+
import androidx.compose.foundation.layout.navigationBarsPadding
2526
import androidx.compose.foundation.layout.padding
27+
import androidx.compose.foundation.rememberScrollState
28+
import androidx.compose.foundation.verticalScroll
2629
import androidx.compose.material3.MaterialTheme
2730
import androidx.compose.material3.Text
2831
import androidx.compose.runtime.Composable
@@ -46,6 +49,7 @@ import eu.europa.ec.uilogic.component.AppIcons
4649
import eu.europa.ec.uilogic.component.content.ContentHeader
4750
import eu.europa.ec.uilogic.component.content.ContentHeaderConfig
4851
import eu.europa.ec.uilogic.component.content.ContentScreen
52+
import eu.europa.ec.uilogic.component.content.ImePaddingConfig
4953
import eu.europa.ec.uilogic.component.content.ScreenNavigateAction
5054
import eu.europa.ec.uilogic.component.preview.PreviewTheme
5155
import eu.europa.ec.uilogic.component.preview.ThemeModePreviews
@@ -60,6 +64,7 @@ import eu.europa.ec.uilogic.config.FlowCompletion
6064
import eu.europa.ec.uilogic.config.NavigationType
6165
import eu.europa.ec.uilogic.extension.cacheDeepLink
6266
import eu.europa.ec.uilogic.extension.finish
67+
import eu.europa.ec.uilogic.extension.paddingFrom
6368
import eu.europa.ec.uilogic.extension.resetBackStack
6469
import eu.europa.ec.uilogic.extension.setBackStackFlowCancelled
6570
import eu.europa.ec.uilogic.extension.setBackStackFlowSuccess
@@ -89,7 +94,8 @@ fun BiometricScreen(
8994
onBack = {
9095
viewModel.setEvent(Event.OnNavigateBack)
9196
},
92-
contentErrorConfig = state.error
97+
contentErrorConfig = state.error,
98+
imePaddingConfig = ImePaddingConfig.ONLY_CONTENT
9399
) {
94100
Body(
95101
state = state,
@@ -180,28 +186,30 @@ private fun Body(
180186
Column(
181187
Modifier
182188
.fillMaxSize()
183-
.padding(padding),
184-
verticalArrangement = Arrangement.Center
189+
.paddingFrom(padding, bottom = false)
185190
) {
186191
Column(
187192
modifier = Modifier
188193
.fillMaxWidth()
189-
.weight(1f),
194+
.weight(1f)
195+
.verticalScroll(rememberScrollState())
190196
) {
191197
MainContent(
192198
state = state,
193199
onEventSent = onEventSent,
194200
)
195201
}
196202

197-
Row(
198-
modifier = Modifier.fillMaxWidth(),
199-
horizontalArrangement = Arrangement.End,
200-
) {
201-
if (state.userBiometricsAreEnabled) {
203+
if (state.userBiometricsAreEnabled) {
204+
Row(
205+
modifier = Modifier
206+
.fillMaxWidth()
207+
.navigationBarsPadding()
208+
.padding(bottom = 5.dp),
209+
horizontalArrangement = Arrangement.End,
210+
) {
202211
WrapIconButton(
203212
iconData = AppIcons.TouchId,
204-
modifier = Modifier.padding(bottom = 5.dp),
205213
onClick = {
206214
onEventSent(
207215
Event.OnBiometricsClicked(
@@ -213,25 +221,25 @@ private fun Body(
213221
)
214222
}
215223
}
224+
}
216225

217-
LaunchedEffect(Unit) {
218-
effectFlow.onEach { effect ->
219-
when (effect) {
220-
is Effect.Navigation -> {
221-
onNavigationRequested(effect)
222-
}
226+
LaunchedEffect(Unit) {
227+
effectFlow.onEach { effect ->
228+
when (effect) {
229+
is Effect.Navigation -> {
230+
onNavigationRequested(effect)
231+
}
223232

224-
is Effect.InitializeBiometricAuthOnCreate -> {
225-
onEventSent(
226-
Event.OnBiometricsClicked(
227-
context = context,
228-
shouldThrowErrorIfNotAvailable = false,
229-
)
233+
is Effect.InitializeBiometricAuthOnCreate -> {
234+
onEventSent(
235+
Event.OnBiometricsClicked(
236+
context = context,
237+
shouldThrowErrorIfNotAvailable = false,
230238
)
231-
}
239+
)
232240
}
233-
}.collect()
234-
}
241+
}
242+
}.collect()
235243
}
236244
}
237245

common-feature/src/main/java/eu/europa/ec/commonfeature/ui/pin/PinScreen.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ import androidx.compose.foundation.layout.PaddingValues
2323
import androidx.compose.foundation.layout.fillMaxSize
2424
import androidx.compose.foundation.layout.fillMaxWidth
2525
import androidx.compose.foundation.layout.padding
26+
import androidx.compose.foundation.rememberScrollState
27+
import androidx.compose.foundation.verticalScroll
2628
import androidx.compose.material3.ExperimentalMaterial3Api
2729
import androidx.compose.material3.MaterialTheme
2830
import androidx.compose.material3.SheetState
@@ -45,6 +47,7 @@ import eu.europa.ec.resourceslogic.R
4547
import eu.europa.ec.uilogic.component.AppIconAndText
4648
import eu.europa.ec.uilogic.component.AppIconAndTextDataUi
4749
import eu.europa.ec.uilogic.component.content.ContentScreen
50+
import eu.europa.ec.uilogic.component.content.ImePaddingConfig
4851
import eu.europa.ec.uilogic.component.preview.PreviewTheme
4952
import eu.europa.ec.uilogic.component.preview.ThemeModePreviews
5053
import eu.europa.ec.uilogic.component.utils.SPACING_LARGE
@@ -80,13 +83,14 @@ fun PinScreen(
8083
val isBottomSheetOpen = state.isBottomSheetOpen
8184
val scope = rememberCoroutineScope()
8285
val bottomSheetState = rememberModalBottomSheetState(
83-
skipPartiallyExpanded = false
86+
skipPartiallyExpanded = true
8487
)
8588

8689
ContentScreen(
8790
isLoading = state.isLoading,
8891
navigatableAction = state.action,
8992
onBack = { viewModel.setEvent(state.onBackEvent) },
93+
imePaddingConfig = ImePaddingConfig.ONLY_CONTENT,
9094
stickyBottom = { paddingValues ->
9195
WrapStickyBottomContent(
9296
modifier = Modifier
@@ -181,6 +185,7 @@ private fun Content(
181185
modifier = Modifier
182186
.fillMaxSize()
183187
.padding(paddingValues)
188+
.verticalScroll(rememberScrollState())
184189
) {
185190
AppIconAndText(
186191
modifier = Modifier

common-feature/src/main/java/eu/europa/ec/commonfeature/ui/request/RequestScreen.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ fun RequestScreen(
9696
val isBottomSheetOpen = state.isBottomSheetOpen
9797
val scope = rememberCoroutineScope()
9898
val bottomSheetState = rememberModalBottomSheetState(
99-
skipPartiallyExpanded = false
99+
skipPartiallyExpanded = true
100100
)
101101

102102
ContentScreen(

core-logic/src/demo/java/eu/europa/ec/corelogic/config/WalletCoreConfigImpl.kt

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ import eu.europa.ec.corelogic.BuildConfig
2121
import eu.europa.ec.eudi.wallet.EudiWalletConfig
2222
import eu.europa.ec.eudi.wallet.issue.openid4vci.OpenId4VciManager
2323
import eu.europa.ec.eudi.wallet.transfer.openId4vp.ClientIdScheme
24-
import eu.europa.ec.eudi.wallet.transfer.openId4vp.EncryptionAlgorithm
25-
import eu.europa.ec.eudi.wallet.transfer.openId4vp.EncryptionMethod
2624
import eu.europa.ec.eudi.wallet.transfer.openId4vp.Format
2725
import eu.europa.ec.resourceslogic.R
2826

@@ -48,17 +46,12 @@ internal class WalletCoreConfigImpl(
4846
useStrongBoxForKeys = true
4947
)
5048
configureOpenId4Vp {
51-
withEncryptionAlgorithms(listOf(EncryptionAlgorithm.ECDH_ES))
52-
withEncryptionMethods(
49+
withClientIdSchemes(
5350
listOf(
54-
EncryptionMethod.A128CBC_HS256,
55-
EncryptionMethod.A256GCM
51+
ClientIdScheme.X509SanDns,
52+
ClientIdScheme.X509Hash
5653
)
5754
)
58-
59-
withClientIdSchemes(
60-
listOf(ClientIdScheme.X509SanDns)
61-
)
6255
withSchemes(
6356
listOf(
6457
BuildConfig.OPENID4VP_SCHEME,
@@ -67,7 +60,7 @@ internal class WalletCoreConfigImpl(
6760
)
6861
)
6962
withFormats(
70-
Format.MsoMdoc, Format.SdJwtVc.ES256
63+
Format.MsoMdoc.ES256, Format.SdJwtVc.ES256
7164
)
7265
}
7366

core-logic/src/dev/java/eu/europa/ec/corelogic/config/WalletCoreConfigImpl.kt

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ import eu.europa.ec.corelogic.BuildConfig
2121
import eu.europa.ec.eudi.wallet.EudiWalletConfig
2222
import eu.europa.ec.eudi.wallet.issue.openid4vci.OpenId4VciManager
2323
import eu.europa.ec.eudi.wallet.transfer.openId4vp.ClientIdScheme
24-
import eu.europa.ec.eudi.wallet.transfer.openId4vp.EncryptionAlgorithm
25-
import eu.europa.ec.eudi.wallet.transfer.openId4vp.EncryptionMethod
2624
import eu.europa.ec.eudi.wallet.transfer.openId4vp.Format
2725
import eu.europa.ec.resourceslogic.R
2826

@@ -48,17 +46,12 @@ internal class WalletCoreConfigImpl(
4846
useStrongBoxForKeys = true
4947
)
5048
configureOpenId4Vp {
51-
withEncryptionAlgorithms(listOf(EncryptionAlgorithm.ECDH_ES))
52-
withEncryptionMethods(
49+
withClientIdSchemes(
5350
listOf(
54-
EncryptionMethod.A128CBC_HS256,
55-
EncryptionMethod.A256GCM
51+
ClientIdScheme.X509SanDns,
52+
ClientIdScheme.X509Hash
5653
)
5754
)
58-
59-
withClientIdSchemes(
60-
listOf(ClientIdScheme.X509SanDns)
61-
)
6255
withSchemes(
6356
listOf(
6457
BuildConfig.OPENID4VP_SCHEME,
@@ -67,7 +60,7 @@ internal class WalletCoreConfigImpl(
6760
)
6861
)
6962
withFormats(
70-
Format.MsoMdoc, Format.SdJwtVc.ES256
63+
Format.MsoMdoc.ES256, Format.SdJwtVc.ES256
7164
)
7265
}
7366

core-logic/src/main/java/eu/europa/ec/corelogic/controller/WalletCorePresentationController.kt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ sealed class TransferEventPartialState {
7373

7474
data object ResponseSent : TransferEventPartialState()
7575
data class Redirect(val uri: URI) : TransferEventPartialState()
76+
data object IntentToSend : TransferEventPartialState()
7677
}
7778

7879
sealed class CheckKeyUnlockPartialState {
@@ -290,6 +291,12 @@ class WalletCorePresentationControllerImpl(
290291
uri = uri
291292
)
292293
)
294+
},
295+
296+
intentToSend = {
297+
trySendBlocking(
298+
TransferEventPartialState.IntentToSend
299+
)
293300
}
294301
)
295302

core-logic/src/main/java/eu/europa/ec/corelogic/util/EudiWalletListenerWrapper.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ class EudiWalletListenerWrapper(
2929
private val onRequestReceived: (RequestProcessor.ProcessedRequest) -> Unit,
3030
private val onResponseSent: () -> Unit,
3131
private val onRedirect: (URI) -> Unit,
32+
private val intentToSend: () -> Unit
3233
) : TransferEvent.Listener {
3334
override fun onTransferEvent(event: TransferEvent) {
3435
when (event) {
@@ -40,6 +41,7 @@ class EudiWalletListenerWrapper(
4041
is TransferEvent.RequestReceived -> onRequestReceived(event.processedRequest)
4142
is TransferEvent.ResponseSent -> onResponseSent()
4243
is TransferEvent.Redirect -> onRedirect(event.redirectUri)
44+
is TransferEvent.IntentToSend -> intentToSend()
4345
}
4446
}
4547
}

0 commit comments

Comments
 (0)