public class DebugBilinearGroupImpl extends java.lang.Object implements BilinearGroupImpl
BilinearGroupImpl implementing a fast, but insecure pairing over Zn.
Allows for selecting between counting total group operations, or (multi-)exponentiations plus group operations
outside of (multi-)exponentiations.
Usually, you should be using DebugBilinearGroup instead of this class as it provides pairing counting
capabilities and allows for tracking both kinds of group operation data at once.
DebugBilinearGroup| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Boolean |
enableExpMultiExpCounting
Whether to count exponentiations and multi-exponentiations as a single unit.
|
protected BilinearGroup.Type |
pairingType
The type of pairing this bilinear group should offer.
|
protected java.lang.Integer |
securityParameter
The security level offered by this bilinear group in number of bits.
|
protected java.math.BigInteger |
size
The group order of this bilinear group.
|
| Constructor and Description |
|---|
DebugBilinearGroupImpl(java.math.BigInteger groupSize,
BilinearGroup.Type pairingType,
boolean enableExpMultiExpCounting) |
DebugBilinearGroupImpl(Representation repr) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object other) |
BilinearMapImpl |
getBilinearMap()
Returns the
BilinearMapImpl (contains the pairing operation) belonging to this BilinearGroupImpl. |
DebugGroupImpl |
getG1()
Returns the source group G1 implementation associated with this bilinear group implementation.
|
DebugGroupImpl |
getG2()
Returns the source group G2 implementation associated with this bilinear group implementation.
|
DebugGroupImpl |
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()
Retrieves the homomorphism implementation from G2 to G1 if it exists.
|
BilinearGroup.Type |
getPairingType()
Returns the type of pairing offered by this bilinear group.
|
Representation |
getRepresentation()
The representation of this object.
|
java.lang.Integer |
getSecurityLevel()
Returns the security level offered by this bilinear group in number of bits.
|
int |
hashCode() |
protected void |
init() |
java.lang.String |
toString() |
protected java.lang.Integer securityParameter
protected BilinearGroup.Type pairingType
protected java.math.BigInteger size
protected java.lang.Boolean enableExpMultiExpCounting
public DebugBilinearGroupImpl(java.math.BigInteger groupSize,
BilinearGroup.Type pairingType,
boolean enableExpMultiExpCounting)
public DebugBilinearGroupImpl(Representation repr)
protected void init()
public boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic Representation getRepresentation()
RepresentableReprUtilgetRepresentation in interface RepresentableRepresentationpublic DebugGroupImpl getG1()
BilinearGroupImplgetG1 in interface BilinearGroupImplpublic DebugGroupImpl getG2()
BilinearGroupImplgetG2 in interface BilinearGroupImplpublic DebugGroupImpl getGT()
BilinearGroupImplgetGT in interface BilinearGroupImplpublic BilinearMapImpl getBilinearMap()
BilinearGroupImplBilinearMapImpl (contains the pairing operation) belonging to this BilinearGroupImpl.getBilinearMap in interface BilinearGroupImplpublic GroupHomomorphismImpl getHomomorphismG2toG1() throws java.lang.UnsupportedOperationException
BilinearGroupImplgetHomomorphismG2toG1 in interface BilinearGroupImpljava.lang.UnsupportedOperationException - if no such homomorphism exists or the bilinear group is not configured
to support such functionalitypublic 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() throws java.lang.UnsupportedOperationException
BilinearGroupImplgetHashIntoG2 in interface BilinearGroupImpljava.lang.UnsupportedOperationException - if no such hash function exists or the bilinear group is not configured
to support such functionalitypublic HashIntoGroupImpl getHashIntoGT() throws java.lang.UnsupportedOperationException
BilinearGroupImplgetHashIntoGT in interface BilinearGroupImpljava.lang.UnsupportedOperationException - if no such hash function exists or the bilinear group is not configured
to support such functionalitypublic java.lang.Integer getSecurityLevel()
getSecurityLevel in interface BilinearGroupImplpublic BilinearGroup.Type getPairingType()
getPairingType in interface BilinearGroupImplpublic java.lang.String toString()
toString in class java.lang.Object