26 lines
933 B
Java
26 lines
933 B
Java
|
package org.bouncycastle.crypto.tls;
|
||
|
|
||
|
import org.bouncycastle.crypto.DSA;
|
||
|
import org.bouncycastle.crypto.params.AsymmetricKeyParameter;
|
||
|
import org.bouncycastle.crypto.params.DSAPublicKeyParameters;
|
||
|
import org.bouncycastle.crypto.signers.DSASigner;
|
||
|
import org.bouncycastle.crypto.signers.HMacDSAKCalculator;
|
||
|
|
||
|
/* loaded from: classes6.dex */
|
||
|
public class TlsDSSSigner extends TlsDSASigner {
|
||
|
@Override // org.bouncycastle.crypto.tls.TlsDSASigner
|
||
|
protected short getSignatureAlgorithm() {
|
||
|
return (short) 2;
|
||
|
}
|
||
|
|
||
|
@Override // org.bouncycastle.crypto.tls.TlsSigner
|
||
|
public boolean isValidPublicKey(AsymmetricKeyParameter asymmetricKeyParameter) {
|
||
|
return asymmetricKeyParameter instanceof DSAPublicKeyParameters;
|
||
|
}
|
||
|
|
||
|
@Override // org.bouncycastle.crypto.tls.TlsDSASigner
|
||
|
protected DSA createDSAImpl(short s) {
|
||
|
return new DSASigner(new HMacDSAKCalculator(TlsUtils.createHash(s)));
|
||
|
}
|
||
|
}
|