public class BarretoNaehrigBilinearGroupImpl extends java.lang.Object implements BilinearGroupImpl
For BN curves, \(\mathbb{G}_1\), \(\mathbb{G}_2\), and \(\mathbb{G}_T\) are defined based on:
| Modifier and Type | Field and Description |
|---|---|
protected int[] |
minimumGroupBitSize |
protected int[] |
securityLimits |
| Constructor and Description |
|---|
BarretoNaehrigBilinearGroupImpl(BarretoNaehrigParameterSpec spec) |
BarretoNaehrigBilinearGroupImpl(int securityParameter) |
BarretoNaehrigBilinearGroupImpl(Representation representation) |
BarretoNaehrigBilinearGroupImpl(java.lang.String spec) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object o) |
BilinearMapImpl |
getBilinearMap()
Returns the
BilinearMapImpl (contains the pairing operation) belonging to this BilinearGroupImpl. |
GroupImpl |
getG1()
Returns the source group G1 implementation associated with this bilinear group implementation.
|
GroupImpl |
getG2()
Returns the source group G2 implementation associated with this bilinear group implementation.
|
GroupImpl |
getGT()
Returns the target group G2 implementation associated with this bilinear group implementation.
|
HashIntoGroupImpl |
getHashIntoG1()
Retrieves a hash function implementation that maps byte arrays to G1.
|
HashIntoGroupImpl |
getHashIntoG2()
Retrieves a hash function implementation that maps byte arrays to G2.
|
HashIntoGroupImpl |
getHashIntoGT()
Retrieves a hash function implementation that maps byte arrays to GT.
|
GroupHomomorphismImpl |
getHomomorphismG2toG1()
This functions throws an exception because for type 3 pairings there is no efficient homomorphism
H : G2 -> G1. |
BilinearGroup.Type |
getPairingType() |
Representation |
getRepresentation()
The representation of this object.
|
java.lang.Integer |
getSecurityLevel() |
int |
hashCode() |
protected void |
init(int groupBitSize)
Construct all required objects based on a given group size.
|
java.lang.String |
toString() |
protected final int[] securityLimits
protected final int[] minimumGroupBitSize
public BarretoNaehrigBilinearGroupImpl(int securityParameter)
public BarretoNaehrigBilinearGroupImpl(java.lang.String spec)
public BarretoNaehrigBilinearGroupImpl(BarretoNaehrigParameterSpec spec)
public BarretoNaehrigBilinearGroupImpl(Representation representation)
public Representation getRepresentation()
RepresentableReprUtilgetRepresentation in interface RepresentableRepresentationpublic GroupImpl getG1()
BilinearGroupImplgetG1 in interface BilinearGroupImplpublic GroupImpl getG2()
BilinearGroupImplgetG2 in interface BilinearGroupImplpublic GroupImpl getGT()
BilinearGroupImplgetGT in interface BilinearGroupImplpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic BilinearMapImpl getBilinearMap()
BilinearGroupImplBilinearMapImpl (contains the pairing operation) belonging to this BilinearGroupImpl.getBilinearMap in interface BilinearGroupImplpublic HashIntoGroupImpl getHashIntoG1() throws java.lang.UnsupportedOperationException
BilinearGroupImplgetHashIntoG1 in interface BilinearGroupImpljava.lang.UnsupportedOperationException - if no such hash function exists or the bilinear group is not configured
to support such functionalitypublic HashIntoGroupImpl getHashIntoG2()
BilinearGroupImplgetHashIntoG2 in interface BilinearGroupImplpublic HashIntoGroupImpl getHashIntoGT()
BilinearGroupImplgetHashIntoGT in interface BilinearGroupImplpublic java.lang.Integer getSecurityLevel()
getSecurityLevel in interface BilinearGroupImplpublic BilinearGroup.Type getPairingType()
getPairingType in interface BilinearGroupImplpublic GroupHomomorphismImpl getHomomorphismG2toG1()
H : G2 -> G1.getHomomorphismG2toG1 in interface BilinearGroupImplpublic java.lang.String toString()
toString in class java.lang.Objectprotected void init(int groupBitSize)
Basically implements Algorithm 2.1 of [1]