Skip to content

Support OAuth in ContentSync #3600

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

YegorKozlov
Copy link
Contributor

@YegorKozlov YegorKozlov commented Jul 4, 2025

In some AEMaaCS environments, security policies may disallow Basic Auth. In such cases, ContentSync can use an Adobe IMS Technical Account with OAuth.

How it works

  1. Create an AEMaaCS technical account and download the service credentials JSON from the Adobe Dev Console
  2. Convert the service credentials JSON into a com.adobe.acs.commons.adobeio.service.impl.IntegrationServiceImpl.cfg.json OSGi configuration. This can be done via one-liner script:
cat cm-p12345-e9876-integration-1.json | \
jq -r '.integration | {
 "endpoint": ("https://" + .imsEndpoint + "/ims/exchange/jwt"),
 "loginEndpoint": "https://ims-na1.adobelogin.com/c/",
 "privateKey":  .privateKey,
   "clientId":  .technicalAccount.clientId, 
   "clientSecret": .technicalAccount.clientSecret,
   "amcOrgId": .org,
   "techAccountId": .id,
   "adobeLoginClaimKey": ("https://" + .imsEndpoint + "/s/ent_aem_cloud_api")
}' >com.adobe.acs.commons.adobeio.service.impl.IntegrationServiceImpl.cfg.json

which will output

{
  "endpoint": "https://ims-na1.adobelogin.com/ims/exchange/jwt",
  "loginEndpoint": "https://ims-na1.adobelogin.com/c/",
  "privateKey": "************************************",
  "clientId": "cm-p12345-e9876-integration-1",
  "clientSecret": "************************************",
  "amcOrgId": "************************************@AdobeOrg",
  "techAccountId": "************************************@techacct.adobe.com",
  "adobeLoginClaimKey": "https://ims-na1.adobelogin.com/s/ent_aem_cloud_api"
}
  1. deploy the OSGi config and change the Auth type in the host configuration to OAuth:
    image

  2. Ensure the Technical Account User has read access to the content being sync-ed

Copy link

github-actions bot commented Jul 4, 2025

Test Results

 3 006 files  ± 0   3 006 suites  ±0   2h 18m 23s ⏱️ + 9m 33s
 1 920 tests + 3   1 920 ✅ + 3  0 💤 ±0  0 ❌ ±0 
17 280 runs  +27  17 274 ✅ +27  6 💤 ±0  0 ❌ ±0 

Results for commit 68090c2. ± Comparison against base commit 8c395ac.

♻️ This comment has been updated with latest results.

@davidjgonzalez davidjgonzalez merged commit 185c260 into Adobe-Consulting-Services:master Jul 15, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants