[KARAF-4863] Trim down the number of configuration files in apache-karaf-minimal and static framework
Project: http://git-wip-us.apache.org/repos/asf/karaf/repo Commit: http://git-wip-us.apache.org/repos/asf/karaf/commit/203cfd8d Tree: http://git-wip-us.apache.org/repos/asf/karaf/tree/203cfd8d Diff: http://git-wip-us.apache.org/repos/asf/karaf/diff/203cfd8d Branch: refs/heads/master Commit: 203cfd8d6b40169d93ddaedcc271a89fff62295d Parents: 78d3712 Author: Guillaume Nodet <[email protected]> Authored: Mon Nov 28 13:38:49 2016 +0100 Committer: Guillaume Nodet <[email protected]> Committed: Mon Nov 28 13:44:43 2016 +0100 ---------------------------------------------------------------------- assemblies/apache-karaf-minimal/pom.xml | 5 + .../etc/org.apache.karaf.features.repos.cfg | 54 --- .../main/resources/resources/etc/jmx.acl.cfg | 73 ---- .../resources/etc/jmx.acl.java.lang.Memory.cfg | 25 -- .../etc/jmx.acl.org.apache.karaf.bundle.cfg | 40 --- .../etc/jmx.acl.org.apache.karaf.config.cfg | 52 --- .../jmx.acl.org.apache.karaf.security.jmx.cfg | 27 -- .../etc/jmx.acl.osgi.compendium.cm.cfg | 53 --- .../etc/org.apache.karaf.command.acl.bundle.cfg | 44 --- .../etc/org.apache.karaf.command.acl.config.cfg | 45 --- .../org.apache.karaf.command.acl.feature.cfg | 30 -- .../etc/org.apache.karaf.command.acl.jaas.cfg | 27 -- .../etc/org.apache.karaf.command.acl.kar.cfg | 27 -- ...rg.apache.karaf.command.acl.scope_bundle.cfg | 31 -- .../etc/org.apache.karaf.command.acl.shell.cfg | 29 -- .../etc/org.apache.karaf.command.acl.system.cfg | 53 --- .../resources/etc/org.apache.karaf.jaas.cfg | 61 ---- .../resources/etc/org.apache.karaf.log.cfg | 36 -- .../etc/org.apache.karaf.management.cfg | 73 ---- .../resources/etc/org.apache.karaf.shell.cfg | 121 ------- .../standard/src/main/feature/feature.xml | 334 ++++++++++++++++++- assemblies/features/static/pom.xml | 7 + .../resources/resources/etc/system.properties | 145 ++++++++ assemblies/test-cxf/pom.xml | 146 ++++++++ .../karaf/features/internal/model/Config.java | 29 +- .../karaf/features/internal/model/Feature.java | 11 + .../service/FeatureConfigInstaller.java | 85 ++--- .../features/internal/model/ConfigTest.java | 47 +++ .../apache/karaf/profile/assembly/Builder.java | 132 ++++++++ .../org/apache/karaf/tooling/AssemblyMojo.java | 9 + 30 files changed, 887 insertions(+), 964 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/apache-karaf-minimal/pom.xml ---------------------------------------------------------------------- diff --git a/assemblies/apache-karaf-minimal/pom.xml b/assemblies/apache-karaf-minimal/pom.xml index f3583df..7f16b70 100644 --- a/assemblies/apache-karaf-minimal/pom.xml +++ b/assemblies/apache-karaf-minimal/pom.xml @@ -138,6 +138,11 @@ <feature>service</feature> <feature>system</feature> </bootFeatures> + <pidsToExtract> + !jmx.acl.*, + !org.apache.karaf.command.acl.*, + * + </pidsToExtract> <javase>1.8</javase> </configuration> </plugin> http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/filtered-resources/resources/etc/org.apache.karaf.features.repos.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/filtered-resources/resources/etc/org.apache.karaf.features.repos.cfg b/assemblies/features/base/src/main/filtered-resources/resources/etc/org.apache.karaf.features.repos.cfg deleted file mode 100644 index d83805b..0000000 --- a/assemblies/features/base/src/main/filtered-resources/resources/etc/org.apache.karaf.features.repos.cfg +++ /dev/null @@ -1,54 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This file describes the features repository URL -# It could be directly installed using feature:repo-add command -# -enterprise=mvn:org.apache.karaf.features/enterprise/${karaf.version}/xml/features -spring=mvn:org.apache.karaf.features/spring/${karaf.version}/xml/features -cellar=mvn:org.apache.karaf.cellar/apache-karaf-cellar/RELEASE/xml/features -cave=mvn:org.apache.karaf.cave/apache-karaf-cave/RELEASE/xml/features -camel=mvn:org.apache.camel.karaf/apache-camel/RELEASE/xml/features -camel-extras=mvn:org.apache-extras.camel-extra.karaf/camel-extra/RELEASE/xml/features -cxf=mvn:org.apache.cxf.karaf/apache-cxf/RELEASE/xml/features -cxf-dosgi=mvn:org.apache.cxf.dosgi/cxf-dosgi/RELEASE/xml/features -cxf-dosgi-samples=mvn:org.apache.cxf.dosgi/cxf-dosgi-samples/RELEASE/xml/features -cxf-xkms=mvn:org.apache.cxf.services.xkms/cxf-services-xkms-features/RELEASE/xml -activemq=mvn:org.apache.activemq/activemq-karaf/RELEASE/xml/features -jclouds=mvn:org.apache.jclouds.karaf/jclouds-karaf/RELEASE/xml/features -openejb=mvn:org.apache.openejb/openejb-feature/RELEASE/xml/features -wicket=mvn:org.ops4j.pax.wicket/features/RELEASE/xml/features -hawtio=mvn:io.hawt/hawtio-karaf/RELEASE/xml/features -pax-cdi=mvn:org.ops4j.pax.cdi/pax-cdi-features/RELEASE/xml/features -pax-jdbc=mvn:org.ops4j.pax.jdbc/pax-jdbc-features/RELEASE/xml/features -pax-jpa=mvn:org.ops4j.pax.jpa/pax-jpa-features/RELEASE/xml/features -pax-web=mvn:org.ops4j.pax.web/pax-web-features/RELEASE/xml/features -pax-wicket=mvn:org.ops4j.pax.wicket/pax-wicket-features/RELEASE/xml/features -ecf=http://download.eclipse.org/rt/ecf/RELEASE/site.p2/karaf-features.xml -decanter=mvn:org.apache.karaf.decanter/apache-karaf-decanter/RELEASE/xml/features -eclipsesource-jaxrs=mvn:com.eclipsesource.jaxrs/features/RELEASE/xml/features -aries-jpa=mvn:org.apache.aries.jpa/jpa-features/RELEASE/xml/features -aries-rsa=mvn:org.apache.aries.rsa/rsa-features/RELEASE/xml/features -hibernate=mvn:org.hibernate/hibernate-osgi/RELEASE/xml/karaf -ignite=mvn:org.apache.ignite/ignite-osgi-karaf/RELEASE/xml/features -openjpa=mvn:org.apache.openjpa/openjpa-features/RELEASE/xml/features - -artemis=mvn:org.apache.activemq/artemis-features/RELEASE/xml/features - http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.cfg deleted file mode 100644 index 531d8c4..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.cfg +++ /dev/null @@ -1,73 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# Generic JMX ACL -# -# This file defines the roles required for MBean operations for MBeans that -# do not have this defined explicitly. -# -# The definition of ACLs for JMX operations works as follows: -# -# The required roles for JMX operations are defined in configuration files -# read via OSGi ConfigAdmin. -# -# JMX RBAC-related configuration is prefixed with jmx.acl and based on the -# JMX ObjectName that it applies to. For example specific configuration for -# an MBean with the following objectName: foo.bar:type=Test can be placed in -# a configuration file called jmx.acl.foo.bar.Test.cfg. More generic -# configuration can be placed in the domain (e.g. jmx.acl.foo.bar.cfg) or -# at the top level (jmx.acl.cfg). A simple configuration file looks like -# this: -# test : admin -# getVal : manager, viewer -# -# The system looks for required roles using the following process: -# The most specific configuration file/pid is tried first. E.g. in the -# above example the jmx.acl.foo.bar.Test.cfg is looked at first. In this -# configuration, the system looks for a: -# 1. Specific match for the current invocation, e.g. test(int)["17"] : role1 -# 2. Reg exp match for the current invocation, e.g. test(int)[/[0-9]/] : role2 -# In both cases the passed argument is converted to a String for the -# comparison. -# If any of the above match all the roles with matching definitions -# are collected and allowed. If no matches are found the following is tried: -# 3. Signature match for the invocation, e.g. test(int) : role3. If -# matched the associated roles are used. -# 4. Method name match for the invocation, e.g. test : role4. If matched -# the associated roles are used. -# 5. A method name wildcard match, e.g. te* : role5. For all the -# wildcard matches found in the current configuration file, the roles -# associated with the longest match are used. So if you have te* and * and -# the method invoked is 'test', then the roles defined with te* are used, -# not the ones defined with *. -# If no matching definition is found in the current configuration file, a -# more general configuration file is looked for. So jmx.acl.foo.bar.cfg is -# tried next, this matches the domain of the MBean. If there is no match -# found in the domain the most generic configuration file is consulted -# (jmx.acl.cfg). -# If a matching definition is found, this is used and the process will not -# look for any other matching definitions. So the most specific definition -# always takes precedence. -# -list* = viewer -get* = viewer -is* = viewer -set* = admin -* = admin \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.java.lang.Memory.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.java.lang.Memory.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.java.lang.Memory.cfg deleted file mode 100644 index a58bcf5..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.java.lang.Memory.cfg +++ /dev/null @@ -1,25 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# JMX ACL specific to the java.lang.Memory MBean -# -# For a description of the format of this file, see jmx.acl.cfg -# -gc = manager http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.bundle.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.bundle.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.bundle.cfg deleted file mode 100644 index dd318d8..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.bundle.cfg +++ /dev/null @@ -1,40 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# JMX ACL specific to the org.apache.karaf:type=bundle,name=* MBean which maps to the Karaf MBean -# to control OSGi bundles. -# -# For a description of the format of this file, see jmx.acl.cfg -# -install = manager -refresh = manager -resolve = manager -restart = manager -setStartLevel(java.lang.String, int)[/([1-4])?[0-9]/,/.*/] = admin -setStartLevel = manager -start(java.lang.String)[/([1-4])?[0-9]/] = admin -start = manager -stop(java.lang.String)[/([1-4])?[0-9]/] = admin -stop = manager -uninstall(java.lang.String)["0"] = #this is a comment, no roles can perform this operation -uninstall = admin -update(java.lang.String)[/([1-4])?[0-9]/] = admin -update(java.lang.String,java.lang.String)[/([1-4])?[0-9]/,/.*/] = admin -update = manager \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.config.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.config.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.config.cfg deleted file mode 100644 index a597112..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.config.cfg +++ /dev/null @@ -1,52 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# JMX ACL specific to the org.apache.karaf:type=config,name=* MBean which maps to the Karaf MBean to interact with the -# OSGi Config Admin service. -# -# For a description of the format of this file, see jmx.acl.cfg -# -# By default, only an admin can make changes to the JMX ACL and shell command rules, but managers can make -# changes to other PIDs. -# -appendProperty(java.lang.String,java.lang.String,java.lang.String)[/jmx[.]acl.*/,/.*/,/.*/] = admin -appendProperty(java.lang.String,java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl.+/,/.*/,/.*/] = admin -appendProperty(java.lang.String,java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl.+/,/.*/,/.*/] = admin -appendProperty(java.lang.String,java.lang.String,java.lang.String) = manager -create(java.lang.String)[/jmx[.]acl.*/] = admin -create(java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl.+/] = admin -create(java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl.+/] = admin -create(java.lang.String) = manager -delete(java.lang.String)[/jmx[.]acl.*/] = admin -delete(java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl.+/] = admin -delete(java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl.+/] = admin -delete(java.lang.String) = manager -deleteProperty(java.lang.String,java.lang.String)[/jmx[.]acl.*/,/.*/] = admin -deleteProperty(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl.+/,/.*/] = admin -deleteProperty(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl.+/,/.*/] = admin -deleteProperty(java.lang.String,java.lang.String) = manager -setProperty(java.lang.String,java.lang.String,java.lang.String)[/jmx[.]acl.*/,/.*/,/.*/] = admin -setProperty(java.lang.String,java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl.+/,/.*/,/.*/] = admin -setProperty(java.lang.String,java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl.+/,/.*/,/.*/] = admin -setProperty(java.lang.String,java.lang.String,java.lang.String) = manager -update(java.lang.String,java.util.Map)[/jmx[.]acl.*/,/.*/] = admin -update(java.lang.String,java.util.Map)[/org[.]apache[.]karaf[.]command[.]acl.+/,/.*/] = admin -update(java.lang.String,java.util.Map)[/org[.]apache[.]karaf[.]service[.]acl.+/,/.*/] = admin -update(java.lang.String,java.util.Map) = manager \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.security.jmx.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.security.jmx.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.security.jmx.cfg deleted file mode 100644 index 0af2c96..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.org.apache.karaf.security.jmx.cfg +++ /dev/null @@ -1,27 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# JMX ACL specific to the org.apache.karaf:type=security,area=jmx MBean which -# can be used to find out whether the currently logged in JMX user can invoke -# the requested JMX operations. -# -# For a description of the format of this file, see jmx.acl.cfg -# -canInvoke = viewer \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.osgi.compendium.cm.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.osgi.compendium.cm.cfg b/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.osgi.compendium.cm.cfg deleted file mode 100644 index 7de362d..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/jmx.acl.osgi.compendium.cm.cfg +++ /dev/null @@ -1,53 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# JMX ACL specific to osgi.compendium.cm MBean -# -# For a description of the format of this file, see jmx.acl.cfg -# -# This configuration file configures the management of ConfigAdmin via the standard ConfigAdmin MBean -# Such that only an admin can make changes to the JMX ACL rules, but managers can make -# changes to other PIDs. -# -createFactoryConfiguration(java.lang.String)[/jmx[.]acl.*/] = admin -createFactoryConfiguration(java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -createFactoryConfiguration(java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -createFactoryConfiguration(java.lang.String) = manager -createFactoryConfigurationForLocation(java.lang.String,java.lang.String)[/jmx[.]acl.*/,/.*/] = admin -createFactoryConfigurationForLocation(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl[.].+/,/.*/] = admin -createFactoryConfigurationForLocation(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl[.].+/,/.*/] = admin -createFactoryConfigurationForLocation(java.lang.String,java.lang.String) = manager -delete(java.lang.String)[/jmx[.]acl.*/] = admin -delete(java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -delete(java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -delete(java.lang.String) = manager -deleteConfigurations = admin -deleteForLocation(java.lang.String,java.lang.String)[/jmx[.]acl.*/,/.*/] = admin -deleteForLocation(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]command[.]acl[.].+/,/.*/] = admin -deleteForLocation(java.lang.String,java.lang.String)[/org[.]apache[.]karaf[.]service[.]acl[.].+/,/.*/] = admin -deleteForLocation(java.lang.String,java.lang.String) = manager -update(java.lang.String,javax.management.openmbean.TabularData)[/jmx[.]acl.*/,/.*/] = admin -update(java.lang.String,javax.management.openmbean.TabularData)[/org[.]apache[.]karaf[.]command[.]acl[.].+/,/.*/] = admin -update(java.lang.String,javax.management.openmbean.TabularData)[/org[.]apache[.]karaf[.]service[.]acl[.].+/,/.*/] = admin -update(java.lang.String,javax.management.openmbean.TabularData) = manager -updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData)[/jmx[.]acl.*/,/.*/,/.*/] = admin -updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData)[/org[.]apache[.]karaf[.]command[.]acl[.].+/,/.*/,/.*/] = admin -updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData)[/org[.]apache[.]karaf[.]service[.]acl[.].+/,/.*/,/.*/] = admin -updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData) = manager \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.bundle.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.bundle.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.bundle.cfg deleted file mode 100644 index d50320e..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.bundle.cfg +++ /dev/null @@ -1,44 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the bundle subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# -# This configuration relies on the fact that 'system' bundles need to be managed -# with the -# -f (--force) -# flag. Operations with -f need admin permission. Most of these operations without -# the 'force' option can be done by a manager. -install = admin -refresh[/.*[-][f].*/] = admin -refresh = manager -restart[/.*[-][f].*/] = admin -restart = manager -start[/.*[-][f].*/] = admin -start = manager -stop[/.*[-][f].*/] = admin -stop = manager -uninstall[/.*[-][f].*/] = admin -uninstall = manager -update[/.*[-][f].*/] = admin -update = manager -watch = admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.config.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.config.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.config.cfg deleted file mode 100644 index e9a5be2..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.config.cfg +++ /dev/null @@ -1,45 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for various commands in the config subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# - -cancel = manager -delete = admin -edit = manager -edit[/.*jmx[.]acl.*/] = admin -edit[/.*org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -edit[/.*org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -property-append = manager -property-append[/.*jmx[.]acl.*/] = admin -property-append[/.*org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -property-append[/.*org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -property-delete = manager -property-delete[/.*jmx[.]acl.*/] = admin -property-delete[/.*org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -property-delete[/.*org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -property-set = manager -property-set[/.*jmx[.]acl.*/] = admin -property-set[/.*org[.]apache[.]karaf[.]command[.]acl[.].+/] = admin -property-set[/.*org[.]apache[.]karaf[.]service[.]acl[.].+/] = admin -update = manager \ No newline at end of file http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.feature.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.feature.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.feature.cfg deleted file mode 100644 index 2987b4c..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.feature.cfg +++ /dev/null @@ -1,30 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the kar subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# -install = admin -uninstall = admin -start = admin -stop = admin -update = admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.jaas.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.jaas.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.jaas.cfg deleted file mode 100644 index 0c0644b..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.jaas.cfg +++ /dev/null @@ -1,27 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the jaas subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# -# Jaas commands commands have no effect until update is called. -update = admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.kar.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.kar.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.kar.cfg deleted file mode 100644 index fd41ab9..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.kar.cfg +++ /dev/null @@ -1,27 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the kar subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# -install = admin -uninstall = admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.scope_bundle.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.scope_bundle.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.scope_bundle.cfg deleted file mode 100644 index 5e909e5..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.scope_bundle.cfg +++ /dev/null @@ -1,31 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for scope bundles -# -features=org.apache.karaf.features.command -jaas=org.apache.karaf.jaas.command -admin=org.apache.karaf.admin.command -osgi=org.apache.karaf.shell.osgi -log=org.apache.karaf.shell.log -packages=org.apache.karaf.shell.packages -config=org.apache.karaf.shell.config -ssh=org.apache.karaf.shell.ssh -shell=org.apache.karaf.shell.commands http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.shell.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.shell.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.shell.cfg deleted file mode 100644 index 2afc19b..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.shell.cfg +++ /dev/null @@ -1,29 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the shell subshell -# -# For an explanation of the syntax of this file, see the file: -# org.apache.karaf.command.acl.system.cfg -# -nano = admin -exec = admin -new = admin -java = admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.system.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.system.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.system.cfg deleted file mode 100644 index 7927798..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.command.acl.system.cfg +++ /dev/null @@ -1,53 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file defines the ACLs for commands in the system subshell -# -# The format of this file is as follows: -# The name of the file corresponds to a Configuration Admin PID. This file is for PID: -# org.apache.karaf.command.acl.system -# The prefix org.apache.karaf.command.acl. determines that this file defines ACLs for karaf -# commands. The last word on the PID declares the scope that it applies to, i.e. this file -# is for the 'system' scope. -# Entries in this file map to commands within the defined scope. The simplest role definition -# has the form: -# command = role1, role2, role3 -# Specific roles can also be declared for certain arguments to the command. This is done using -# regular expression matching. -# All the arguments to the command are represented as a list using the following syntax: -# [arg1,arg2,arg3] -# The matching is done after converting this list into a string. So the line -# start-level[/.*[0-9][0-9][0-9]+.*/] = manager -# declares that a manager role is needed to set a start level with 3 digits or more. The .* -# wildcards at the beginning and end are used to match the '[' and ']' characters surrounding. -# When looking for a match the regular-expression based ACLs are always checked first. If any -# of them match the associated roles are used. -# -# If no match can be found based on reg-exp ACLs, a match is looked for based purely on the -# command name. -# -# If no command-name match can be found it is assumed that the command does not need a specific -# role and can therefore be invoked by any user. - -property = admin -shutdown = admin -start-level[/.*[0-9][0-9][0-9]+.*/] = manager # manager can set startlevels above 100 -start-level[/[^0-9]*/] = viewer # viewer can obtain the current start level -start-level = admin # admin can set any start level, including < 100 http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.jaas.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.jaas.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.jaas.cfg deleted file mode 100644 index 19f3fa0..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.jaas.cfg +++ /dev/null @@ -1,61 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# Boolean enabling / disabling encrypted passwords -# -encryption.enabled = false - -# -# Encryption Service name -# the default one is 'basic' -# a more powerful one named 'jasypt' is available -# when installing the encryption feature -# -encryption.name = - -# -# Encryption prefix -# -encryption.prefix = {CRYPT} - -# -# Encryption suffix -# -encryption.suffix = {CRYPT} - -# -# Set the encryption algorithm to use in Karaf JAAS login module -# Supported encryption algorithms follow: -# MD2 -# MD5 -# SHA-1 -# SHA-256 -# SHA-384 -# SHA-512 -# -encryption.algorithm = MD5 - -# -# Encoding of the encrypted password. -# Can be: -# hexadecimal -# base64 -# -encryption.encoding = hexadecimal http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.log.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.log.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.log.cfg deleted file mode 100644 index f1648da..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.log.cfg +++ /dev/null @@ -1,36 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# This configuration file is used to configure the default values for the log:display -# and log:exception-display commands. -# - -# -# The number of log statements to be displayed using log:display. It also defines the number -# of lines searched for exceptions using log:exception-display. You can override this value -# at runtime using -n in log:display. -# -size = 500 - -# -# The pattern used to format the log statement when using log:display. This pattern is according -# to the log4j layout. You can override this parameter at runtime using log:display with -p. -# -pattern = %d{ISO8601} | %-5.5p | %-16.16t | %-32.32c{1} | %X{bundle.id} - %X{bundle.name} - %X{bundle.version} | %m%n http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.management.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.management.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.management.cfg deleted file mode 100644 index f95c0e3..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.management.cfg +++ /dev/null @@ -1,73 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# The properties in this file define the configuration of Apache Karaf's JMX Management -# - -# -# Port number for RMI registry connection -# -rmiRegistryPort = 1099 - -# -# Host for RMI registry -# -rmiRegistryHost = 127.0.0.1 - -# -# Port number for RMI server connection -# -rmiServerPort = 44444 - -# -# Host for RMI server -# -rmiServerHost = 127.0.0.1 - -# -# Name of the JAAS realm used for authentication -# -jmxRealm = karaf - -# -# The service URL for the JMXConnectorServer -# -serviceUrl = service:jmx:rmi://${rmiServerHost}:${rmiServerPort}/jndi/rmi://${rmiRegistryHost}:${rmiRegistryPort}/karaf-${karaf.name} - -# -# Whether any threads started for the JMXConnectorServer should be started as daemon threads -# -daemon = true - -# -# Whether the JMXConnectorServer should be started in a separate thread -# -threaded = true - -# -# The ObjectName used to register the JMXConnectorServer -# -objectName = connector:name=rmi - -# -# Role name used for JMX access authorization -# If not set, this defaults to the ${karaf.admin.role} configured in etc/system.properties -# -# jmxRole=admin http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.shell.cfg ---------------------------------------------------------------------- diff --git a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.shell.cfg b/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.shell.cfg deleted file mode 100644 index dff3171..0000000 --- a/assemblies/features/base/src/main/resources/resources/etc/org.apache.karaf.shell.cfg +++ /dev/null @@ -1,121 +0,0 @@ -################################################################################ -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You 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. -# -################################################################################ - -# -# These properties are used to configure Karaf's ssh shell. -# - -# -# Via sshPort and sshHost you define the address you can login into Karaf. -# -sshPort = 8101 -sshHost = 0.0.0.0 - -# -# The sshIdleTimeout defines the inactivity timeout to logout the SSH session. -# The sshIdleTimeout is in milliseconds, and the default is set to 30 minutes. -# -sshIdleTimeout = 1800000 - -# -# sshRealm defines which JAAS domain to use for password authentication. -# -sshRealm = karaf - -# -# The location of the hostKey file defines where the private/public key of the server -# is located. If no file is at the defined location it will be ignored. -# -hostKey = ${karaf.etc}/host.key - -# -# The format used for hostKey. -#Â Possible values are simple (Karaf internal), or PEM (OpenSSH format) -# -hostKeyFormat = simple - -# -# Role name used for SSH access authorization -# If not set, this defaults to the ${karaf.admin.role} configured in etc/system.properties -# -# sshRole = admin - -# -# Self defined key size in 1024, 2048, 3072, or 4096 -# If not set, this defaults to 4096. -# -# keySize = 4096 - -# -# Specify host key algorithm, defaults to RSA -# -# algorithm = RSA - -# -# Specify the client log level (default is WARN) -# 0: ERROR -# 1: WARN -# 2: INFO -# 3: DEBUG -# 4: TRACE -# -#logLevel=1 - -# -# Specify an additional welcome banner to be displayed when a user logs into the server. -# -# welcomeBanner = - -# -# Defines the completion mode on the Karaf shell console. The possible values are: -# - GLOBAL: it's the same behavior as in previous Karaf releases. The completion displays all commands and all aliases -# ignoring if you are in a subshell or not. -# - FIRST: the completion displays all commands and all aliases only when you are not in a subshell. When you are -# in a subshell, the completion displays only the commands local to the subshell. -# - SUBSHELL: the completion displays only the subshells on the root level. When you are in a subshell, the completion -# displays only the commands local to the subshell. -# This property define the default value when you use the Karaf shell console. -# You can change the completion mode directly in the shell console, using shell:completion command. -# - -# -# Override allowed SSH cipher algorithms. -# Default: aes128-ctr,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc -# -# ciphers = aes128-ctr,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc - -# -# Override allowed SSH HMAC algorithms. -# Default: hmac-sha2-512,hmac-sha2-256,hmac-sha1 -# -# macs = hmac-sha2-512,hmac-sha2-256,hmac-sha1 - -# -# Override allowed SSH key exchange algorithms. -# Default: diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 -# -# kexAlgorithms = diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 - -# -# Override moduli-url. -# Default: moduli-url not specified to use the internal one from SSHD -# -# moduli-url = external moduli-url users wanna use - -completionMode = GLOBAL http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/standard/src/main/feature/feature.xml ---------------------------------------------------------------------- diff --git a/assemblies/features/standard/src/main/feature/feature.xml b/assemblies/features/standard/src/main/feature/feature.xml index 3a3cdf2..2b4f74a 100644 --- a/assemblies/features/standard/src/main/feature/feature.xml +++ b/assemblies/features/standard/src/main/feature/feature.xml @@ -72,6 +72,41 @@ <feature name="feature" description="Features Support" version="${project.version}"> <bundle start-level="1">mvn:org.apache.karaf.features/org.apache.karaf.features.extension/${project.version}</bundle> <bundle start-level="15">mvn:org.apache.karaf.features/org.apache.karaf.features.core/${project.version}</bundle> + <config name="org.apache.karaf.features.repos"> + # + # This file describes the features repository URL + # It could be directly installed using feature:repo-add command + # + enterprise=mvn:org.apache.karaf.features/enterprise/${karaf.version}/xml/features + spring=mvn:org.apache.karaf.features/spring/${karaf.version}/xml/features + cellar=mvn:org.apache.karaf.cellar/apache-karaf-cellar/RELEASE/xml/features + cave=mvn:org.apache.karaf.cave/apache-karaf-cave/RELEASE/xml/features + camel=mvn:org.apache.camel.karaf/apache-camel/RELEASE/xml/features + camel-extras=mvn:org.apache-extras.camel-extra.karaf/camel-extra/RELEASE/xml/features + cxf=mvn:org.apache.cxf.karaf/apache-cxf/RELEASE/xml/features + cxf-dosgi=mvn:org.apache.cxf.dosgi/cxf-dosgi/RELEASE/xml/features + cxf-dosgi-samples=mvn:org.apache.cxf.dosgi/cxf-dosgi-samples/RELEASE/xml/features + cxf-xkms=mvn:org.apache.cxf.services.xkms/cxf-services-xkms-features/RELEASE/xml + activemq=mvn:org.apache.activemq/activemq-karaf/RELEASE/xml/features + jclouds=mvn:org.apache.jclouds.karaf/jclouds-karaf/RELEASE/xml/features + openejb=mvn:org.apache.openejb/openejb-feature/RELEASE/xml/features + wicket=mvn:org.ops4j.pax.wicket/features/RELEASE/xml/features + hawtio=mvn:io.hawt/hawtio-karaf/RELEASE/xml/features + pax-cdi=mvn:org.ops4j.pax.cdi/pax-cdi-features/RELEASE/xml/features + pax-jdbc=mvn:org.ops4j.pax.jdbc/pax-jdbc-features/RELEASE/xml/features + pax-jpa=mvn:org.ops4j.pax.jpa/pax-jpa-features/RELEASE/xml/features + pax-web=mvn:org.ops4j.pax.web/pax-web-features/RELEASE/xml/features + pax-wicket=mvn:org.ops4j.pax.wicket/pax-wicket-features/RELEASE/xml/features + ecf=http://download.eclipse.org/rt/ecf/RELEASE/site.p2/karaf-features.xml + decanter=mvn:org.apache.karaf.decanter/apache-karaf-decanter/RELEASE/xml/features + eclipsesource-jaxrs=mvn:com.eclipsesource.jaxrs/features/RELEASE/xml/features + aries-jpa=mvn:org.apache.aries.jpa/jpa-features/RELEASE/xml/features + aries-rsa=mvn:org.apache.aries.rsa/rsa-features/RELEASE/xml/features + hibernate=mvn:org.hibernate/hibernate-osgi/RELEASE/xml/karaf + ignite=mvn:org.apache.ignite/ignite-osgi-karaf/RELEASE/xml/features + openjpa=mvn:org.apache.openjpa/openjpa-features/RELEASE/xml/features + artemis=mvn:org.apache.activemq/artemis-features/RELEASE/xml/features + </config> <conditional> <condition>shell</condition> <config name="org.apache.karaf.command.acl.feature"> @@ -80,6 +115,9 @@ # install = admin uninstall = admin + start = admin + stop = admin + update = admin </config> <bundle start-level="30">mvn:org.apache.karaf.features/org.apache.karaf.features.command/${project.version}</bundle> </conditional> @@ -97,11 +135,129 @@ # # This configuration file defines the ACLs for commands in the shell subshell # - edit = admin + nano = admin exec = admin new = admin java = admin </config> + <config name="org.apache.karaf.command.acl.scope_bundle"> + # + # This configuration file defines the ACLs for scope bundles + # + features=org.apache.karaf.features.command + jaas=org.apache.karaf.jaas.command + admin=org.apache.karaf.admin.command + osgi=org.apache.karaf.shell.osgi + log=org.apache.karaf.shell.log + packages=org.apache.karaf.shell.packages + config=org.apache.karaf.shell.config + ssh=org.apache.karaf.shell.ssh + shell=org.apache.karaf.shell.commands + </config> + <config name="org.apache.karaf.shell"> + # + # These properties are used to configure Karaf's ssh shell. + # + + # + # Via sshPort and sshHost you define the address you can login into Karaf. + # + sshPort = 8101 + sshHost = 0.0.0.0 + + # + # The sshIdleTimeout defines the inactivity timeout to logout the SSH session. + # The sshIdleTimeout is in milliseconds, and the default is set to 30 minutes. + # + sshIdleTimeout = 1800000 + + # + # sshRealm defines which JAAS domain to use for password authentication. + # + sshRealm = karaf + + # + # The location of the hostKey file defines where the private/public key of the server + # is located. If no file is at the defined location it will be ignored. + # + hostKey = ${karaf.etc}/host.key + + # + # The format used for hostKey. + #Â Possible values are simple (Karaf internal), or PEM (OpenSSH format) + # + hostKeyFormat = simple + + # + # Role name used for SSH access authorization + # If not set, this defaults to the ${karaf.admin.role} configured in etc/system.properties + # + # sshRole = admin + + # + # Self defined key size in 1024, 2048, 3072, or 4096 + # If not set, this defaults to 4096. + # + # keySize = 4096 + + # + # Specify host key algorithm, defaults to RSA + # + # algorithm = RSA + + # + # Specify the client log level (default is WARN) + # 0: ERROR + # 1: WARN + # 2: INFO + # 3: DEBUG + # 4: TRACE + # + #logLevel=1 + + # + # Specify an additional welcome banner to be displayed when a user logs into the server. + # + # welcomeBanner = + + # + # Defines the completion mode on the Karaf shell console. The possible values are: + # - GLOBAL: it's the same behavior as in previous Karaf releases. The completion displays all commands and all aliases + # ignoring if you are in a subshell or not. + # - FIRST: the completion displays all commands and all aliases only when you are not in a subshell. When you are + # in a subshell, the completion displays only the commands local to the subshell. + # - SUBSHELL: the completion displays only the subshells on the root level. When you are in a subshell, the completion + # displays only the commands local to the subshell. + # This property define the default value when you use the Karaf shell console. + # You can change the completion mode directly in the shell console, using shell:completion command. + # + + # + # Override allowed SSH cipher algorithms. + # Default: aes128-ctr,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc + # + # ciphers = aes128-ctr,arcfour128,aes128-cbc,3des-cbc,blowfish-cbc + + # + # Override allowed SSH HMAC algorithms. + # Default: hmac-sha2-512,hmac-sha2-256,hmac-sha1 + # + # macs = hmac-sha2-512,hmac-sha2-256,hmac-sha1 + + # + # Override allowed SSH key exchange algorithms. + # Default: diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 + # + # kexAlgorithms = diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group-exchange-sha1,diffie-hellman-group1-sha1 + + # + # Override moduli-url. + # Default: moduli-url not specified to use the internal one from SSHD + # + # moduli-url = external moduli-url users wanna use + + completionMode = GLOBAL + </config> <bundle dependency="true" start-level="30">mvn:org.fusesource.jansi/jansi/${jansi.version}</bundle> <bundle dependency="true" start-level="30">mvn:org.jline/jline/${jline.version}</bundle> <bundle start-level="30">mvn:org.apache.karaf.shell/org.apache.karaf.shell.core/${project.version}</bundle> @@ -288,6 +444,50 @@ </feature> <feature name="jaas" description="Provide JAAS support" version="${project.version}"> + <config name="org.apache.karaf.jaas"> + # + # Boolean enabling / disabling encrypted passwords + # + encryption.enabled = false + + # + # Encryption Service name + # the default one is 'basic' + # a more powerful one named 'jasypt' is available + # when installing the encryption feature + # + encryption.name = + + # + # Encryption prefix + # + encryption.prefix = {CRYPT} + + # + # Encryption suffix + # + encryption.suffix = {CRYPT} + + # + # Set the encryption algorithm to use in Karaf JAAS login module + # Supported encryption algorithms follow: + # MD2 + # MD5 + # SHA-1 + # SHA-256 + # SHA-384 + # SHA-512 + # + encryption.algorithm = MD5 + + # + # Encoding of the encrypted password. + # Can be: + # hexadecimal + # base64 + # + encryption.encoding = hexadecimal + </config> <feature>jaas-boot</feature> <bundle start-level="30" start="true">mvn:org.apache.karaf.jaas/org.apache.karaf.jaas.config/${project.version}</bundle> <bundle start-level="30" start="true">mvn:org.apache.karaf.jaas/org.apache.karaf.jaas.modules/${project.version}</bundle> @@ -308,6 +508,25 @@ </feature> <feature name="log" description="Provide Log support" version="${project.version}"> + <config name="org.apache.karaf.log"> + # + # This configuration file is used to configure the default values for the log:display + # and log:exception-display commands. + # + + # + # The number of log statements to be displayed using log:display. It also defines the number + # of lines searched for exceptions using log:exception-display. You can override this value + # at runtime using -n in log:display. + # + size = 500 + + # + # The pattern used to format the log statement when using log:display. This pattern is according + # to the log4j layout. You can override this parameter at runtime using log:display with -p. + # + pattern = %d{ISO8601} | %-5.5p | %-16.16t | %-32.32c{1} | %X{bundle.id} - %X{bundle.name} - %X{bundle.version} | %m%n + </config> <bundle start-level="30" start="true">mvn:org.apache.karaf.log/org.apache.karaf.log.core/${project.version}</bundle> </feature> @@ -327,7 +546,6 @@ # # This configuration file defines the ACLs for commands in the system subshell # - update = admin property = admin shutdown = admin start-level[/.*[0-9][0-9][0-9]+.*/] = manager # manager can set startlevels above 100 @@ -433,6 +651,62 @@ </feature> <feature name="management" description="Provide a JMX MBeanServer and a set of MBeans in Karaf" version="${project.version}"> + <config name="jmx.acl"> + # + # Generic JMX ACL + # + # This file defines the roles required for MBean operations for MBeans that + # do not have this defined explicitly. + # + # The definition of ACLs for JMX operations works as follows: + # + # The required roles for JMX operations are defined in configuration files + # read via OSGi ConfigAdmin. + # + # JMX RBAC-related configuration is prefixed with jmx.acl and based on the + # JMX ObjectName that it applies to. For example specific configuration for + # an MBean with the following objectName: foo.bar:type=Test can be placed in + # a configuration file called jmx.acl.foo.bar.Test.cfg. More generic + # configuration can be placed in the domain (e.g. jmx.acl.foo.bar.cfg) or + # at the top level (jmx.acl.cfg). A simple configuration file looks like + # this: + # test : admin + # getVal : manager, viewer + # + # The system looks for required roles using the following process: + # The most specific configuration file/pid is tried first. E.g. in the + # above example the jmx.acl.foo.bar.Test.cfg is looked at first. In this + # configuration, the system looks for a: + # 1. Specific match for the current invocation, e.g. test(int)["17"] : role1 + # 2. Reg exp match for the current invocation, e.g. test(int)[/[0-9]/] : role2 + # In both cases the passed argument is converted to a String for the + # comparison. + # If any of the above match all the roles with matching definitions + # are collected and allowed. If no matches are found the following is tried: + # 3. Signature match for the invocation, e.g. test(int) : role3. If + # matched the associated roles are used. + # 4. Method name match for the invocation, e.g. test : role4. If matched + # the associated roles are used. + # 5. A method name wildcard match, e.g. te* : role5. For all the + # wildcard matches found in the current configuration file, the roles + # associated with the longest match are used. So if you have te* and * and + # the method invoked is 'test', then the roles defined with te* are used, + # not the ones defined with *. + # If no matching definition is found in the current configuration file, a + # more general configuration file is looked for. So jmx.acl.foo.bar.cfg is + # tried next, this matches the domain of the MBean. If there is no match + # found in the domain the most generic configuration file is consulted + # (jmx.acl.cfg). + # If a matching definition is found, this is used and the process will not + # look for any other matching definitions. So the most specific definition + # always takes precedence. + # + list* = viewer + get* = viewer + is* = viewer + set* = admin + * = admin + </config> <config name="jmx.acl.org.apache.karaf.security.jmx"> # # JMX ACL specific to the org.apache.karaf:type=security,area=jmx MBean which @@ -487,6 +761,62 @@ updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData)[/org[.]apache[.]karaf[.]service[.]acl[.].+/,/.*/,/.*/] = admin updateForLocation(java.lang.String,java.lang.String,javax.management.openmbean.TabularData) = manager </config> + <config name="org.apache.karaf.management"> + # + # The properties in this file define the configuration of Apache Karaf's JMX Management + # + + # + # Port number for RMI registry connection + # + rmiRegistryPort = 1099 + + # + # Host for RMI registry + # + rmiRegistryHost = 127.0.0.1 + + # + # Port number for RMI server connection + # + rmiServerPort = 44444 + + # + # Host for RMI server + # + rmiServerHost = 127.0.0.1 + + # + # Name of the JAAS realm used for authentication + # + jmxRealm = karaf + + # + # The service URL for the JMXConnectorServer + # + serviceUrl = service:jmx:rmi://${rmiServerHost}:${rmiServerPort}/jndi/rmi://${rmiRegistryHost}:${rmiRegistryPort}/karaf-${karaf.name} + + # + # Whether any threads started for the JMXConnectorServer should be started as daemon threads + # + daemon = true + + # + # Whether the JMXConnectorServer should be started in a separate thread + # + threaded = true + + # + # The ObjectName used to register the JMXConnectorServer + # + objectName = connector:name=rmi + + # + # Role name used for JMX access authorization + # If not set, this defaults to the ${karaf.admin.role} configured in etc/system.properties + # + # jmxRole=admin + </config> <feature>jaas</feature> <bundle dependency="true" start-level="20">mvn:org.apache.aries/org.apache.aries.util/${aries.util.version}</bundle> <bundle start-level="30">mvn:org.apache.karaf.management/org.apache.karaf.management.server/${project.version}</bundle> http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/static/pom.xml ---------------------------------------------------------------------- diff --git a/assemblies/features/static/pom.xml b/assemblies/features/static/pom.xml index ab233a8..7ab0c90 100644 --- a/assemblies/features/static/pom.xml +++ b/assemblies/features/static/pom.xml @@ -120,6 +120,13 @@ <artifactId>base</artifactId> </artifactItem> </artifactItems> + <excludes> + resources/bin/contrib,resources/bin/contrib/*, + resources/bin/instance*,resources/bin/client*, + resources/deploy,resources/deploy/*, + resources/instances,resources/instances/*, + resources/etc/system.properties + </excludes> <outputDirectory>target/classes</outputDirectory> </configuration> </execution> http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/features/static/src/main/resources/resources/etc/system.properties ---------------------------------------------------------------------- diff --git a/assemblies/features/static/src/main/resources/resources/etc/system.properties b/assemblies/features/static/src/main/resources/resources/etc/system.properties new file mode 100644 index 0000000..6cfaca8 --- /dev/null +++ b/assemblies/features/static/src/main/resources/resources/etc/system.properties @@ -0,0 +1,145 @@ +################################################################################ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You 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. +# +################################################################################ + +# +# The properties defined in this file will be made available through system +# properties at the very beginning of the Karaf's boot process. +# + + +# Log level when the pax-logging service is not available +# This level will only be used while the pax-logging service bundle +# is not fully available. +# To change log levels, please refer to the org.ops4j.pax.logging.cfg file +# instead. +org.ops4j.pax.logging.DefaultServiceLog.level = ERROR + +# +# Name of this Karaf instance. +# +# karaf.name = root + +# +# Default repository where bundles will be loaded from before using +# other Maven repositories. For the full Maven configuration, see +# the org.ops4j.pax.url.mvn.cfg file. +# +karaf.default.repository = system + +# +# Location of a shell script that will be run when starting a shell +# session. This script can be used to create aliases and define +# additional commands. +# +karaf.shell.init.script = ${karaf.etc}/shell.init.script,${karaf.etc}/scripts/*.script + +# +# Sets the maximum size of the shell command history. If not set, +# defaults to 500 entries. Setting to 0 will disable history. +# +# karaf.shell.history.maxSize = 0 + +# +# Deletes the entire karaf.data directory at every start +# +karaf.clean.all = false + +# +# Deletes the karaf.data/cache directory at every start +# +karaf.clean.cache = false + +# +# User name for the Karaf local console +# +karaf.local.user = karaf + +# +# Roles to use when for the default user in the local Karaf console. +# +# The syntax is the following: +# [classname:]principal +# where classname is the class name of the principal object +# (defaults to org.apache.karaf.jaas.modules.RolePrincipal) +# and principal is the name of the principal of that class +# (defaults to instance). +# +karaf.local.roles = admin,manager,viewer,systembundles + +# +# Set this empty property to avoid errors when validating xml documents. +# +xml.catalog.files = + +# +# ServiceMix specs options +# +org.apache.servicemix.specs.debug = false +org.apache.servicemix.specs.timeout = 0 + +# +# Settings for the OSGi 4.3 Weaving +# By default, we will not weave any classes. Change this setting to include classes +# that you application needs to have woven. +# +org.apache.aries.proxy.weaving.enabled = none +# Classes not to weave - Aries default + Xerces which is known to have issues. +org.apache.aries.proxy.weaving.disabled = org.objectweb.asm.*,org.slf4j.*,org.apache.log4j.*,javax.*,org.apache.xerces.* + +# +# By default, only Karaf shell commands are secured, but additional services can be +# secured by expanding this filter +# +karaf.secured.services = (&(osgi.command.scope=*)(osgi.command.function=*)) + +# +# By default, if there's no ACL policy for a certain karaf command, this command is allowed to access +# without the RBAC. We can change this behavior by enable the following property, which means +# if a karaf command has no corresponding ACL then access it must have one of the karaf.secured.command.compulsory.roles +# +#karaf.secured.command.compulsory.roles=admin + +# +# Security properties +# +# To enable OSGi security, uncomment the properties below, +# install the framework-security feature and restart. +# +#java.security.policy=${karaf.etc}/all.policy +#org.osgi.framework.security=osgi +#org.osgi.framework.trust.repositories=${karaf.etc}/trustStore.ks + +# +# HA/Lock configuration +# +# Karaf uses a lock mechanism to know which instance is the master (HA) +# The lock can be on the filesystem (default) or on a database. +# +# See http://karaf.apache.org/manual/latest/users-guide/failover.html for details. +# +# Even using a single instance, Karaf creates the lock file +# You can specify the location of the lock file using the +# karaf.lock.dir=/path/to/the/directory/containing/the/lock +# +# By default, the slave instances start but are passive. +# If you want to prevent the slave instances startup, you can use +# the karaf.lock.slave.block property (false by default): +# karaf.lock.slave.block=true + +karaf.lock = false http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/assemblies/test-cxf/pom.xml ---------------------------------------------------------------------- diff --git a/assemblies/test-cxf/pom.xml b/assemblies/test-cxf/pom.xml new file mode 100644 index 0000000..bd96f25 --- /dev/null +++ b/assemblies/test-cxf/pom.xml @@ -0,0 +1,146 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + + <!-- + + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + --> + + <modelVersion>4.0.0</modelVersion> + + <parent> + <groupId>org.apache.karaf.assemblies</groupId> + <artifactId>assemblies</artifactId> + <version>4.1.0-SNAPSHOT</version> + <relativePath>../pom.xml</relativePath> + </parent> + + <groupId>org.apache.karaf</groupId> + <artifactId>test-cxf</artifactId> + <packaging>pom</packaging> + <name>Apache Karaf :: Assemblies :: Minimal Distribution</name> + + <properties> + <appendedResourcesDirectory>${basedir}/../etc/appended-resources</appendedResourcesDirectory> + </properties> + + <dependencies> + <dependency> + <groupId>org.apache.karaf.features</groupId> + <artifactId>static</artifactId> + <type>kar</type> + </dependency> + <dependency> + <groupId>org.apache.karaf.features</groupId> + <artifactId>standard</artifactId> + <classifier>features</classifier> + <type>xml</type> + </dependency> + <dependency> + <groupId>org.apache.karaf.features</groupId> + <artifactId>enterprise</artifactId> + <classifier>features</classifier> + <type>xml</type> + </dependency> + <dependency> + <groupId>org.apache.cxf.karaf</groupId> + <artifactId>apache-cxf</artifactId> + <version>3.1.8</version> + <classifier>features</classifier> + <type>xml</type> + </dependency> + <dependency> + <groupId>org.ops4j.pax.web</groupId> + <artifactId>pax-web-features</artifactId> + <version>4.4.0</version> + <classifier>features</classifier> + <type>xml</type> + </dependency> + </dependencies> + + <build> + <resources> + <resource> + <directory>${project.basedir}/../..</directory> + <filtering>false</filtering> + <includes> + <include>README</include> + <include>RELEASE*</include> + <include>LICENSE</include> + <include>NOTICE</include> + </includes> + </resource> + </resources> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-resources-plugin</artifactId> + <executions> + <execution> + <id>process-resources</id> + <goals> + <goal>resources</goal> + </goals> + </execution> + </executions> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-remote-resources-plugin</artifactId> + <configuration> + <skip>true</skip> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.karaf.tooling</groupId> + <artifactId>karaf-maven-plugin</artifactId> + <executions> + <execution> + <id>process-resources</id> + <phase>process-resources</phase> + <goals> + <goal>assembly</goal> + </goals> + </execution> + <execution> + <id>package</id> + <goals> + <goal>archive</goal> + </goals> + </execution> + </executions> + <configuration> + <startupFeatures> + <feature>cxf-jaxws</feature> + <feature>cxf-jaxrs</feature> + <feature>httplite</feature> + <feature>shell</feature> + <feature>bundle</feature> + </startupFeatures> + <javase>1.8</javase> + <blacklistedBundles> + <bundle>mvn:javax.mail/mail/1.4.4</bundle> + <bundle>mvn:javax.servlet/javax.servlet-api/3.1.0</bundle> + <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.jaxb-impl/2.2.11_1</bundle> + <bundle>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.jaxb-xjc/2.2.11_1</bundle> + </blacklistedBundles> + </configuration> + </plugin> + + </plugins> + </build> + +</project> http://git-wip-us.apache.org/repos/asf/karaf/blob/203cfd8d/features/core/src/main/java/org/apache/karaf/features/internal/model/Config.java ---------------------------------------------------------------------- diff --git a/features/core/src/main/java/org/apache/karaf/features/internal/model/Config.java b/features/core/src/main/java/org/apache/karaf/features/internal/model/Config.java index 816b595..8fed515 100644 --- a/features/core/src/main/java/org/apache/karaf/features/internal/model/Config.java +++ b/features/core/src/main/java/org/apache/karaf/features/internal/model/Config.java @@ -18,10 +18,8 @@ package org.apache.karaf.features.internal.model; import java.io.IOException; import java.io.StringReader; -import java.util.Enumeration; +import java.util.Map; import java.util.Properties; -import java.util.regex.Matcher; -import java.util.regex.Pattern; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; @@ -111,31 +109,18 @@ public class Config implements ConfigInfo { } public Properties getProperties() { - StringReader propStream = new StringReader(getValue()); Properties props = new Properties(); try { - props.load(propStream); + org.apache.felix.utils.properties.Properties properties + = new org.apache.felix.utils.properties.Properties(); + properties.load(new StringReader(value)); + for (Map.Entry<String, String> e : properties.entrySet()) { + props.put(e.getKey(), e.getValue()); + } } catch (IOException e) { // ignore?? } - interpolation(props); return props; } - @SuppressWarnings("rawtypes") - private void interpolation(Properties properties) { - for (Enumeration e = properties.propertyNames(); e.hasMoreElements();) { - String key = (String) e.nextElement(); - String val = properties.getProperty(key); - Matcher matcher = Pattern.compile("\\$\\{([^}]+)\\}").matcher(val); - while (matcher.find()) { - String rep = System.getProperty(matcher.group(1)); - if (rep != null) { - val = val.replace(matcher.group(0), rep); - matcher.reset(val); - } - } - properties.put(key, val); - } - } }
