Pairings on type A curves are the fast and ought to be used where the main concern is efficiency. Typically, r should be about 160 bits long and q about 512 bits. In this case, elements of groups G1 and G2 take 512 bits to represent.
The file param/a.param
contains parameters for a type A pairing suitable for
cryptographic use.
The a_param_t data type holds parameters for a type A pairing.
void a_param_init(a_param_t p)-
Initialize
p. This must be called beforepcan be used. void a_param_clear(a_param_t p)-
Clear
p. This should be called afterpis no longer needed. void a_param_gen(a_param_t p,int rbits,int qbits)-
Generate type A pairing parameters and store them in
p, where the group order r isrbitslong, and the order of the base field q isqbitslong. To be secure, generic discrete log algorithms must be infeasible in groups of order r, and finite field discrete log algorithms must be infeasible in finite fields of order q^2. Typical values:rbits= 160,qbits= 512. void a_param_out_str(FILE *stream,a_param_t p)-
Write the parameters in
pin a text format ontostream.