Skip to content

Commit 35c459d

Browse files
Fix java.lang.Boolean issues for ActiveDirectoryAuthenticator (#543)
* Fix java.lang.Boolean issues for ActiveDirectoryAuthenticator * Issue#157 copyrights
1 parent d547402 commit 35c459d

File tree

4 files changed

+22
-11
lines changed

4 files changed

+22
-11
lines changed

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/Log.json

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"copyright": "Copyright (c) 2017, 2019, Oracle Corporation and/or its affiliates. All rights reserved.",
2+
"copyright": "Copyright (c) 2017, 2020, Oracle Corporation and/or its affiliates.",
33
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
44
"wlst_type": "Log",
55
"child_folders_type": "single_unpredictable",
@@ -33,8 +33,7 @@
3333
"LogMonitoringThrottleThreshold": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringThrottleThreshold", "wlst_path": "WP001", "value": {"default": 1500 }, "wlst_type": "integer"} ],
3434
"LoggerSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverity", "wlst_path": "WP001", "value": {"default": "${None:Info}" }, "wlst_type": "string" } ],
3535
"LoggerSeverityProperties": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverityProperties", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "properties", "preferred_model_type": "dict", "get_method": "GET" } ],
36-
"MemoryBufferFilter": [ {"version": "[10,12.1.3)", "wlst_mode": "both", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean"} ,
37-
{"version": "[12.1.3,)", "wlst_mode": "offline", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean"} ],
36+
"MemoryBufferFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean"} ],
3837
"MemoryBufferSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferSeverity", "wlst_path": "WP001", "value": {"default": "${None:Trace}"}, "wlst_type": "string" } ],
3938
"MemoryBufferSize": [ {"version": "[10,12.2.1.3)","wlst_mode": "both", "wlst_name": "MemoryBufferSize", "wlst_path": "WP001", "value": {"default": 10 }, "wlst_type": "integer"} ,
4039
{"version": "[12.2.1.3,)","wlst_mode": "both", "wlst_name": "MemoryBufferSize", "wlst_path": "WP001", "value": {"default": "${10:500}"}, "wlst_type": "integer"} ],

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/SecurityConfiguration.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"copyright": "Copyright (c) 2017, 2019, Oracle Corporation and/or its affiliates. All rights reserved.",
2+
"copyright": "Copyright (c) 2017, 2020, Oracle Corporation and/or its affiliates.",
33
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
44
"wlst_type": "SecurityConfiguration",
55
"child_folders_type": "single_unpredictable",
@@ -160,7 +160,7 @@
160160
"DynamicMemberUrlAttribute": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "DynamicMemberUrlAttribute", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
161161
"EnableCacheStatistics": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "EnableCacheStatistics", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean" } ],
162162
"EnableGroupMembershipLookupHierarchyCaching": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "EnableGroupMembershipLookupHierarchyCaching", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "java.lang.Boolean", "wlst_read_type": "boolean", "set_method": "MBEAN.set_attribute_with_cmo" } ],
163-
"EnableSIDtoGroupLookupCaching": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "EnableSIDtoGroupLookupCaching", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean" } ],
163+
"EnableSIDtoGroupLookupCaching": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "EnableSIDtoGroupLookupCaching", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "java.lang.Boolean", "wlst_read_type": "boolean", "set_method": "MBEAN.set_attribute_with_cmo" } ],
164164
"FollowReferrals": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "FollowReferrals", "wlst_path": "WP001", "value": {"default": true }, "wlst_type": "boolean" } ],
165165
"GroupBaseDN": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "GroupBaseDN", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
166166
"GroupFromNameFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "GroupFromNameFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
@@ -179,7 +179,7 @@
179179
"ParallelConnectDelay": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "ParallelConnectDelay", "wlst_path": "WP001", "value": {"default": 0 }, "wlst_type": "integer" } ],
180180
"Port": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Port", "wlst_path": "WP001", "value": {"default": 389 }, "wlst_type": "integer" } ],
181181
"Principal": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "Principal", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
182-
"PropagateCauseForLoginException": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "PropagateCauseForLoginException", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean" } ],
182+
"PropagateCauseForLoginException": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "PropagateCauseForLoginException", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "java.lang.Boolean", "wlst_read_type": "boolean", "set_method": "MBEAN.set_attribute_with_cmo" } ],
183183
"ResultsTimeLimit": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "ResultsTimeLimit", "wlst_path": "WP001", "value": {"default": 0 }, "wlst_type": "integer" } ],
184184
"RetrievePrincipalFromUserDn": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "RetrievePrincipalFromUserDn", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean", "get_method": "LSA" } ],
185185
"RetrieveUserAccountControl": [ {"version": "[12.2.1.1,)", "wlst_mode": "both", "wlst_name": "RetrieveUserAccountControl", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean" } ],
@@ -189,7 +189,7 @@
189189
"StaticGroupObjectClass": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StaticGroupObjectClass", "wlst_path": "WP001", "value": {"default": "groupofuniquenames" }, "wlst_type": "string" } ],
190190
"StaticMemberDNAttribute": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "StaticMemberDNAttribute", "wlst_path": "WP001", "value": {"default": "uniquemember" }, "wlst_type": "string" } ],
191191
"UseRetrievedUserNameAsPrincipal": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UseRetrievedUserNameAsPrincipal", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "java.lang.Boolean", "wlst_read_type": "boolean", "set_method": "MBEAN.set_attribute_with_cmo" } ],
192-
"UseTokenGroupsForGroupMembershipLookup": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UseTokenGroupsForGroupMembershipLookup", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "boolean" } ],
192+
"UseTokenGroupsForGroupMembershipLookup": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UseTokenGroupsForGroupMembershipLookup", "wlst_path": "WP001", "value": {"default": false }, "wlst_type": "java.lang.Boolean", "wlst_read_type": "boolean", "set_method": "MBEAN.set_attribute_with_cmo" } ],
193193
"UserBaseDn": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UserBaseDn", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
194194
"UserDynamicGroupDnAttribute": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UserDynamicGroupDnAttribute", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],
195195
"UserFromNameFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "UserFromNameFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string" } ],

