Skip to content

IllegalArgumentException: unknown object in getInstance: org.bouncycastle.asn1.DERTaggedObject #213

@IrynaZhumatiy

Description

@IrynaZhumatiy

Hello All,
I use BouncyCastle 1.57 version, the next .jar files:

  • bcprov-ext-jdk15on-1.57.jar
  • bcpkix-jdk15on-1.57.jar
  • bcmail-jdk15on-1.57.jar
  • bcprov-jdk15on-1.57.jar.
    I have some issue during call ASN1Sequence.getInstance.
    My code:
    ASN1Primitive obj = null; try { obj = (new ASN1InputStream(new ByteArrayInputStream(value)).readObject()); } catch (java.io.IOException e) { SystemLog.logException("Failure while getting alternative sequence", e); } ASN1Sequence seq = ASN1Sequence.getInstance(obj);
    I get the exception:
    Caused by: java.lang.IllegalArgumentException: unknown object in getInstance: org.bouncycastle.asn1.DERTaggedObject
    at org.bouncycastle.asn1.ASN1Sequence.getInstance(Unknown Source).

Could you please help me with this?
What I do wrong?
Thanks!

Regards,
Iryna

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions