|
6 | 6 | package org.elasticsearch.xpack.watcher.notification.jira;
|
7 | 7 |
|
8 | 8 | import org.elasticsearch.common.settings.ClusterSettings;
|
| 9 | +import org.elasticsearch.common.settings.SecureSetting; |
| 10 | +import org.elasticsearch.common.settings.SecureString; |
9 | 11 | import org.elasticsearch.common.settings.Setting;
|
10 | 12 | import org.elasticsearch.common.settings.Setting.Property;
|
11 | 13 | import org.elasticsearch.common.settings.Settings;
|
@@ -41,17 +43,17 @@ public class JiraService extends NotificationService<JiraAccount> {
|
41 | 43 | Setting.affixKeySetting("xpack.notification.jira.account.", "password",
|
42 | 44 | (key) -> Setting.simpleString(key, Property.Dynamic, Property.NodeScope, Property.Filtered, Property.Deprecated));
|
43 | 45 |
|
44 |
| - private static final Setting.AffixSetting<String> SETTING_SECURE_USER = |
| 46 | + private static final Setting.AffixSetting<SecureString> SETTING_SECURE_USER = |
45 | 47 | Setting.affixKeySetting("xpack.notification.jira.account.", "secure_user",
|
46 |
| - (key) -> Setting.simpleString(key, Property.Dynamic, Property.NodeScope, Property.Filtered)); |
| 48 | + (key) -> SecureSetting.secureString(key, null)); |
47 | 49 |
|
48 |
| - private static final Setting.AffixSetting<String> SETTING_SECURE_URL = |
| 50 | + private static final Setting.AffixSetting<SecureString> SETTING_SECURE_URL = |
49 | 51 | Setting.affixKeySetting("xpack.notification.jira.account.", "secure_url",
|
50 |
| - (key) -> Setting.simpleString(key, Property.Dynamic, Property.NodeScope, Property.Filtered)); |
| 52 | + (key) -> SecureSetting.secureString(key, null)); |
51 | 53 |
|
52 |
| - private static final Setting.AffixSetting<String> SETTING_SECURE_PASSWORD = |
| 54 | + private static final Setting.AffixSetting<SecureString> SETTING_SECURE_PASSWORD = |
53 | 55 | Setting.affixKeySetting("xpack.notification.jira.account.", "secure_password",
|
54 |
| - (key) -> Setting.simpleString(key, Property.Dynamic, Property.NodeScope, Property.Filtered)); |
| 56 | + (key) -> SecureSetting.secureString(key, null)); |
55 | 57 |
|
56 | 58 | private static final Setting.AffixSetting<Settings> SETTING_DEFAULTS =
|
57 | 59 | Setting.affixKeySetting("xpack.notification.jira.account.", "issue_defaults",
|
|
0 commit comments