Ability to separate key cert from SSL connection cert #49

Closed
wants to merge 11 commits into
from

Projects

None yet

2 participants

@mattmichielsen

I added another database field for the private key cert contents, as I needed it for a project where I was only provided different files and couldn't generate the two together. I figured this might be useful for other people in the same situation. Maybe Keycert isn't the best name. What do you think?

@ileitch
Owner
ileitch commented Jun 23, 2012

In what format are you receiving your certificate and key files?

@mattmichielsen

They're both pem files for both the apps that my associate made for his
app. I'm not sure pem is the right extension for the RSA key in the key
file, but basically they didn't follow your advice and export the key and
cert together. Anyway, I'm able to send messages when I reproduce what the
daemon is doing in irb, but I can't seem to get the daemon to work
properly. It seems to be a threading problem, but I haven't been able to
figure it out yet.

On Sat, Jun 23, 2012 at 7:49 PM, Ian Leitch <
reply@reply.github.com

wrote:

In what format are you receiving your certificate and key files?


Reply to this email directly or view it on GitHub:
#49 (comment)

@ileitch
Owner
ileitch commented Jun 24, 2012

Have you tried to merge the files?

openssl pkcs12 -export -inkey openssl_key.pem -in openssl_crt.pem -out combined.p12 -name combined

openssl pkcs12 -nodes -clcerts -in combined.p12 -out <environment>.pem

@mattmichielsen

I combined the key and certificate files and I'm having the same threading
issue (back on the latest gem version of rapns). So I went back to my
version with the extra debugging statements, and it looks like the problem
is with DeliveryQueue never waking up after the @mutex.sleep call in the
pop method. I'll keep messing with it and will let you know if I come up
with a solution.

On Sun, Jun 24, 2012 at 6:54 PM, Ian Leitch <
reply@reply.github.com

wrote:

Have you tried to merge the files?

openssl pkcs12 -export -inkey openssl_key.pem -in openssl_crt.pem -out combined.p12 -name combined

openssl pkcs12 -nodes -clcerts -in combined.p12 -out <environment>.pem


Reply to this email directly or view it on GitHub:
#49 (comment)

@ileitch
Owner
ileitch commented Jun 25, 2012

What version of Ruby are you using?

@mattmichielsen

1.8.7 patch 352 default on latest Ubuntu. I hadn't thought to try a newer
version, but I can definitely try something 1.9.

On Mon, Jun 25, 2012 at 6:16 PM, Ian Leitch <
reply@reply.github.com

wrote:

What version of Ruby are you using?


Reply to this email directly or view it on GitHub:
#49 (comment)

@mattmichielsen

So 1.9.3 patch 194 works as expected, including with my changes and the separate keycert. Thanks for the suggestions!

@ileitch
Owner
ileitch commented Jul 7, 2012

If you are still using 1.8 can you give master a try?

@ileitch ileitch closed this Jul 7, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment