Brent Waters (Pairing-based)

From: “Ciphertext-Policy Attribute-Based Encryption: An Expressive, Efficient, and Provably Secure Realization”, Appendix C.
Published in: 2008
Notes: Security Assumption: parallel q-DBDHE. The sole disadvantage of this scheme is the high number of pairings
that must be computed during the decryption process (2 + N) for N attributes mathing in the key.
  • type: ciphertext-policy attribute-based encryption (public key)
  • setting: Pairing
Authors:J Ayo Akinyele
class abenc_waters09.CPabe09(groupObj)[source]

Bases: charm.toolbox.ABEnc.ABEnc

>>> from charm.toolbox.pairinggroup import PairingGroup,GT
>>> group = PairingGroup('SS512')
>>> cpabe = CPabe09(group)
>>> msg = group.random(GT)
>>> (master_secret_key, master_public_key) = cpabe.setup()
>>> policy = '((ONE or THREE) and (TWO or FOUR))'
>>> attr_list = ['THREE', 'ONE', 'TWO']
>>> secret_key = cpabe.keygen(master_public_key, master_secret_key, attr_list)
>>> cipher_text = cpabe.encrypt(master_public_key, msg, policy)
>>> decrypted_msg = cpabe.decrypt(master_public_key, secret_key, cipher_text)
>>> decrypted_msg == msg
decrypt(pk, sk, ct)[source]
encrypt(pk, M, policy_str)[source]
keygen(pk, msk, attributes)[source]