docusign / docusign-objc-client

The Official DocuSign Objective-C Client Library used to interact with the eSign REST API. Send, sign, and approve documents using this client.
https://www.docusign.com/devcenter
MIT License
13 stars 14 forks source link

DSApiClient configure_jwt_authorization_flow pem file issue #17

Closed toseefkhilji closed 4 years ago

toseefkhilji commented 6 years ago

Hi,

I am trying to authorization using jwt flow.

Code

 let docApi = DSApiClient(baseURL: URL(string: DSConstatns.host))
 docApi.configure_jwt_authorization_flow(DSConstatns.integrationKey, userId: DSConstatns.userId, oauthBasePath: DSConstatns.outhBasePath, privateKeyFilename: DSConstatns.privateKeyName, expiresIn: 3600)

But after calling configure_jwt_authorization_flow method, I'm getting pem file loading issue JWTCryptoSecurity error: Error Domain=NSCocoaErrorDomain Code=256 "The file couldn’t be opened."

I have valid pem file, tested my pem file with SdkTestsWithJwtAuth test class, and working fine.

pem file

Please find code at below repo. https://github.com/toseefkhilji/TestJWTSwift.git

Let me know what I'm missing with Pem file.

Thanks.

LarryKlugerDS commented 4 years ago

Will be covered as part of #21