core/src/main/resources/oracle/weblogic/deploy/aliases/category_modules/Server.json

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"copyright": "Copyright (c) 2017, 2019, Oracle Corporation and/or its affiliates. All rights reserved.",
2+
"copyright": "Copyright (c) 2017, 2020, Oracle Corporation and/or its affiliates.",
33
"license": "Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl",
44
"wlst_type": "Server${:s}",
55
"child_folders_type": "multiple",
@@ -259,8 +259,7 @@
259259
"LogMonitoringThrottleThreshold": [ {"version": "[12.2.1,)", "wlst_mode": "both", "wlst_name": "LogMonitoringThrottleThreshold", "wlst_path": "WP001", "value": {"default": 1500 }, "wlst_type": "integer"} ],
260260
"LoggerSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverity", "wlst_path": "WP001", "value": {"default": "${None:Info}"}, "wlst_type": "string" } ],
261261
"LoggerSeverityProperties": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "LoggerSeverityProperties", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "properties", "preferred_model_type": "dict", "get_method": "GET" } ],
262-
"MemoryBufferFilter": [ {"version": "[10,12.1.3)", "wlst_mode": "both", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean" } ,
263-
{"version": "[12.1.3,)", "wlst_mode": "offline", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean" } ],
262+
"MemoryBufferFilter": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferFilter", "wlst_path": "WP001", "value": {"default": "None" }, "wlst_type": "string", "set_method": "MBEAN.set_log_filter_mbean", "set_mbean_type": "weblogic.management.configuration.LogFilterMBean" } ],
264263
"MemoryBufferSeverity": [ {"version": "[10,)", "wlst_mode": "both", "wlst_name": "MemoryBufferSeverity", "wlst_path": "WP001", "value": {"default": "${None:Trace}"}, "wlst_type": "string" } ],
265264
"MemoryBufferSize": [ {"version": "[10,12.2.1.3)", "wlst_mode": "both", "wlst_name": "MemoryBufferSize", "wlst_path": "WP001", "value": {"default": 10 }, "wlst_type": "integer"} ,
266265
{"version": "[12.2.1.3,)", "wlst_mode": "both", "wlst_name": "MemoryBufferSize", "wlst_path": "WP001", "value": {"default": "${10:500}"}, "wlst_type": "integer"} ],

core/src/test/python/aliases_test.py

+14-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
Copyright (c) 2017, 2020, Oracle Corporation and/or its affiliates. All rights reserved.
2+
Copyright (c) 2017, 2020, Oracle Corporation and/or its affiliates.
33
Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl.
44
"""
55
from org.python.modules import jarray
@@ -900,6 +900,19 @@ def testGetWlstAttributeJavaBoolean(self):
900900
self.assertEqual(value, Boolean('true'))
901901
return
902902

903+
def testGetWlstAttributeJavaBooleanNewIssue157(self):
904+
location = LocationContext().append_location(FOLDERS.SECURITY_CONFIGURATION)
905+
token = self.aliases.get_name_token(location)
906+
location.add_name_token(token, 'my-domain')
907+
location.append_location(FOLDERS.REALM, REALM="myrealm"). \
908+
append_location(FOLDERS.AUTHENTICATION_PROVIDER, PROVIDER='myprovider'). \
909+
append_location(FOLDERS.ACTIVE_DIRECTORY_AUTHENTICATOR)
910+
name, value = self.aliases.get_wlst_attribute_name_and_value(location, 'UseTokenGroupsForGroupMembershipLookup',
911+
'true')
912+
self.assertEqual(name, 'UseTokenGroupsForGroupMembershipLookup')
913+
self.assertEqual(value, Boolean('true'))
914+
return
915+
903916
def testSecurityProviderTypeHandling(self):
904917
location = LocationContext().append_location(FOLDERS.SECURITY_CONFIGURATION)
905918
token = self.aliases.get_name_token(location)

0 commit comments

Comments
 (0)