All Downloads are FREE. Search and download functionalities are using the official Maven repository.

OSGI-INF.blueprint.config.xml Maven / Gradle / Ivy

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!--
  Copyright (c) 2013 - 2018 Lijun Liao

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
    xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0">

  <cm:property-placeholder persistent-id="org.xipki.security">
    <cm:default-properties>
      <cm:property name="key.strongrandom.enabled" value="false"/>
      <cm:property name="sign.strongrandom.enabled" value="false"/>
      <cm:property name="hostnameVerifier.enabled" value="false"/>
      <cm:property name="hostnameVerifier.trustAll" value="false"/>
      <cm:property name="hostnameVerifier.commonnameHostMap" value=""/>
      <cm:property name="defaultSignerParallelism" value="32"/>
    </cm:default-properties>
  </cm:property-placeholder>

  <reference id="passwordResolver" interface="org.xipki.password.PasswordResolver"/>

  <bean id="providers" class="org.xipki.security.Providers"
      init-method="init" destroy-method="shutdown"/>


  <bean id="signerFactoryRegister"
       class="org.xipki.security.SignerFactoryRegisterImpl">
  </bean>

  <service ref="signerFactoryRegister"
       interface="org.xipki.security.SignerFactoryRegister"/>
  <reference-list id="signerFactories"
       interface="org.xipki.security.SignerFactory"
       availability="optional">
    <reference-listener ref="signerFactoryRegister" bind-method="bindService"
         unbind-method="unbindService"/>
  </reference-list>

  <bean id="securityFactory" class="org.xipki.security.SecurityFactoryImpl">
    <property name="strongRandom4KeyEnabled" value="${key.strongrandom.enabled}"/>
    <property name="strongRandom4SignEnabled" value="${sign.strongrandom.enabled}"/>
    <property name="defaultSignerParallelism" value="${defaultSignerParallelism}"/>
    <property name="passwordResolver" ref="passwordResolver"/>
    <property name="signerFactoryRegister" ref="signerFactoryRegister"/>
  </bean>
  <service ref="securityFactory" interface="org.xipki.security.SecurityFactory"/>

  <bean id="httpHostnameVerifier" class="org.xipki.security.HttpsHostnameVerifier"
      init-method="init" destroy-method="shutdown">
    <property name="enabled" value="${hostnameVerifier.enabled}"/>
    <property name="trustAll" value="${hostnameVerifier.trustAll}"/>
    <property name="commonnameHostMap" value="${hostnameVerifier.commonnameHostMap}"/>
  </bean>

</blueprint>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy