What steps will reproduce the problem?
1. Created Service Account in Google apis
2. Read the key with api client:
Google::APIClient::PKCS12.load_key('client.p12', 'notasecret')
What is the expected output?
none
What do you see instead?
c:/Ruby/lib/ruby/gems/1.9.1/gems/google-api-client-0.5.0/lib/google/api_client/a
uth/pkcs12.rb:43:in `rescue in load_key': Invalid keyfile or passphrase
(ArgumentError)
from c:/Ruby/lib/ruby/gems/1.9.1/gems/google-api-client-0.5.0/lib/google/api_client/auth/pkcs12.rb:34:in `load_key'
What version of the product are you using? On what operating system?
google-api-client (0.5.0) on Windows 7
Please provide any additional information below.
I figured out that the key needs to be read in binary mode when using Windows.
After changing this it worked for me (see attached patch).
Original issue reported on code.google.com by meik.nie...@gmail.com on 6 Dec 2012 at 3:42
Original issue reported on code.google.com by
meik.nie...@gmail.com
on 6 Dec 2012 at 3:42Attachments: