wazuh-splunk icon indicating copy to clipboard operation
wazuh-splunk copied to clipboard

Move API credentials to the config.yml file

Open jesusgn90 opened this issue 5 years ago • 2 comments

Hi team,

We need to improve the way we manage the Wazuh API entries. We should simplify it adding them to the config.yml file.

Proposal

  • It would be an array, each element has URL, port, username, password.
  • The user fills that information, something similar to kibana.yml file.
  • The app must show clear instructions if it's started with no API entries.
api:
  - production_env:
      url: http://172.16.1.2
      port: 55000
      username: foo
      password: bar
  - staging_env:
      url: http://localhost
      port: 7600
      username: fuzz
      password: fuzz

Other related changes

The above change implies some other modifications such as:

  • The kvStore logic must be reviewed, no longer needed.
  • Cluster current status is now different, we must reduce and simplify the way we determine if the cluster is enabled or not.
  • Settings view, the form, and all related views must be modified.

jesusgn90 avatar May 23 '19 11:05 jesusgn90

Note: this must be the first iteration, and we can't fully remove the legacy logic so for 3.10.0 the app will accept both mechanisms (soft deprecation so far).

jesusgn90 avatar May 27 '19 16:05 jesusgn90

Hi team,

I have been researching how could do this and there are several inconveniences.

The first problem is that the by default Splunk cannot read YML files then will be necessary to add any python library that supports this file format.

The second problem is even if it was possible to read properly an YML file if we remove the kvStore method to store the APIs in a cluster environment that will provoke that the APIs won't be redistributed to the nodes, this means that on each node will be necessary to add manually each API saved in others nodes.

adri9valle avatar Jun 06 '19 09:06 adri9valle