OpenSSL - Neither PUB key nor PRIV key:: nested asn1 error

前端 未结 4 529
名媛妹妹
名媛妹妹 2021-01-05 08:48

I am trying to initialize OpenSSL::PKey::RSA using a public key, and it is not working.

Following is the key pair:

-----BEGIN RSA PRIVATE KEY-----
MI         


        
4条回答
  •  礼貌的吻别
    2021-01-05 09:28

    Same day I was stuck with the same issue, changing passphrase might help you. So verify your passphrase and change it in notification class.I hope this might help you.

    I have changed in file app/jobs/notification_job.rb

    certificate: Rails.root.join('Your Pem File Name Goes Here'),# required
                    passphrase:  "PASSPHRASE GOES HERE",              # optional
                    gateway:     "gateway.push.apple.com", # optional; See note below.
                    # gateway:     "gateway.sandbox.push.apple.com", # optional; See note below.
    

提交回复
热议问题