Passphrase encryption - round III
by Bruno Oliveira
Good morning slackland, yesterday I had a hangout with Matthias and we agreed that the whole key agreement thing would bring more complexity from the developer’s pespective. That’s the reason why the client with airline was dropped.
Here comes the new proposal: https://gist.github.com/abstractj/ef1e3d53619796f4e87e
# Passphrase encryption for UPS
**Note**: This is NOT a replacement for SSL
## Scenario
- Developers wants to upload passphrase and certificate for iOS variants. The passphrase must be stored encrypted and restored in clear while sending messages.
## Jira references
- https://issues.jboss.org/browse/AGPUSH-565 (*Dropped*). After a hangout with Matthias, we agreed that would complicate the developer's workflow.
- https://issues.jboss.org/browse/AGPUSH-358
## Proposal
Today we can't guarantee that our developers will have an [HSM](http://en.wikipedia.org/wiki/Hardware_security_module) to manage encryption keys. Neither we can store the private keys in a separated database, for the push server.
If somehow the database is compromised, private keys could be exposed and most of the sensitive data decrypted.
The suggestion is to make use of a *KDF function* per application to encrypt passphrases, not perfect, but helps (like we did in the past for password reset). Where encryption key means:
```
PK = PBKDF2(Secret Key, Salt)
```
*Secret Key*: In the ideal world, users would be required to provide a password for encryption. In this scenario we don't want them to be prompted to input the password, or add extra parameters to the UPS endpoints. So the suggestion is to provide secret key configured on the server and protected by the ACL's from the operating system
*Salt*: 16 bytes non-deterministic used to encrypt/decrypt the data on the server per application and stored into the database.
![](http://photon.abstractj.org/cdraw_460528_pixels_20140404_103644_20140404_103648.jpg)
### Secret key configuration
The file can be generated and checked if something exists during the application start up.
- config.properties
```
secret_key = "d9eb5171c59a4c817f68b0de27b8c1e340c2341b52cdbc60d3083d4e8958532" \
"18dcc5f589cafde048faec956b61f864b9b5513ff9ce29bf9e5d58b0f234f8e3b"
```
or
- config.json
```
{"secret_key":"d9eb5171c59a4c817f68b0de27b8c1e340c2341b52cdbc60d3083d4e8958532" \
"18dcc5f589cafde048faec956b61f864b9b5513ff9ce29bf9e5d58b0f234f8e3b"}
```
### Sending push messages
Passphrases must be reversible for Apple, that's why we make use of symmetric encryption here.
![](http://photon.abstractj.org/cdraw_537346_pixels_20140404_104245_20140404_104247.jpg)
# REST API
## Register push app
```POST | rest/applications```
### HTTP request
Remain unchanged
### HTTP response
Remain unchanged
## iOS Variant
### HTTP request
Remain unchanged
### HTTP response
Remain unchanged
## Sender
### HTTP request
Remain unchanged
### HTTP response
Remain unchanged
# Clients
No changes at the client side.
Thoughts?
--
abstractj
10 years, 8 months
Community release checklists
by Karel Piwko
Hi,
I've drafted a few checklists for QE to go through for community releases
(UPS, OS Cart, Cordova Push Plugin). I've put them there:
https://gist.github.com/kpiwko/9956724
Any feedback on their content is very welcomed.
As for the location, I think the best way would be to put them directly into
GH repositories, for instance into RELEASE.ad / RELEASE.md file, together with
release process instructions (not existing yet). General testing instructions,
applicable for any project, can go to aerogear-parent or aerogear-testing-tools
and be crosslinked.
Thoughts?
Thanks,
Karel
10 years, 8 months
cordova plugin release
by Erik Jan de Wit
Hi,
I would like to release another version of the cordova push plugin (next week thursday), the major feature will be the new simplified API that is already on the master branch and there have already been successful builds. Releasing it will update the version to 0.0.4 and make it available on the registry, it would also provide a test for the gradle release script.
Cheers,
Erik Jan
10 years, 8 months