From fbc126f0ee9f2a50cd6450378976d4ed32c2dce8 Mon Sep 17 00:00:00 2001 From: Ryan Goulding Date: Thu, 29 Oct 2015 14:48:59 -0400 Subject: [PATCH] Bug 3231 jolokia access should be controlled by aaa Due to unfortunate lack of support, we are going to have to just use basic authentication from config file for now. I have committed this patch to upstream jolokia: https://github.com/rhuss/jolokia/pull/225 which will unlock power for us to use AAA. However, this won't be available until a new release is cut on Jolokia's end. The only options for jolokia-osgi bundle for authentication are basic file authn (which is implemented in this proposed changeset) and JAAS. ODL's JAAS is unencrypted and generally disregarded, so basic file authN was chosen. By default, the credentials are admin/admin. Change-Id: I35770bcf13b3cb32e59685e9bbf0ef47d73d132f Signed-off-by: Ryan Goulding --- features/extras/pom.xml | 11 ++++- .../extras/src/main/features/features.xml | 1 + opendaylight/commons/jolokia/pom.xml | 47 +++++++++++++++++++ .../src/main/resources/org.jolokia.osgi.cfg | 4 ++ pom.xml | 1 + 5 files changed, 62 insertions(+), 2 deletions(-) create mode 100644 opendaylight/commons/jolokia/pom.xml create mode 100644 opendaylight/commons/jolokia/src/main/resources/org.jolokia.osgi.cfg diff --git a/features/extras/pom.xml b/features/extras/pom.xml index 563f1281b8..9fbe2dfb5f 100644 --- a/features/extras/pom.xml +++ b/features/extras/pom.xml @@ -19,8 +19,8 @@ 1.6.0-SNAPSHOT jar - 0.2.0-SNAPSHOT - 1.1.4 + 1.3.1 + 0.3.0-SNAPSHOT @@ -29,6 +29,13 @@ jolokia-osgi ${jolokia.version} + + org.opendaylight.controller + odl-jolokia-osgi + ${odl-jolokia-osgi.version} + cfg + configuration + diff --git a/features/extras/src/main/features/features.xml b/features/extras/src/main/features/features.xml index d83b378f98..99111e7c94 100644 --- a/features/extras/src/main/features/features.xml +++ b/features/extras/src/main/features/features.xml @@ -19,6 +19,7 @@ odl-jolokia + mvn:org.opendaylight.controller/odl-jolokia-osgi/{{VERSION}}/cfg/configuration http mvn:org.jolokia/jolokia-osgi/{{VERSION}} diff --git a/opendaylight/commons/jolokia/pom.xml b/opendaylight/commons/jolokia/pom.xml new file mode 100644 index 0000000000..e1132dc492 --- /dev/null +++ b/opendaylight/commons/jolokia/pom.xml @@ -0,0 +1,47 @@ + + + 4.0.0 + + org.opendaylight.controller + commons.opendaylight + 1.6.0-SNAPSHOT + ../opendaylight + + + odl-jolokia-osgi + 0.3.0-SNAPSHOT + jar + + + + + org.codehaus.mojo + build-helper-maven-plugin + + + attach-artifacts + package + + attach-artifact + + + + + ${project.build.directory}/classes/org.jolokia.osgi.cfg + cfg + configuration + + + + + + + + + + scm:git:http://git.opendaylight.org/gerrit/controller.git + scm:git:ssh://git.opendaylight.org:29418/controller.git + HEAD + https://wiki.opendaylight.org/view/OpenDaylight_Controller:Main + + diff --git a/opendaylight/commons/jolokia/src/main/resources/org.jolokia.osgi.cfg b/opendaylight/commons/jolokia/src/main/resources/org.jolokia.osgi.cfg new file mode 100644 index 0000000000..fdad9e9a2b --- /dev/null +++ b/opendaylight/commons/jolokia/src/main/resources/org.jolokia.osgi.cfg @@ -0,0 +1,4 @@ +#ODL Default Jolokia Configuration File +org.jolokia.authMode=basic +org.jolokia.user=admin +org.jolokia.password=admin diff --git a/pom.xml b/pom.xml index 9ea0abd1c9..67ae2e9833 100644 --- a/pom.xml +++ b/pom.xml @@ -33,6 +33,7 @@ opendaylight/commons/liblldp opendaylight/commons/enunciate-parent benchmark + opendaylight/commons/jolokia karaf -- 2.36.6