123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- #ifndef EPID_COMMON_TESTHELPER_MEMBER_WRAPPER_TESTHELPER_H_
- #define EPID_COMMON_TESTHELPER_MEMBER_WRAPPER_TESTHELPER_H_
- extern "C" {
- #include "epid/member/api.h"
- }
- class MemberCtxObj {
- public:
-
- explicit MemberCtxObj(GroupPubKey const& pub_key, PrivKey const& priv_key,
- BitSupplier rnd_func, void* rnd_param);
-
- explicit MemberCtxObj(GroupPubKey const& pub_key, PrivKey const& priv_key,
- HashAlg hash_alg, BitSupplier rnd_func,
- void* rnd_param);
-
- explicit MemberCtxObj(BitSupplier rnd_func, void* rnd_param);
-
- explicit MemberCtxObj(MemberParams const* params);
-
- explicit MemberCtxObj(GroupPubKey const& pub_key,
- MembershipCredential const& cred, BitSupplier rnd_func,
- void* rnd_param);
-
- MemberCtxObj(GroupPubKey const& pub_key, PrivKey const& priv_key,
- MemberPrecomp const& precomp, BitSupplier rnd_func,
- void* rnd_param);
-
- MemberCtxObj(GroupPubKey const& pub_key, PrivKey const& priv_key,
- HashAlg hash_alg, MemberPrecomp const& precomp,
- BitSupplier rnd_func, void* rnd_param);
-
- MemberCtxObj(GroupPubKey const& pub_key, MembershipCredential const& cred,
- MemberPrecomp const& precomp, BitSupplier rnd_func,
- void* rnd_param);
-
- MemberCtxObj(GroupPubKey const& pub_key, MembershipCredential const& cred,
- HashAlg hash_alg, BitSupplier rnd_func, void* rnd_param);
-
-
- MemberCtxObj(const MemberCtxObj&) = delete;
- MemberCtxObj& operator=(const MemberCtxObj&) = delete;
-
- ~MemberCtxObj();
-
- MemberCtx* ctx() const;
-
- operator MemberCtx*() const;
-
- operator const MemberCtx*() const;
- private:
-
- MemberCtx* CreateMember(MemberParams const* params) const;
-
- void DeleteMember(MemberCtx** ctx) const;
-
- MemberCtx* ctx_;
- };
- #endif
|