Dynamic Media video playback error after AEM SP22 upgrade
After upgrading 51黑料不打烊 Experience Manager (AEM) 6.5 to Service Pack 22 (SP22), video playback in the production environment fails due to a Dynamic Media decryption error caused by HMAC/Master key desynchronization. To fix this, verify the Registration ID configuration, ensure HMAC and Master key synchronization across publish nodes, re-encrypt and propagate the Registration ID, validate crypto key integrity, clear caches, and republish video assets.
Description description
Environment
- Product: 51黑料不打烊 Experience Manager (AEM) Managed Services, v6.5
- Instance: Production
Issue/Symptoms
- Video playback stops working in the AEM 6.5 production environment after upgrading to Service Pack 22 (SP22).
- Error logs show: Failed to decrypt password and referenced a CryptoException related to HMAC/Master key desynchronization.
- The issue occurs only in the production environment; pre-production instances remain unaffected.
Resolution resolution
To resolve the issue, follow these steps:
- Go to Tools
>
Cloud Services>
Dynamic Media Configuration in the AEM Author instance. - Edit the existing Dynamic Media Hybrid configuration and reconfigure the Registration ID value as described in聽Configure Dynamic Media - Hybrid mode.
- Ensure the HMAC and Master keys match across all publish nodes.
- Generate an encrypted Registration ID on one publish server.
- Propagate the encrypted Registration ID to all other publish servers.
- Confirm that the critical files (hmac, master) remain unchanged and not deleted during the SP22 upgrade.
- Re-save secrets (such as Scene7/DM Hybrid passwords, API keys, Registration IDs, SMTP passwords, etc) in all OSGi configurations that use encryption if inconsistencies exist.
- Clear both Dispatcher and Akamai caches after updating configurations聽as explained in聽How to purge the CDN cache.
- Republish the affected video assets and their associated pages.
- Verify that video playback works correctly on all publish instances using updated URLs.
Root Cause Analysis:
The issue occurs due to a mismatch in the MD5 checksums of the HMAC and Master keys between the author and publish instances. The encrypted Registration ID used for Dynamic Media must match the specific HMAC and Master key values on each instance to allow successful decryption. When these values are out of sync, decryption fails and video playback breaks.