Examples of Any


Examples of org.mozilla.jss.asn1.ANY

      byte[] tmp = new byte[2 + (((ECFieldFp) params.getCurve().getField())
          .getFieldSize() + 7) / 8];
      tmp[0] = 0x02;
      tmp[1] = (byte) EcCore.fieldElemToBytes(r, params, tmp, 2);
      seq.addElement(new ANY(tmp));

      tmp = new byte[2 + (((ECFieldFp) params.getCurve().getField())
          .getFieldSize() + 7) / 8];
      tmp[0] = 0x02;
      tmp[1] = (byte) EcCore.fieldElemToBytes(s, params, tmp, 2);
      seq.addElement(new ANY(tmp));

      seq.encode(baos);
    } catch (Exception ex) {
      throw new SignatureException("Internal ASN.1 encoding error", ex);
    }
View Full Code Here

Examples of org.omg.CORBA.Any

                   + container.getClassLoader().getParent());
      WebClassLoader wcl = (WebClassLoader)container.getWebClassLoader();
      String codebaseString;
      if (wcl != null && (codebaseString = wcl.getCodebaseString()) != null)
      {
         Any codebase = orb.create_any();
         codebase.insert_string(codebaseString);
         codebasePolicy = orb.create_policy(CodebasePolicy.TYPE, codebase);
         logger.debug("codebasePolicy: " + codebasePolicy);
      }
      else
      {
         logger.debug("Not setting codebase policy, codebase is null");
      }

      // Create csiv2Policy for both home and remote containing IorSecurityConfigMetadata
      Any secPolicy = orb.create_any();
      IorSecurityConfigMetaData securityConfig =
         container.getBeanMetaData().getIorSecurityConfigMetaData();
      // if no security metadata was found, get the default metadata from the registry.
      if (securityConfig == null)
        securityConfig = (IorSecurityConfigMetaData) Registry.lookup(CorbaORBService.IOR_SECURITY_CONFIG);
      secPolicy.insert_Value(securityConfig);
      csiv2Policy = orb.create_policy(CSIv2Policy.TYPE, secPolicy);

      // Create SSLPolicy
      //    (SSL_REQUIRED ensures home and remote IORs
      //     will have port 0 in the primary address)
      boolean sslRequired = false;
      if (securityConfig != null) {
         IorSecurityConfigMetaData.TransportConfig tc =
            securityConfig.getTransportConfig();
         sslRequired =
            tc.getIntegrity() ==
               IorSecurityConfigMetaData.TransportConfig.INTEGRITY_REQUIRED
            || tc.getConfidentiality() ==
               IorSecurityConfigMetaData.TransportConfig.CONFIDENTIALITY_REQUIRED
            || tc.getEstablishTrustInClient() ==
               IorSecurityConfigMetaData.TransportConfig.ESTABLISH_TRUST_IN_CLIENT_REQUIRED;
      }
      Any sslPolicyValue = orb.create_any();
      SSLPolicyValueHelper.insert(
            sslPolicyValue,
            (sslRequired) ? SSLPolicyValue.SSL_REQUIRED
                          : SSLPolicyValue.SSL_NOT_REQUIRED);
      sslPolicy = orb.create_policy(SSL_POLICY_TYPE.value, sslPolicyValue);
View Full Code Here

Examples of org.omg.CORBA.Any

         // Build default SSL component with minimum SSL options
         SSL ssl = new SSL((short) MIN_SSL_OPTIONS, /* supported options */
            (short) 0, /* required options  */
            (short) sslPort);
         ORB orb = ORB.init();
         Any any = orb.create_any();
         SSLHelper.insert(any, ssl);
         byte[] componentData = codec.encode_value(any);
         defaultSSLComponent = new TaggedComponent(TAG_SSL_SEC_TRANS.value,
            componentData);
         // Get the default IOR security metadata from the system registry.
View Full Code Here

Examples of org.w3.x2001.xmlSchema.AnyDocument.Any

        }
        else if (particleCode == SchemaParticle.WILDCARD)
        {
            if (!allowElt)
                state.error("Must be a sequence, choice or all here", XmlErrorContext.EXPLICIT_GROUP_NEEDED, parseTree);
            Any parseAny = (Any)parseTree;
            sPart = new SchemaParticleImpl();
            sPart.setParticleType(SchemaParticle.WILDCARD);
            QNameSet wcset;
            NamespaceList nslist = parseAny.xgetNamespace();
            if (nslist == null)
                wcset = QNameSet.ALL;
            else
                wcset = QNameSet.forWildcardNamespaceString(nslist.getStringValue(), targetNamespace);
            sPart.setWildcardSet(wcset);
            sPart.setWildcardProcess(translateWildcardProcess(parseAny.xgetProcessContents()));
            minOccurs = extractMinOccurs(parseAny.xgetMinOccurs());
            maxOccurs = extractMaxOccurs(parseAny.xgetMaxOccurs());
        }
        else
        {
            Group parseGroup = (Group)parseTree;
            sPart = new SchemaParticleImpl();
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.