Package com.maverick.crypto.asn1

Examples of com.maverick.crypto.asn1.DERObjectIdentifier


      HashSet      set = new HashSet();
      Enumeration    e = extensions.oids();

      while (e.hasMoreElements())
      {
        DERObjectIdentifier  oid = (DERObjectIdentifier)e.nextElement();
        X509Extension    ext = extensions.getExtension(oid);

        if (critical == ext.isCritical())
        {
          set.add(oid.getId());
        }
      }

      return set;
    }
View Full Code Here


  {
    X509Extensions exts = c.getExtensions();

    if (exts != null)
    {
      X509Extension ext = exts.getExtension(new DERObjectIdentifier(oid));

      if (ext != null)
      {
        return ext.getValue().getOctets();
      }
View Full Code Here

      {
        buf.append("   crlEntryExtensions:" + nl);

        while ( e.hasMoreElements() )
        {
          DERObjectIdentifier oid = (DERObjectIdentifier)e.nextElement();
          X509Extension ext = extensions.getExtension(oid);
          buf.append(ext);
        }
      }
    }
View Full Code Here

    }

    public static X9ECParameters getByName(
        String  name)
    {
        DERObjectIdentifier oid = (DERObjectIdentifier)objIds.get(name);

        if (oid != null)
        {
            return (X9ECParameters)curves.get(oid);
        }
View Full Code Here

    public void addExtension(
        String          OID,
        boolean         critical,
        DEREncodable    value)
    {
        this.addExtension(new DERObjectIdentifier(OID), critical, value);
    }
View Full Code Here

    public void addExtension(
        String          OID,
        boolean         critical,
        byte[]          value)
    {
        this.addExtension(new DERObjectIdentifier(OID), critical, value);
    }
View Full Code Here

        PrivateKey          signingKey,
        String              provider)
        throws NoSuchAlgorithmException, NoSuchProviderException,
                InvalidKeyException, SignatureException
    {
        DERObjectIdentifier sigOID = (DERObjectIdentifier)algorithms.get(signatureAlgorithm.toUpperCase());

        if (sigOID == null)
        {
            throw new IllegalArgumentException("Unknown signature type requested");
        }
View Full Code Here

        {
            this.obj = new DERIA5String(name);
        }
        else if (tag == registeredID)
        {
            this.obj = new DERObjectIdentifier(name);
        }
        else if (tag == directoryName)
        {
            this.obj = new X509Name(name);
        }
View Full Code Here

        if (algorithms.containsKey(algorithmName))
        {
            return (DERObjectIdentifier)algorithms.get(algorithmName);
        }
       
        return new DERObjectIdentifier(algorithmName);
    }
View Full Code Here

        cipher.init(1, secretkey, algorithmparameters);
        byte[] abyte1 = cipher.doFinal(in);
        DEROctetString deroctetstring = new DEROctetString(abyte1);
        KeyTransRecipientInfo keytransrecipientinfo = computeRecipientInfo(cert, secretkey.getEncoded());
        DERSet derset = new DERSet(new RecipientInfo(keytransrecipientinfo));
        AlgorithmIdentifier algorithmidentifier = new AlgorithmIdentifier(new DERObjectIdentifier(s), derobject);
        EncryptedContentInfo encryptedcontentinfo =
            new EncryptedContentInfo(PKCSObjectIdentifiers.data, algorithmidentifier, deroctetstring);
        EnvelopedData env = new EnvelopedData(null, derset, encryptedcontentinfo, null);
        ContentInfo contentinfo =
            new ContentInfo(PKCSObjectIdentifiers.envelopedData, env);
View Full Code Here

TOP

Related Classes of com.maverick.crypto.asn1.DERObjectIdentifier

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.