• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers

Storing Extract API Credentials Securely in Azure

Explorer ,
Jul 22, 2022 Jul 22, 2022

Copy link to clipboard

Copied

I've been using the extract api locally (really enjoying it) but now I'm read to publish to the server.  How should I go about storing the "pdfservices-api-credentials.json" and "private.key" files securely?  My first thought was keyvault, but I don't see any options for storing json or .key file types...  Has anyone done this? 

 

Screen Shot 2022-07-22 at 9.03.27 PM.png

Thank you!

TOPICS
Authentication , Java SDK

Views

78

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Adobe Employee , Jul 25, 2022 Jul 25, 2022

To add to @Raymond Camden 's comment,

In the sample code there is an example that has those parameters:

Credentials credentials = Credentials.serviceAccountCredentialsBuilder()
                    .withClientId("CLIENT_ID")
                    .withClientSecret("CLIENT_SECRET")
                    .withPrivateKey("PRIVATE_KEY_FILE_CONTENTS")
                    .withOrganizationId("ORGANIZATION_ID")
                    .withAccountId("ACCOUNT_ID")
                    .build();

https://github.com/adobe/pdfservices-java-sdk-samples/blob/master/src/main/java/com/adobe/pdfservices/operation/samples/createpdf/CreatePDFWithInMemoryAuthCredentials.java

...

Likes

Translate

Translate
Adobe Employee ,
Jul 25, 2022 Jul 25, 2022

Copy link to clipboard

Copied

All our SDKs support providing credentials via methods, like .clientId(...) (going by memory here, that's not the exact caall). So in production you would put the values in environment variables and pass them to our code that way.

 

See Python ref here: https://opensource.adobe.com/pdfservices-python-sdk-samples/apidocs/latest/reference/index.html#serv...

 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Jul 25, 2022 Jul 25, 2022

Copy link to clipboard

Copied

LATEST

To add to @Raymond Camden 's comment,

In the sample code there is an example that has those parameters:

Credentials credentials = Credentials.serviceAccountCredentialsBuilder()
                    .withClientId("CLIENT_ID")
                    .withClientSecret("CLIENT_SECRET")
                    .withPrivateKey("PRIVATE_KEY_FILE_CONTENTS")
                    .withOrganizationId("ORGANIZATION_ID")
                    .withAccountId("ACCOUNT_ID")
                    .build();

https://github.com/adobe/pdfservices-java-sdk-samples/blob/master/src/main/java/com/adobe/pdfservice... 

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources