이 콘텐츠는 선택한 언어로 제공되지 않습니다.
Chapter 4. Securing the Management Console
Abstract
The default setting for
Access-Control-Allow-Origin
header for the JBoss A-MQ Management Console permits unrestricted sharing. To restrict access to the JBoss A-MQ Management Console, an OSGI fragment bundle must be implemented.
4.1. Controlling Access to the Fuse Management Console 링크 복사링크가 클립보드에 복사되었습니다!
링크 복사링크가 클립보드에 복사되었습니다!
Contents of the Fragment Bundle 링크 복사링크가 클립보드에 복사되었습니다!
링크 복사링크가 클립보드에 복사되었습니다!
A fragment bundle that enables the
jolokia-access.xml
policy file can be used to restrict access without altering the original hawtio-web.war
. A fragment bundle that contains the jolokia-access.xml
policy file within the CORS configuration can be added to limit access to a certain host by using <allow-origin>
sections within the <cors>
sections. The <allow-origin>
section can contain the origin URL provided by browsers with the Origin:
header, or a wildcard specification with *. For example:
Build the fragment bundle according to the insructions in the OSGI specifications at OSGi Developer Downloads. For more information about OSGi dependencies see Managing OSGi dependencies. Ensure that you add the
Fragment-Host
header in the Manifest.MF
bundle. After building the fragment bundle, use the following command to install it:
install file:///Location_Of_Fragment_Bundle_file/hawtio-web-fragment/target/hawtio-web-fragment-1.2-redhat-379.jar
install file:///Location_Of_Fragment_Bundle_file/hawtio-web-fragment/target/hawtio-web-fragment-1.2-redhat-379.jar
Hawtio-web
must be refreshed to pick up the fragment bundle. Use the follwing comands to refresh the hawtio-web
bundle:
To find out the
hawtio-web
bundle ID:
JBossFuse:karaf@root> la | grep -i hawtio
JBossFuse:karaf@root> la | grep -i hawtio
Identify the number for the
hawtio-web
bundle. In the example below, the number is 253:
[ 253] [Active ] [ ] [ ] [ 80] hawtio :: hawtio-web (1.4.0.redhat-621083)
[ 253] [Active ] [ ] [ ] [ 80] hawtio :: hawtio-web (1.4.0.redhat-621083)
Refresh the
hawtio-web
bundle using the following command:
JBossFuse:karaf@root> refresh 253
JBossFuse:karaf@root> refresh 253
Repeat the
la | grep -i hawtio
command to see the hawtio-web
line with the fragment bundle attached:
[ 253] [Active ] [ ] [ ] [ 80] hawtio :: hawtio-web (1.4.0.redhat-621083), Fragments: 270
[ 253] [Active ] [ ] [ ] [ 80] hawtio :: hawtio-web (1.4.0.redhat-621083), Fragments: 270