# # This setup is used to test partial proof part of libabac # # This example shows a very simple delegation of roles by Acme and Osh. # Acme's buy_rockets role includes all of Acme's preferred customers, # Acme's buy_flowers role includes all of Acme's green thumbed customers, # Acme's buy_lumbers role is limited to those who is Acme's contractor, # and Osh's buy_rockets role includes all of Osh's preferred customers. # The setup.py creates the principals and the attr.py creates policy # credentials. # # partial_proof_rt1 # # partial proof checking sequence in libabac # can pLadybug buy_rockets from pAcme ? (fact) # can pLadybug What from pAcme ? (What) # Who can buy_rockets from pAcme ? (Who) # can pLadybug buy_rockets from Whom ? (whom) # can pLadybug What from Whom ? (What_Whom) #[keyid:Acme].role:buy_rockets <- [keyid:Acme].role:preferred_customer #[keyid:Acme].role:preferred_customer <- [keyid:Coyote] #[keyid:Acme].role:buy_flowers([keyid:Burpee]) <- [keyid:Acme].role:green_thumb #[keyid:Acme].role:green_thumb <- [keyid:Ladybug] #[keyid:Acme].role:green_thumb <- [keyid:Granny] #[keyid:Acme].role:buy_lumbers <- [keyid:Acme].role:contractor #[keyid:Acme].role:contractor <- [keyid:Granny] #[keyid:Osh].role:buy_rockets <- [keyid:Osh].role:preferred_customer #[keyid:Osh].role:preferred_customer <- [keyid:Ladybug] #[keyid:Osh].role:preferred_customer <- [keyid:Coyote] # trying quries with next_proof calls, # can coyote buy rockets from Acme ? # can ladybug buy rockets from Acme ? # can ladybug buy rockets from Osh ? # can ladybug buy lumbers from Acme ? # can pooh buy rockets from Osh ? # can pooh buy rockets from Osh ? (with next_proof calls) # can ladybug buy flowers from Acme ? # can pooh buy flowers from Acme ?