mirror of
https://github.com/lux-tel/libsession-util.git
synced 2026-10-30 20:25:11 +00:00
The backend dropped the `{google,apple}_obfuscated_account_id_from_master_pkey`
helpers, so seed_payment.py's [pro_live] seeding died with
`AttributeError: module 'backend' has no attribute
'apple_obfuscated_account_id_from_master_pkey'`.
The account tag each provider attests changed, and the seeded witnessed-payment
row must equal what the backend now recomputes from the request-signed master key
at redeem time (backend.py add_pro_payment):
- Google: the client sets setObfuscatedAccountId to the master pubkey verbatim
(no more sha256), so the id is the raw 32-byte master pubkey -> `bytes(vk)`.
- Apple: appAccountToken = UUID(first 16 bytes of the master pubkey) via
providers.app_store.uuid_from_master_pk, stored lowercased.
Import the Apple provider lazily (its module pulls the Apple SDK) so seeding a
non-Apple payment doesn't require it.
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>