本文整理汇总了C#中Org.BouncyCastle.Asn1.Asn1Encodable类的典型用法代码示例。如果您正苦于以下问题:C# Asn1Encodable类的具体用法?C# Asn1Encodable怎么用?C# Asn1Encodable使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Asn1Encodable类属于Org.BouncyCastle.Asn1命名空间,在下文中一共展示了Asn1Encodable类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: AddExtension
/**
* add a given extension field for the standard extensions tag (tag 3)
* @throws IOException
*/
public virtual void AddExtension(
DerObjectIdentifier oid,
bool critical,
Asn1Encodable extValue)
{
this.AddExtension(oid, critical, extValue.GetEncoded());
}
示例2: CommitmentTypeQualifier
/**
* Creates a new <code>CommitmentTypeQualifier</code> instance.
*
* @param commitmentTypeIdentifier a <code>CommitmentTypeIdentifier</code> value
* @param qualifier the qualifier, defined by the above field.
*/
public CommitmentTypeQualifier(
DerObjectIdentifier commitmentTypeIdentifier,
Asn1Encodable qualifier)
{
this.commitmentTypeIdentifier = commitmentTypeIdentifier;
this.qualifier = qualifier;
}
示例3: OtherKeyAttribute
public OtherKeyAttribute(
DerObjectIdentifier keyAttrId,
Asn1Encodable keyAttr)
{
this.keyAttrId = keyAttrId;
this.keyAttr = keyAttr;
}
示例4: AddExtension
/// <summary>
/// Add an extension to this certificate.
/// </summary>
/// <param name="oid">Its Object Identifier.</param>
/// <param name="critical">Is it critical.</param>
/// <param name="extensionValue">The value.</param>
public void AddExtension(
DerObjectIdentifier oid,
bool critical,
Asn1Encodable extensionValue)
{
extGenerator.AddExtension(oid, critical, extensionValue);
}
示例5: ContentInfo
public ContentInfo(
DerObjectIdentifier contentType,
Asn1Encodable content)
{
this.contentType = contentType;
this.content = content;
}
示例6: OtherRecipientInfo
public OtherRecipientInfo(
DerObjectIdentifier oriType,
Asn1Encodable oriValue)
{
this.oriType = oriType;
this.oriValue = oriValue;
}
示例7: SmimeCapability
public SmimeCapability(
DerObjectIdentifier capabilityID,
Asn1Encodable parameters)
{
this.capabilityID = capabilityID;
this.parameters = parameters;
}
示例8: QCStatement
public QCStatement(
DerObjectIdentifier qcStatementId,
Asn1Encodable qcStatementInfo)
{
this.qcStatementId = qcStatementId;
this.qcStatementInfo = qcStatementInfo;
}
示例9: BerTaggedObject
/**
* @param explicitly true if an explicitly tagged object.
* @param tagNo the tag number for this object.
* @param obj the tagged object.
*/
public BerTaggedObject(
bool explicitly,
int tagNo,
Asn1Encodable obj)
: base(explicitly, tagNo, obj)
{
}
示例10: CertStatus
public CertStatus(
int tagNo,
Asn1Encodable value)
{
this.tagNo = tagNo;
this.value = value;
}
示例11: SetSignatureParameters
internal static void SetSignatureParameters(
ISigner signature,
Asn1Encodable parameters)
{
if (parameters != null && !derNull.Equals(parameters))
{
// TODO Put back in
// AlgorithmParameters sigParams = AlgorithmParameters.GetInstance(signature.getAlgorithm());
//
// try
// {
// sigParams.Init(parameters.ToAsn1Object().GetDerEncoded());
// }
// catch (IOException e)
// {
// throw new SignatureException("IOException decoding parameters: " + e.Message);
// }
//
// if (Platform.EndsWith(signature.getAlgorithm(), "MGF1"))
// {
// try
// {
// signature.setParameter(sigParams.getParameterSpec(PSSParameterSpec.class));
// }
// catch (GeneralSecurityException e)
// {
// throw new SignatureException("Exception extracting parameters: " + e.Message);
// }
// }
}
}
示例12: Asn1TaggedObject
/**
* @param tagNo the tag number for this object.
* @param obj the tagged object.
*/
protected Asn1TaggedObject(
int tagNo,
Asn1Encodable obj)
{
this.explicitly = true;
this.tagNo = tagNo;
this.obj = obj;
}
示例13: DerApplicationSpecific
public DerApplicationSpecific(
int tag,
Asn1Encodable obj)
{
this.tag = tag | Asn1Tags.Constructed;
this.octets = obj.GetDerEncoded();
}
示例14: Asn1TaggedObject
/**
* @param explicitly true if the object is explicitly tagged.
* @param tagNo the tag number for this object.
* @param obj the tagged object.
*/
protected Asn1TaggedObject(
bool explicitly,
int tagNo,
Asn1Encodable obj)
{
this.explicitly = explicitly;
this.tagNo = tagNo;
this.obj = obj;
}
示例15: Asn1OctetString
internal Asn1OctetString(
Asn1Encodable obj)
{
try
{
this.str = obj.GetDerEncoded();
}
catch (IOException e)
{
throw new ArgumentException("Error processing object : " + e.ToString());
}
}