Skip to content

Commit

Permalink
Merge pull request #125 from /issues/124-merge-upstream
Browse files Browse the repository at this point in the history
Merge upstream
  • Loading branch information
romanstrobl authored Dec 1, 2023
2 parents dcaf062 + ed7f6f4 commit cf374af
Show file tree
Hide file tree
Showing 73 changed files with 7,198 additions and 3,268 deletions.
1 change: 0 additions & 1 deletion docs/Configuration-Properties.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ The Enrollment Server uses the following public configuration properties:
| `spring.datasource.username` | `_empty_` | Database JDBC username |
| `spring.datasource.password` | `_empty_` | Database JDBC password |
| `spring.datasource.driver-class-name` | `_empty_` | Datasource JDBC class name |
| `spring.jpa.database-platform` | `_empty_` | Database dialect |
| `spring.jpa.hibernate.ddl-auto` | `none` | Configuration of automatic database schema creation |
| `spring.jpa.properties.hibernate.connection.characterEncoding` | `_empty_` | Character encoding |
| `spring.jpa.properties.hibernate.connection.useUnicode` | `_empty_` | Character encoding - Unicode support |
Expand Down
279 changes: 279 additions & 0 deletions docs/Mobile-Token-API.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ Following endpoints are published in Enrollment Server RESTful API:
### Operations API

- `POST` [/api/auth/token/app/operation/list](#get-pending-operations) - List pending Mobile Token operations
- `POST` [/api/auth/token/app/operation/detail](#get-operation-detail) - Get detail of a Mobile Token operation
- `POST` [/api/auth/token/app/operation/detail/claim](#claim-operation) - Claim a Mobile Token operation for a user
- `POST` [/api/auth/token/app/operation/history](#get-history-of-operations) - Get history of Mobile Token operations
- `POST` [/api/auth/token/app/operation/authorize](#confirm-operation) - Confirm a Mobile Token operation
- `POST` [/api/auth/token/app/operation/cancel](#reject-operation) - Reject a Mobile Token operation
Expand Down Expand Up @@ -226,6 +228,283 @@ Get the list with all operations that are pending confirmation.
```
<!-- end -->

<!-- begin api POST /api/auth/token/app/operation/detail -->
### Get Operation Detail

Get an operation detail.

<!-- begin remove -->

<table>
<tr>
<td>Method</td>
<td><code>POST</code></td>
</tr>
<tr>
<td>Resource URI</td>
<td><code>/api/auth/token/app/operation/detail</code></td>
</tr>
</table>
<!-- end -->

#### Request

- Headers:
- `Content-Type: application/json`
- `Accept-Language: en-US`
- `X-PowerAuth-Authorization: ...`

```json
{
"requestObject": {
"id": "7e0ba60f-bf22-4ff5-b999-2733784e5eaa"
}
}
```

#### Response 200

```json
{
"status": "OK",
"responseObject": {
"id": "7e0ba60f-bf22-4ff5-b999-2733784e5eaa",
"name": "authorize_payment",
"data": "A1*A100CZK*Q238400856/0300**D20190629*NUtility Bill Payment - 05/2019",
"status": "PENDING",
"operationCreated": "2018-07-02T14:43:13+0000",
"operationExpires": "2018-07-02T14:48:17+0000",
"allowedSignatureType": {
"type": "2FA",
"variants": [
"possession_knowledge",
"possession_biometry"
]
},
"formData": {
"title": "Confirm Payment",
"message": "Hello,\nplease confirm following payment:",
"attributes": [
{
"type": "ALERT",
"alertType": "WARNING",
"id": "operation.warning",
"label": "Balance alert",
"title": "Insufficient Balance",
"message": "You have only $1.00 on your account with number 238400856/0300."
},
{
"type": "HEADING",
"id": "operation.heading",
"label": "Utility Payment"
},
{
"type": "AMOUNT",
"id": "operation.amount",
"label": "Amount",
"amount": 2199.40,
"currency": "CZK",
"amountFormatted": "2199,40",
"currencyFormatted": ""
},
{
"type": "AMOUNT_CONVERSION",
"id": "operation.conversion",
"label": "Conversion Rate",
"dynamic": false,
"sourceAmount": 100.00,
"sourceCurrency": "USD",
"sourceAmountFormatted": "100.00",
"sourceCurrencyFormatted": "$",
"sourceValueFormatted": "$100.00",
"targetAmount": 2199.40,
"targetCurrency": "CZK",
"targetAmountFormatted": "2199,40",
"targetCurrencyFormatted": "",
"targetValueFormatted": "2199,40 Kč"
},
{
"type": "KEY_VALUE",
"id": "operation.account",
"label": "To Account",
"value": "238400856/0300"
},
{
"type": "KEY_VALUE",
"id": "operation.dueDate",
"label": "Due Date",
"value": "Jun 29, 2019"
},
{
"type": "NOTE",
"id": "operation.note",
"label": "Note",
"note": "Utility Bill Payment - 05/2019"
},
{
"type": "IMAGE",
"id": "operation.image",
"label": "Payment Check Preview",
"thumbnailUrl": "https://example.com/thumbnail.png",
"originalUrl": "https://example.com/image.png"
},
{
"type": "PARTY_INFO",
"id": "operation.partyInfo",
"label": "Application",
"partyInfo": {
"logoUrl": "https://itesco.cz/img/logo/logo.svg",
"name": "Tesco",
"description": "Find out more about Tesco...",
"websiteUrl": "https://itesco.cz/hello"
}
}
]
}
}
}
```
<!-- end -->

<!-- begin api POST /api/auth/token/app/operation/detail/claim -->
### Claim Operation

Claim an operation for a user.

<!-- begin remove -->

<table>
<tr>
<td>Method</td>
<td><code>POST</code></td>
</tr>
<tr>
<td>Resource URI</td>
<td><code>/api/auth/token/app/operation/detail/claim</code></td>
</tr>
</table>
<!-- end -->

#### Request

- Headers:
- `Content-Type: application/json`
- `Accept-Language: en-US`
- `X-PowerAuth-Authorization: ...`

```json
{
"requestObject": {
"id": "7e0ba60f-bf22-4ff5-b999-2733784e5eaa",
"userId": "user12345"
}
}
```

#### Response 200

```json
{
"status": "OK",
"responseObject": {
"id": "7e0ba60f-bf22-4ff5-b999-2733784e5eaa",
"name": "authorize_payment",
"data": "A1*A100CZK*Q238400856/0300**D20190629*NUtility Bill Payment - 05/2019",
"status": "PENDING",
"operationCreated": "2018-07-02T14:43:13+0000",
"operationExpires": "2018-07-02T14:48:17+0000",
"allowedSignatureType": {
"type": "2FA",
"variants": [
"possession_knowledge",
"possession_biometry"
]
},
"formData": {
"title": "Confirm Payment",
"message": "Hello,\nplease confirm following payment:",
"attributes": [
{
"type": "ALERT",
"alertType": "WARNING",
"id": "operation.warning",
"label": "Balance alert",
"title": "Insufficient Balance",
"message": "You have only $1.00 on your account with number 238400856/0300."
},
{
"type": "HEADING",
"id": "operation.heading",
"label": "Utility Payment"
},
{
"type": "AMOUNT",
"id": "operation.amount",
"label": "Amount",
"amount": 2199.40,
"currency": "CZK",
"amountFormatted": "2199,40",
"currencyFormatted": ""
},
{
"type": "AMOUNT_CONVERSION",
"id": "operation.conversion",
"label": "Conversion Rate",
"dynamic": false,
"sourceAmount": 100.00,
"sourceCurrency": "USD",
"sourceAmountFormatted": "100.00",
"sourceCurrencyFormatted": "$",
"sourceValueFormatted": "$100.00",
"targetAmount": 2199.40,
"targetCurrency": "CZK",
"targetAmountFormatted": "2199,40",
"targetCurrencyFormatted": "",
"targetValueFormatted": "2199,40 Kč"
},
{
"type": "KEY_VALUE",
"id": "operation.account",
"label": "To Account",
"value": "238400856/0300"
},
{
"type": "KEY_VALUE",
"id": "operation.dueDate",
"label": "Due Date",
"value": "Jun 29, 2019"
},
{
"type": "NOTE",
"id": "operation.note",
"label": "Note",
"note": "Utility Bill Payment - 05/2019"
},
{
"type": "IMAGE",
"id": "operation.image",
"label": "Payment Check Preview",
"thumbnailUrl": "https://example.com/thumbnail.png",
"originalUrl": "https://example.com/image.png"
},
{
"type": "PARTY_INFO",
"id": "operation.partyInfo",
"label": "Application",
"partyInfo": {
"logoUrl": "https://itesco.cz/img/logo/logo.svg",
"name": "Tesco",
"description": "Find out more about Tesco...",
"websiteUrl": "https://itesco.cz/hello"
}
}
]
}
}
}
```
<!-- end -->

<!-- begin api POST /api/auth/token/app/operation/history -->
### Get History of Operations

Expand Down
34 changes: 25 additions & 9 deletions docs/onboarding/Configuration-Properties.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ The Onboarding Server uses the following public configuration properties:
| `spring.datasource.username` | `powerauth` | Database JDBC username |
| `spring.datasource.password` | `_empty_` | Database JDBC password |
| `spring.datasource.driver-class-name` | `org.postgresql.Driver` | Datasource JDBC class name |
| `spring.jpa.database-platform` | `org.hibernate.dialect.PostgreSQLDialect` | Database dialect |
| `spring.jpa.hibernate.ddl-auto` | `none` | Configuration of automatic database schema creation |
| `spring.jpa.properties.hibernate.connection.characterEncoding` | `utf8` | Character encoding |
| `spring.jpa.properties.hibernate.connection.useUnicode` | `true` | Character encoding - Unicode support |
Expand Down Expand Up @@ -75,7 +74,7 @@ The Onboarding Server uses the following public configuration properties:

| Property | Default | Note |
|---|---|---|
| `enrollment-server-onboarding.document-verification.provider` | `mock` | Document verification provider (`mock`, `zenid`). |
| `enrollment-server-onboarding.document-verification.provider` | `mock` | Document verification provider (`mock`, `zenid`, `innovatrics`). |
| `enrollment-server-onboarding.document-verification.cleanupEnabled` | `false` | Whether document cleanup is enabled for the provider. |
| `enrollment-server-onboarding.document-verification.checkInProgressDocumentSubmits` | `0/5 * * * * *` | Cron scheduler for checking status of submitted documents. |
| `enrollment-server-onboarding.document-verification.checkDocumentsVerifications.cron` | `0/5 * * * * *` | Cron scheduler for checking pending document verifications. |
Expand All @@ -88,7 +87,7 @@ The Onboarding Server uses the following public configuration properties:
| Property | Default | Note |
|--------------------------------------------------------------------------------|---------|----------------------------------------------------------------------------------------|
| `enrollment-server-onboarding.presence-check.enabled` | `true` | Whether presence check provider is enabled. |
| `enrollment-server-onboarding.presence-check.provider` | `mock` | Presence check provider (`mock`, `iproov`). |
| `enrollment-server-onboarding.presence-check.provider` | `mock` | Presence check provider (`mock`, `iproov`, `innovatrics`). |
| `enrollment-server-onboarding.presence-check.cleanupEnabled` | `false` | Whether cleanup of presence check data is enabled. |
| `enrollment-server-onboarding.presence-check.verifySelfieWithDocumentsEnabled` | `false` | Whether verification of the presence check selfie photo with the documents is enabled. |
| `enrollment-server-onboarding.presence-check.max-failed-attempts` | `5` | Maximum failed attempts for presence check and OTP verification. |
Expand Down Expand Up @@ -128,12 +127,29 @@ The Onboarding Server uses the following public configuration properties:
| `enrollment-server-onboarding.presence-check.iproov.oAuthClientUsername` | | OAuth client username to iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.oAuthClientPassword` | | OAuth client password to iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.acceptInvalidSslCertificate` | `false` | Whether invalid SSL certificate is accepted when calling Zen ID REST service. |
| `enrollment-server-onboarding.document-verification.zenid.restClientConfig.maxInMemorySize` | `10485760` | Maximum in memory size of HTTP requests when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.zenid.restClientConfig.proxyEnabled` | `false` | Whether proxy server is enabled when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.zenid.restClientConfig.proxyHost` | | Proxy host to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.zenid.restClientConfig.proxyPort` | 0 | Proxy port to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.zenid.restClientConfig.proxyUsername` | | Proxy username to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.zenid.restClientConfig.proxyPassword` | | Proxy password to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.maxInMemorySize` | `10485760` | Maximum in memory size of HTTP requests when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.proxyEnabled` | `false` | Whether proxy server is enabled when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.proxyHost` | | Proxy host to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.proxyPort` | 0 | Proxy port to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.proxyUsername` | | Proxy username to be used when calling iProov REST service. |
| `enrollment-server-onboarding.presence-check.iproov.restClientConfig.proxyPassword` | | Proxy password to be used when calling iProov REST service. |


## Innovatrics Configuration

| Property | Default | Note |
|--------------------------------------------------------------------------------------------------|---------------------------|--------------------------------------------------------------------------------|
| `enrollment-server-onboarding.provider.innovatrics.serviceBaseUrl` | | Base REST service URL for Innovatrics. |
| `enrollment-server-onboarding.provider.innovatrics.serviceToken` | | Authentication token for Innovatrics. |
| `enrollment-server-onboarding.provider.innovatrics.serviceUserAgent` | `Wultra/OnboardingServer` | User agent to use when making HTTP calls to Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.acceptInvalidSslCertificate` | `false` | Whether invalid SSL certificate is accepted when calling Zen ID REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.maxInMemorySize` | `10485760` | Maximum in memory size of HTTP requests when calling Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.proxyEnabled` | `false` | Whether proxy server is enabled when calling Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.proxyHost` | | Proxy host to be used when calling Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.proxyPort` | 0 | Proxy port to be used when calling Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.proxyUsername` | | Proxy username to be used when calling Innovatrics REST service. |
| `enrollment-server-onboarding.provider.innovatrics.restClientConfig.proxyPassword` | | Proxy password to be used when calling Innovatrics REST service. |


## Correlation HTTP Header Configuration

Expand Down
Loading

0 comments on commit cf374af

Please sign in to comment.