Skip to content

Commit

Permalink
Merge pull request #380 from wultra/develop
Browse files Browse the repository at this point in the history
Prepare release 1.0.0
  • Loading branch information
romanstrobl authored Jan 7, 2021
2 parents 4906344 + 66f71f6 commit 2b20e98
Show file tree
Hide file tree
Showing 63 changed files with 1,280 additions and 1,032 deletions.
67 changes: 67 additions & 0 deletions docs/Configuration-Properties.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# Configuration Properties

The Push Server uses the following public configuration properties:

## Database Configuration

| Property | Default | Note |
|---|---|---|
| `spring.datasource.url` | `jdbc:mysql://localhost:3306/powerauth` | Database JDBC URL |
| `spring.datasource.username` | `powerauth` | Database JDBC username |
| `spring.datasource.password` | `_empty_` | Database JDBC passwod |
| `spring.datasource.driver-class-name` | `com.mysql.jdbc.Driver` | Datasource JDBC class name |
| `spring.jpa.properties.hibernate.connection.characterEncoding` | `utf8` | Character encoding |
| `spring.jpa.properties.hibernate.connection.useUnicode` | `true` | Character encoding - Unicode support |


## PowerAuth Service Configuration

| Property | Default | Note |
|---|---|---|
| `powerauth.service.url` | `http://localhost:8080/powerauth-java-server/rest` | PowerAuth service REST API base URL |
| `powerauth.service.security.clientToken` | `_empty_` | PowerAuth REST API authentication token |
| `powerauth.service.security.clientSecret` | `_empty_` | PowerAuth REST API authentication secret / password |
| `powerauth.service.ssl.acceptInvalidSslCertificate` | `false` | Flag indicating if connections using untrusted TLS certificate should be made to the PowerAuth Service |

## PowerAuth Push Service Configuration

| Property | Default | Note |
|---|---|---|
| `powerauth.push.service.applicationName` | `powerauth-push` | Technical name of the instance |
| `powerauth.push.service.applicationDisplayName` | `PowerAuth Push Server` | Display name of the instance |
| `powerauth.push.service.applicationEnvironment` | `_empty_` | Environment identifier |
| `powerauth.push.service.message.storage.enabled` | `false` | Whether persistent storing of sent messages is enabled |
| `powerauth.push.service.registration.multipleActivations.enabled` | `false` | Whether push registration supports "associated activations." |

## PowerAuth Push Campaign Setup

| Property | Default | Note |
|---|---|---|
| `powerauth.push.service.campaign.batchSize` | `100000` | Default batch size for a campaign sending. |


## APNs Configuration

| Property | Default | Note |
|---|---|---|
| `powerauth.push.service.apns.useDevelopment` | `false` | Flag indicating that the development instance of APNS service should be used. |
| `powerauth.push.service.apns.proxy.enabled` | `false` | Flag indicating if the communication needs to go through proxy. |
| `powerauth.push.service.apns.proxy.host` | `127.0.0.1` | Proxy host |
| `powerauth.push.service.apns.proxy.port` | `8080` | Proxy port |
| `powerauth.push.service.apns.proxy.username` | `_empty_` | Proxy username |
| `powerauth.push.service.apns.proxy.password` | `_empty_` | Proxy password |
| `powerauth.push.service.apns.connect.timeout` | `5000` | Push message gateway connect timeout in milliseconds |
| `powerauth.push.service.apns.concurrentConnections` | `1` | Push message concurrency settings |

# FCM Configuration

| Property | Default | Note |
|---|---|---|
| `powerauth.push.service.fcm.proxy.enabled` | `false` | Flag indicating if the communication needs to go through proxy. |
| `powerauth.push.service.fcm.proxy.host` | `127.0.0.1` | Proxy host |
| `powerauth.push.service.fcm.proxy.port` | `8080` | Proxy port |
| `powerauth.push.service.fcm.proxy.username` | `_empty_` | Proxy username |
| `powerauth.push.service.fcm.proxy.password` | `_empty_` | Proxy password |
| `powerauth.push.service.fcm.dataNotificationOnly` | `false` | Flag indicating that FCM service should never use "notification" format, only a data format with extra payload representing the notification. |
| `powerauth.push.service.fcm.sendMessageUrl` | `https://fcm.googleapis.com/v1/projects/%s/messages:send` | Default URL for the FCM service. |
| `powerauth.push.service.fcm.connect.timeout` | `5000` | Push message gateway connect timeout in milliseconds |
14 changes: 7 additions & 7 deletions docs/Deploying-Push-Server.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ As you can see, these credentials are the same as for the PowerAuth Server. You

## Configuration

The default implementation of a PowerAuth Push Server has only one compulsory configuration parameter `powerauth.service.url` that configures the SOAP endpoint location of a PowerAuth Server. The default value for this property points to `localhost`:
The default implementation of a PowerAuth Push Server has only one compulsory configuration parameter `powerauth.service.url` that configures the REST endpoint location of a PowerAuth Server. The default value for this property points to `localhost`:

```bash
powerauth.service.url=http://localhost:8080/powerauth-java-server/soap
powerauth.service.url=http://localhost:8080/powerauth-java-server/rest
```

There are several optional configuration options you may want to set up.
Expand Down Expand Up @@ -104,15 +104,15 @@ In order to run PowerAuth Push server behind the proxy, you simply need to confi

### Disabling SSL Validation During Development

