Write ALFA policies
When use cases, attribute dictionaries, and tests are defined, go ahead and create an ALFA policy.
-
First, delete the existing policies that came with the APD example code (
src/authorizationDomain/alfaSpecifications/*). -
Create a new ALFA file in this directory:
namespace acme {policy Main {apply firstApplicablerule {permitcondition acme.role == "manager"}}}tipMake sure to check the ALFA reference documentationOpens in a new tab
-
Iterate on your policy until your tests passes.
tip
It is suggested to take the Axiomatics ALFA coursesOpens in a new tab. Contact Axiomatics Customer SupportOpens in a new tab to get access.