what-the-bank/sources/org/bouncycastle/crypto/params/ElGamalParameters.java

46 lines
1.2 KiB
Java

package org.bouncycastle.crypto.params;
import java.math.BigInteger;
import org.bouncycastle.crypto.CipherParameters;
/* loaded from: classes6.dex */
public class ElGamalParameters implements CipherParameters {
private BigInteger g;
private int l;
private BigInteger p;
public int hashCode() {
return (getP().hashCode() ^ getG().hashCode()) + this.l;
}
public BigInteger getP() {
return this.p;
}
public int getL() {
return this.l;
}
public BigInteger getG() {
return this.g;
}
public boolean equals(Object obj) {
if (!(obj instanceof ElGamalParameters)) {
return false;
}
ElGamalParameters elGamalParameters = (ElGamalParameters) obj;
return elGamalParameters.getP().equals(this.p) && elGamalParameters.getG().equals(this.g) && elGamalParameters.getL() == this.l;
}
public ElGamalParameters(BigInteger bigInteger, BigInteger bigInteger2, int i) {
this.g = bigInteger2;
this.p = bigInteger;
this.l = i;
}
public ElGamalParameters(BigInteger bigInteger, BigInteger bigInteger2) {
this(bigInteger, bigInteger2, 0);
}
}