This commit is contained in:
25W0075
2025-11-27 17:47:04 +09:00
parent 5eae7b6468
commit 4c96396951
@@ -821,16 +821,25 @@ public class HttpClient5AdapterServiceRest extends HttpClient5AdapterServiceSupp
}
}
} else if (headerObj instanceof String) { //weblogic
String json = (String) headerObj;
JSONParser parser = new JSONParser();
JSONObject obj = (JSONObject) parser.parse(json);
for (Object k : obj.keySet()) {
if (((String) k).equalsIgnoreCase("authorization")) {
authorization = (String) obj.get(k);
System.out.println("*** inboundHeaders authorization weblogic:"+authorization);
String str = (String) headerObj;
System.out.println("*** inboundHeaders weblogic str:"+str);
str = str.substring(1, str.length() - 1);
String[] entries = str.split(",");
Map<String, String> map = new HashMap<>();
for (String entry : entries) {
String[] kv = entry.split("=", 2);
if (kv.length == 2) {
map.put( kv[0].trim(), kv[1].trim());
}
}
for (String k : map.keySet() ) {
if ( k.equalsIgnoreCase("authorization")) {
authorization = map.get(k);
break;
}
}
}
}
} catch (ParseException e) {
e.printStackTrace();