Skip to content
This repository has been archived by the owner on Jun 6, 2023. It is now read-only.

NewService API, simplify certificate loading and pushpackage signing APIs. #47

Merged
merged 4 commits into from
Jun 6, 2016

Conversation

nathany
Copy link
Contributor

@nathany nathany commented Jun 4, 2016

  • NewService API extracts topic from cert, closes Extract bundle-id from certificate #22
  • pushpackage: use TLS cert for signing instead of x509 cert and privateKey
  • certificate: return TLS cert directly since it can be used for NewService and pushpackage.Sign
  • reorganize push code

@nathany
Copy link
Contributor Author

nathany commented Jun 4, 2016

@macteo Apologies in the delay in getting to this. Mind doing a quick code review? What do you think of this for the API?

@nathany
Copy link
Contributor Author

nathany commented Jun 6, 2016

After making this change, I realized that I can simplify the pkg.Sign API to use tls.Certificate. I'm going to make those revisions on this branch.

simplifying API for signing and certificate loading
@nathany nathany changed the title NewService API extracts topic from cert NewService API, simplify certificate loading and pushpackage signing APIs. Jun 6, 2016
@nathany nathany merged commit dc4636b into master Jun 6, 2016
@nathany nathany deleted the extract-topic branch June 6, 2016 21:32
@bolshoy
Copy link

bolshoy commented Jun 7, 2016

@nathany there still needs to be a way to specify the notification topic. For example, we have two topics, one regular and one voip. The certificate contains both topics, but when you send the notification you must put a specific topic. At the moment, Apple just adds ".voip" suffix to a voip topic, so a flag can also work.

@nathany
Copy link
Contributor Author

nathany commented Jun 7, 2016

Hm. Okay. So we need to add Topic back to Headers then.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extract bundle-id from certificate
2 participants