Skip to content

๐Ÿš€ Injecting Data into IL Redisยถ

This guide explains how to manually inject a user record into the IL Redis cluster for troubleshooting or support purposes.

Production Environment

Ensure you have proper authorization before making changes to the production Redis cluster.

๐Ÿš Step 1: Access the Debug Podยถ

Connect to the debug pod in the default namespace:

kubectl exec -it debug -n default -- /bin/sh

๐Ÿ”— Step 2: Connect to Redisยถ

Use the Redis CLI to connect to the IL Redis cluster:

redis-cli -h clustercfg.ub-elasticache-rg.bazj4a.ilc1.cache.amazonaws.com -c

Cluster Mode

The -c flag enables cluster mode support in redis-cli.

๐Ÿงฎ Step 3: Prepare the User Hashยถ

Generate the hash key for the user. For example:

9852A2A60E482CAC67DD73FE3B74962866633DD1319883B4234E674D3D26271C

This is typically calculated as:

SHA3_256(12345/cellcom/Q3dB6dCRGC)

Hash Calculation

Replace 12345, cellcom, and Q3dB6dCRGC with the actual user ID, MNO, and secret as needed.

๐Ÿ“ Step 4: Inject the User Recordยถ

Run the following HSET command in the Redis CLI to inject the user data:

HSET 9852A2A60E482CAC67DD73FE3B74962866633DD1319883B4234E674D3D26271C \
  "approvedConsent" "true" \
  "configurationHash" "" \
  "serverCtr" "00000000" \
  "version" "" \
  "cipherType" "32" \
  "sessionKeys" "1111111111111111111111111111111122222222222222222222222222222222" \
  "optedOut" "false" \
  "lastUpdated" "1723355494221" \
  "baseKeys" "85AE28AD8DCF26AB6EE33E7793633556883BB77125A2B77B0CED1E9F88DCBC5A" \
  "mnoId" "pelephone" \
  "appletCtr" "00000000" \
  "lastOptOutTime" "1720005928410" \
  "activeSessionId" "b8ff6f24-a7cf-458b-9581-f66aa671c8cc" \
  "coolingStartTime" "" \
  "isPopupOverlapsLockScreen" "false" \
  "consentSmsDelivered" "true"

Field Descriptions

  • approvedConsent: Indicates if consent is approved.
  • mnoId: Mobile network operator ID (e.g., pelephone).
  • sessionKeys, baseKeys: Cryptographic keys for the session.
  • Other fields are used for session and consent management.