Expands template-based permissions into concrete datamanager permissions.
Entries of the form dm:template-<templateID>:<rest> are replaced with one
dm:<dataManagerID>:<rest> per datamanager created from that template (looked up
via getTemplateDataManagers, cached ~5 min). All other permission strings
pass through unchanged. The result is deduplicated while preserving order.
The fdk deliberately does no matching itself (no shiro-trie, no dm: parsing
beyond this expansion): the returned array is still raw data to be fed into your own
matcher on the consumer side. Run raw account permissions through this helper
before matching whenever template grants may be present.
Fail-closed: entries with an invalid (non-v4) template UUID are left untouched, and
if the lookup route fails for a template, its entries stay unexpanded (raw
dm:template-… string) instead of throwing — so a transient outage never silently
widens or drops access.
Expands template-based permissions into concrete datamanager permissions.
Entries of the form
dm:template-<templateID>:<rest>are replaced with onedm:<dataManagerID>:<rest>per datamanager created from that template (looked up via getTemplateDataManagers, cached ~5 min). All other permission strings pass through unchanged. The result is deduplicated while preserving order.The fdk deliberately does no matching itself (no
shiro-trie, nodm:parsing beyond this expansion): the returned array is still raw data to be fed into your own matcher on the consumer side. Run raw account permissions through this helper before matching whenever template grants may be present.Fail-closed: entries with an invalid (non-v4) template UUID are left untouched, and if the lookup route fails for a template, its entries stay unexpanded (raw
dm:template-…string) instead of throwing — so a transient outage never silently widens or drops access.