_(optional)_ While this is **strongly discouraged in production environment** (we cannot emphasize this enough), some development environments may use self-signed certificate for HTTPS communication. In case PowerAuth SOAP service uses HTTPS with such certificate, and in case you are not able to correctly configure a custom keystore in your server container, you may disable SSL certificate validation by setting this property:
_(optional)_ While this is **strongly discouraged in production environment** (we cannot emphasize this enough), some development environments may use self-signed certificate for HTTPS communication. In case PowerAuth REST service uses HTTPS with such certificate, and in case you are not able to correctly configure a custom keystore in your server container, you may disable SSL certificate validation by setting this property:

```bash
powerauth.service.ssl.acceptInvalidSslCertificate=true
```

### Setting Up Credentials

_(optional)_ In case PowerAuth Server uses a [restricted access flag in the server configuration](https://github.com/wultra/powerauth-server/blob/develop/docs/Deploying-PowerAuth-Server.md#enabling-powerauth-server-security), you need to configure credentials for the PowerAuth Push Server so that it can connect to the SOAP service:
_(optional)_ In case PowerAuth Server uses a [restricted access flag in the server configuration](https://github.com/wultra/powerauth-server/blob/develop/docs/Deploying-PowerAuth-Server.md#enabling-powerauth-server-security), you need to configure credentials for the PowerAuth Push Server so that it can connect to the REST service:

```sh
powerauth.service.security.clientToken=
Expand All @@ -121,7 +121,7 @@ powerauth.service.security.clientSecret=

The credentials are stored in the `pa_integration` table.

_Note: For SOAP interface, PowerAuth Server uses WS-Security, `UsernameToken` validation (plain text password). The RESTful interface is secured using Basic HTTP Authentication (pre-emptive)._
_Note: The RESTful interface is secured using Basic HTTP Authentication (pre-emptive)._

## Using up ALPN

Expand All @@ -141,7 +141,7 @@ The default configuration works best with Apache Tomcat server running on defaul

To deploy PowerAuth Push Server to Apache Tomcat, simply copy the WAR file in your `webapps` folder or deploy it using the "Tomcat Web Application Manager" application (usually deployed on default Tomcat address `http://localhost:8080/manager`).

*__Important note: Since PowerAuth Push Server is a very simple application with direct access to the PowerAuth Server SOAP services, it must not be under any circumstances published publicly and must be constrained to the in-house closed infrastructure. The only exception to this rule is the requirement to open up ports for the purpose of communication with APNs and FCM services - the push notifications apparently would not work without access to the primary push service providers.__*
*__Important note: Since PowerAuth Push Server is a very simple application with direct access to the PowerAuth Server REST services, it must not be under any circumstances published publicly and must be constrained to the in-house closed infrastructure. The only exception to this rule is the requirement to open up ports for the purpose of communication with APNs and FCM services - the push notifications apparently would not work without access to the primary push service providers.__*

## Outside the Container

Expand All @@ -153,7 +153,7 @@ java -jar powerauth-push-server.war

_Note: You can overwrite the port using `-Dserver.port=8090` parameter to avoid port conflicts._

*__Important note: Since PowerAuth Push Server is a very simple application with direct access to the PowerAuth Server SOAP services, it must not be under any circumstances published publicly and must be constrained to the in-house closed infrastructure. The only exception to this rule is the requirement to open up ports for the purpose of communication with APNs and FCM services - the push notifications apparently would not work without access to the primary push service providers.__*
*__Important note: Since PowerAuth Push Server is a very simple application with direct access to the PowerAuth Server REST services, it must not be under any circumstances published publicly and must be constrained to the in-house closed infrastructure. The only exception to this rule is the requirement to open up ports for the purpose of communication with APNs and FCM services - the push notifications apparently would not work without access to the primary push service providers.__*

## Deploying Push Server On JBoss / Wildfly

Expand Down
2 changes: 1 addition & 1 deletion docs/Deploying-Wildfly.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ Use the `logback.xml` file to configure logging, for example:
The `application-ext.properties` file is used to override default configuration properties, for example:
```
# PowerAuth 2.0 Client configuration
powerauth.service.url=http://[host]:[port]/powerauth-java-server/soap
powerauth.service.url=http://[host]:[port]/powerauth-java-server/rest
```

Push Server Spring application uses the `ext` Spring profile which activates overriding of default properties by `application-ext.properties`.
Expand Down
6 changes: 4 additions & 2 deletions docs/Migration-Instructions.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

This page contains PowerAuth Push Server migration instructions.

- [PowerAuth Push Server 0.21.0](./PowerAuth-Push-Server-0.21.0.md)
- [PowerAuth Push Server 0.22.0](./PowerAuth-Push-Server-0.22.0.md)
- [PowerAuth Push Server 1.0.0](./PowerAuth-Push-Server-1.0.0.md)
- [PowerAuth Push Server 0.24.0](./PowerAuth-Push-Server-0.24.0.md)
- [PowerAuth Push Server 0.23.0](./PowerAuth-Push-Server-0.23.0.md)
- [PowerAuth Push Server 0.22.0](./PowerAuth-Push-Server-0.22.0.md)
- [PowerAuth Push Server 0.21.0](./PowerAuth-Push-Server-0.21.0.md)
9 changes: 9 additions & 0 deletions docs/PowerAuth-Push-Server-1.0.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Migration from 0.24.0 to 1.0.0

## Push Client Migrated to WebClient

Push client now uses WebClient which is an HTTP client based on Spring WebFlux. We made this
change to unify HTTP clients across the whole PowerAuth stack.

In case you use the provided Push client, the Unirest configuration is no longer required, so you can safely
remove any Unirest configuration from your project.
Loading

0 comments on commit 2b20e98

Please sign in to comment.