Java 类org.bouncycastle.asn1.cryptopro.GOST3410ParamSetParameters 实例源码

项目:ipack    文件:GOST3410ParameterSpec.java   
public GOST3410ParameterSpec(
    String  keyParamSetID,
    String  digestParamSetOID,
    String  encryptionParamSetOID)
{
    GOST3410ParamSetParameters  ecP = null;

    try
    {
        ecP = GOST3410NamedParameters.getByOID(new ASN1ObjectIdentifier(keyParamSetID));
    }
    catch (IllegalArgumentException e)
    {
        ASN1ObjectIdentifier oid = GOST3410NamedParameters.getOID(keyParamSetID);
        if (oid != null)
        {
            keyParamSetID = oid.getId();
            ecP = GOST3410NamedParameters.getByOID(oid);
        }
    }

    if (ecP == null)
    {
        throw new IllegalArgumentException("no key parameter set for passed in name/OID.");
    }

    this.keyParameters = new GOST3410PublicKeyParameterSetSpec(
                                    ecP.getP(),
                                    ecP.getQ(),
                                    ecP.getA());

    this.keyParamSetOID = keyParamSetID;
    this.digestParamSetOID = digestParamSetOID;
    this.encryptionParamSetOID = encryptionParamSetOID;
}
项目:Aki-SSL    文件:GOST3410ParameterSpec.java   
public GOST3410ParameterSpec(
    String  keyParamSetID,
    String  digestParamSetOID,
    String  encryptionParamSetOID)
{
    GOST3410ParamSetParameters  ecP = null;

    try
    {
        ecP = GOST3410NamedParameters.getByOID(new ASN1ObjectIdentifier(keyParamSetID));
    }
    catch (IllegalArgumentException e)
    {
        ASN1ObjectIdentifier oid = GOST3410NamedParameters.getOID(keyParamSetID);
        if (oid != null)
        {
            keyParamSetID = oid.getId();
            ecP = GOST3410NamedParameters.getByOID(oid);
        }
    }

    if (ecP == null)
    {
        throw new IllegalArgumentException("no key parameter set for passed in name/OID.");
    }

    this.keyParameters = new GOST3410PublicKeyParameterSetSpec(
                                    ecP.getP(),
                                    ecP.getQ(),
                                    ecP.getA());

    this.keyParamSetOID = keyParamSetID;
    this.digestParamSetOID = digestParamSetOID;
    this.encryptionParamSetOID = encryptionParamSetOID;
}
项目:CryptMeme    文件:GOST3410ParameterSpec.java   
public GOST3410ParameterSpec(
    String  keyParamSetID,
    String  digestParamSetOID,
    String  encryptionParamSetOID)
{
    GOST3410ParamSetParameters  ecP = null;

    try
    {
        ecP = GOST3410NamedParameters.getByOID(new ASN1ObjectIdentifier(keyParamSetID));
    }
    catch (IllegalArgumentException e)
    {
        ASN1ObjectIdentifier oid = GOST3410NamedParameters.getOID(keyParamSetID);
        if (oid != null)
        {
            keyParamSetID = oid.getId();
            ecP = GOST3410NamedParameters.getByOID(oid);
        }
    }

    if (ecP == null)
    {
        throw new IllegalArgumentException("no key parameter set for passed in name/OID.");
    }

    this.keyParameters = new GOST3410PublicKeyParameterSetSpec(
                                    ecP.getP(),
                                    ecP.getQ(),
                                    ecP.getA());

    this.keyParamSetOID = keyParamSetID;
    this.digestParamSetOID = digestParamSetOID;
    this.encryptionParamSetOID = encryptionParamSetOID;
}
项目:irma_future_id    文件:GOST3410ParameterSpec.java   
public GOST3410ParameterSpec(
    String  keyParamSetID,
    String  digestParamSetOID,
    String  encryptionParamSetOID)
{
    GOST3410ParamSetParameters  ecP = null;

    try
    {
        ecP = GOST3410NamedParameters.getByOID(new ASN1ObjectIdentifier(keyParamSetID));
    }
    catch (IllegalArgumentException e)
    {
        ASN1ObjectIdentifier oid = GOST3410NamedParameters.getOID(keyParamSetID);
        if (oid != null)
        {
            keyParamSetID = oid.getId();
            ecP = GOST3410NamedParameters.getByOID(oid);
        }
    }

    if (ecP == null)
    {
        throw new IllegalArgumentException("no key parameter set for passed in name/OID.");
    }

    this.keyParameters = new GOST3410PublicKeyParameterSetSpec(
                                    ecP.getP(),
                                    ecP.getQ(),
                                    ecP.getA());

    this.keyParamSetOID = keyParamSetID;
    this.digestParamSetOID = digestParamSetOID;
    this.encryptionParamSetOID = encryptionParamSetOID;
}
项目:bc-java    文件:GOST3410ParameterSpec.java   
public GOST3410ParameterSpec(
    String  keyParamSetID,
    String  digestParamSetOID,
    String  encryptionParamSetOID)
{
    GOST3410ParamSetParameters  ecP = null;

    try
    {
        ecP = GOST3410NamedParameters.getByOID(new ASN1ObjectIdentifier(keyParamSetID));
    }
    catch (IllegalArgumentException e)
    {
        ASN1ObjectIdentifier oid = GOST3410NamedParameters.getOID(keyParamSetID);
        if (oid != null)
        {
            keyParamSetID = oid.getId();
            ecP = GOST3410NamedParameters.getByOID(oid);
        }
    }

    if (ecP == null)
    {
        throw new IllegalArgumentException("no key parameter set for passed in name/OID.");
    }

    this.keyParameters = new GOST3410PublicKeyParameterSetSpec(
                                    ecP.getP(),
                                    ecP.getQ(),
                                    ecP.getA());

    this.keyParamSetOID = keyParamSetID;
    this.digestParamSetOID = digestParamSetOID;
    this.encryptionParamSetOID = encryptionParamSetOID;
}