Examples of SemanticsInformation


Examples of org.bouncycastle.asn1.x509.qualified.SemanticsInformation

          final DERObject obj = getExtensionValue(x509cert, X509Extensions.QCStatements.getId());
          if (obj == null) {
              return null;
          }
          final ASN1Sequence seq = (ASN1Sequence)obj;
          SemanticsInformation si = null;
          // Look through all the QCStatements and see if we have a standard RFC3739 pkixQCSyntax
          for (int i = 0; i < seq.size(); i++) {
            final QCStatement qc = QCStatement.getInstance(seq.getObjectAt(i));
            final DERObjectIdentifier oid = qc.getStatementId();
            if ((oid != null) && (oid.equals(RFC3739QCObjectIdentifiers.id_qcs_pkixQCSyntax_v1) || oid.equals(RFC3739QCObjectIdentifiers.id_qcs_pkixQCSyntax_v2))) {
              // We MAY have a SemanticsInformation object here
              final ASN1Encodable enc = qc.getStatementInfo();
              if (enc != null) {
                si = SemanticsInformation.getInstance(enc);
                // We can break the loop now, we got it!
                break;
              }
            }
          }
          if (si != null) {
            final GeneralName[] gns = si.getNameRegistrationAuthorities();
              if (gns == null) {
                  return null;
              }
              final StringBuilder strBuf = new StringBuilder();
              for (int i = 0; i < gns.length; i++) {
View Full Code Here

Examples of org.bouncycastle.asn1.x509.qualified.SemanticsInformation

  @Override
  public DEREncodable getValue(final UserDataVO subject, final CA ca, final CertificateProfile certProfile, final PublicKey userPublicKey, final PublicKey caPublicKey ) throws CertificateExtentionConfigurationException, CertificateExtensionException {
    DERSequence ret = null;
    final String names = certProfile.getQCStatementRAName();
    final GeneralNames san = CertTools.getGeneralNamesFromAltName(names);
    SemanticsInformation si = null;
    if (san != null) {
      if (StringUtils.isNotEmpty(certProfile.getQCSemanticsId())) {
        si = new SemanticsInformation(new DERObjectIdentifier(certProfile.getQCSemanticsId()), san.getNames());
      } else {
        si = new SemanticsInformation(san.getNames());                    
      }
    } else if (StringUtils.isNotEmpty(certProfile.getQCSemanticsId())) {
      si = new SemanticsInformation(new DERObjectIdentifier(certProfile.getQCSemanticsId()));                
    }
    final ArrayList<QCStatement> qcs = new ArrayList<QCStatement>();
    QCStatement qc = null;
    // First the standard rfc3739 QCStatement with an optional SematicsInformation
    DERObjectIdentifier pkixQcSyntax = RFC3739QCObjectIdentifiers.id_qcs_pkixQCSyntax_v1;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.