Skip to content

Commit

Permalink
Backports for Wazuh 3.12.0 [6.8.7] (#2132)
Browse files Browse the repository at this point in the history
* Remove console.log

* Navigate from agents dashboard

* Change state by props

* Fix settings-wizard

* Fix when joinning hosts and registry

* Check for new API entries

* Close add api component

* Remove await

* Improve checks for new apis

* Test if API is down in wazuh-api

* Check down APIs

* Api is down component finish

* Transform hosts in the backend

* Fix key

* Adapt removeOrphanentries

* Adapt settings-wizard

* Improve api-is-down component

* Change  the way to display the helpers components

* Check APIs status when get them

* Remove console.log

* Check manager sets the status to the API entry

* Prevent create wazuh-registry.json without hosts

* FIx extensions

* Add panel

* Change style for wazuh hosts

* Show add api component from the table

* Refresh API entries

* Update wazuh-hosts

* Api is down table loading effect

* Show API is down when accessing to settings if any API is up

* Update cluster info in the settings wizard

* Update Kibana version

* Refactor design of guides

* Change color

* Remove wazuh-hosts.yml

* Remove hosts from configuration

* Change foreach by for

* Solves asynchronous problem

* Adapt ruleset handler

* Upload files

* Add more modules to the guide

* Show what files were upload and hwat not

* Detail the error

* Expand fail list

* Add button to refresh lists

* Fix \n in the migration

* Fix api-count

* Back from dahsboards

* Fix typo

* Fix when getting an empty file

* Prevent empty lines in cdb lists

* Hide index pattern is there are only one

* Add missing `await`

* Fix eui loader

* Change the properties of register-agent component

Set the background to transparent
Change the title: Add => Deploy

* Add register-agent component to add user to group

* Show button in general when no agents registered

* Show button in FIM when no agents registered

* Hide Logtest and Test config

* Update output of success/fail uploaded files

* More modules

* Some fixes

* Fix API wizard

* Add the RegisterAgent component to overview

* Make module selector scrollable and fit current screen

* Add Rootcheck. Fix extra attributes

* Add reconnect_time to log collection section

* Fix example in getting started guide

* Detect if is Agent

* Scroll to bottom when configuration is generated

* Fix groups interactive guide

* Revert "Merge branch 'extend-add-new-agent-1767' of https://github.com/wazuh/wazuh-kibana-app"

This reverts commit 7e56d49, reversing
changes made to 7706a2e.

* Fix style

* Avoid error when agent is not Active

* Revert "Revert "Merge branch 'extend-add-new-agent-1767' of https://github.com/wazuh/wazuh-kibana-app""

This reverts commit 6724d12.

* Delete from groups.html the actrl instance

* Fix typos

* Refresh hosts in api-is-down component

* Set default in props

* Fix API count

* Iterates the api entries to set one as default

* Fix component unmount

* Fix flick

* Validate method and path in Requests

* Adapt 7.4 to 3.10

* Bump version (547)

* Fix the documentation broken links (#1853)

* Update AWS map

* Remove babel-polyfill

* Remove babel-polyfill

* Restore babel-polyfill for cover simple-tail dependency

* Restore babel-polyfill for cover simple-tail dependency

* Filters fix (#1854)

* Filters fix

* Fix the documentation broken links (#1853)

* Update AWS map

* Removed Discover component from top menu

* Update readme

* Bump version

* Set the correct field in the geoMap viz

* Bump version (549 for 3.10.2-7.4.2)

* Revert "Set the correct field in the geoMap viz"

This reverts commit effc3b8.

* Update branch for 7.4.2

* Update README.md

* Update package.json

* Fix logo when reverse proxy is enabled (#1888)

* Fix hidden overflow in the fim configuration (#1887)

* Fix ambiguous message (#1875)

* Amazon s3 status fix (#1889)

* Fix amazon s3 status error

* Fix check aws s3 status

* Update wz-no-config.html

* Add pinned filters after refresh (#1909)

* Fix missing fields in the Visualizations (#1913)

* Fixed infinite load on Ciscat view (#1916)

* Fixed infinite load on Ciscat-agent view (#1920)

* Normalize the field whodata in the group reporting (#1921)

* Fix registration guide (#1926)

* Fix decoders file (#1929)

* Add new table for windows hotfixes (#1932)

* Remove visualizations legend (#1936)

* XML validator false error for \< (#1895)

* Add validator true to \<

* Add to gitignore wazuh-registry

* Minor Fix

* Revert changes for package.json and gitignore

* Refactor syscheck table (#1941) (#1956)

* Fix missing fields in the Visualizations (#1913)

* Fixed infinite load on Ciscat view (#1916)

* Fixed infinite load on Ciscat-agent view (#1920)

* Normalize the field whodata in the group reporting (#1921)

* Fix registration guide (#1926)

* Fix decoders file (#1929)

* Add new table for windows hotfixes (#1932)

* Remove visualizations legend (#1936)

* XML validator false error for \< (#1895)

* Add validator true to \<

* Add to gitignore wazuh-registry

* Minor Fix

* Revert changes for package.json and gitignore

* Refactor syscheck table

* Set fixed width to table columns

* Expand row to get extra details

* Add search bar & allow search

* Show extra details on row expand

* Remove table description

* Fix table margin

* Remove wazuh-registry

* Add go to edit file in rules and decoders, when it has been created correctly (#1943)

* Adapt for 7.5.0

* Bump version to 7.5.0

* Adapt server 7.5.0

* Fix typo

* Add fix to adapt 7.5.0

* Adapt server for Kibana 7.5.0

* Remove the table images from the reports

* Fix the tables in the reports

* Fix the hidden content in management>configuration (#1840)

* Fix discover input styling

* Fix most active agent

* Change the revision number

* Fix the undefined value of filters in the reports

* Restore package.json dependency

* Adapt 7.5.0 in 3.11 (#1960)

* Adapt Kibana for 7.5.0

* Several fixes

* Fix filters

* Bump wazuh version to 3.11.0

* Revert "Adapt 7.5.0 in 3.11 (#1960)"

This reverts commit 8f9c9aa.

* Adapt 7.5.0 for 3.11 (#1961)

* Adapt Kibana for 7.5.0

* Several fixes

* Fix filters

* Bump wazuh version to 3.11.0

* Prepare branch for release

* Last fixes in the branch 3.11-7.5 (#1966)

* Fixed broken link to the documentation

* Update README

* Change plugin-helpers reference in package.json

* Fix the empty search in syscheck-table

* Fix the dead visualizations on CIS-CAT

* Update CHANGELOG.md file

* Adapt for Kibana 7.5.1

* Adapt for Kibana 7.5.1

* Upadte package list

* Fix ciscat panel

* Adapt to 7.5.1

* Prevent reload when click in the sameTab

* Revert "Prevent reload when click in the sameTab"

This reverts commit 7e1deb1.

* Update version files (#1973)

* Update revision code

* Update readme

* Update Changelog

* Update version number of kibana

* Added xpack compatibility (#1971)

* Update files (#1975)

* Update readme file

* Update changelog file

* Bump Wazuh version to 3.11.1

* Add validator true to -- within a commentary (#1980)

* Increased list filesize limit and fixed typo (#1993)

As mentioned in #1947 the limit for uploading a list for the CDB-list capability is too low and the resulting error message contains a typo.

This commit addresses that by increasing the limit to 5MB and fixing the typo.

* Fix maps vis load

* Bump version 3.11.2

* Bump for 7.5.2

* Fix Wazuh version in upgrade guide (#2023)

The upgrade guide is using a previous version of Wazuh 3.11.1-7.5.2 when the latest version is 3.11.2-7.5.2.

* Add WindowsUpdate table to report (#2028)

* Bump for Wazuh 3.11.3

* Cancel listener on destroy kibana discover

* Fix custom spaces infinite loop

* Fix reporting in syscollector

* Adapt for 7.6.0

* Update routes kibana

* Modified upgrade guide

* Bump for 3.11.4

* Update kibana-discover.js

* Update package.json

* Update CHANGELOG.md

* Delete wazuh-registry.json

* update changelog master

* Adapt for 7.6.1

* Fix reporting syscheck negative values in atrributes

* Adapt discover

* Fix visualizations report on chrome

* Restructure optimize/wazuh folder (#2116)

* Restructure optimize/wazuh folder

* Update protocol of initial config example

* Replace path with a constant

* Remove wazuh.yml file

* Update README upgrade guide

* Fix plugin helper error

Co-authored-by: Pablo Torres <pablotr9@correo.ugr.es>

* hide manager alerts

* Add rule group win_auth_failure to metrics (#2099)

* Add PCI 11.2.1 y 11.2.3 rules. (#2062)

* Discover in monitoring

* Close 3.12-7.6

* Update changelog

* Update package.json

* Update package.json

* merge discover

* merge 7.6

* merge 7.6

* Update CHANGELOG.md

* Update package.json

* Fix merge

* Close 6.8.7

* Allow disabling known fields health check (#2037)

* Add https to initial wazuh configuration

* Add https to Wazuh config example

* update changelog

* Fix reports path error

* Add checks.fields to initial default config

* Update initial-wazuh-config.js

Co-authored-by: Adri Valle <adri9valle@gmail.com>
Co-authored-by: Jose Sanchez <josesanxez@gmail.com>
Co-authored-by: Pablo <pablotr9@correo.ugr.es>
Co-authored-by: Alberto Andújar <josealbertoandujar@gmail.com>
Co-authored-by: Daniel Ruiz Capilla <daniel.ruiz@wazuh.com>
Co-authored-by: Juan Carlos Tello <juancarlos.tello@wazuh.com>
Co-authored-by: Victor Santaella <victorst79@gmail.com>
  • Loading branch information
8 people authored Mar 12, 2020
1 parent 20966bb commit 8e9dff0
Show file tree
Hide file tree
Showing 58 changed files with 1,365 additions and 8,367 deletions.
3 changes: 1 addition & 2 deletions .kibana-plugin-helpers.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,10 @@
"package.json",
"LICENSE",
"tsconfig.json",
"wazuh.yml",
"index.js",
"init.js",
"server/**/*",
"public/**/*",
"util/**/*"
]
}
}
54 changes: 49 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,55 @@

All notable changes to the Wazuh app project will be documented in this file.

## Wazuh v3.11.4 - Kibana v6.8.7, v7.4.2, v7.6.1 - Revision 485
## Wazuh v3.12.0 - Kibana v6.8.7, v7.4.2, v7.6.1 - Revision 490

### Added

- Support for Kibana v6.8.7
- Support for Wazuh v3.12.0
- Added a new setting to hide manager alerts from dashboards. [#2102](https://github.com/wazuh/wazuh-kibana-app/pull/2102)
- Added a new setting to enable/disable the known fields health check [#2037](https://github.com/wazuh/wazuh-kibana-app/pull/2037)
- Added suport for PCI 11.2.1 and 11.2.3 rules. [#2062](https://github.com/wazuh/wazuh-kibana-app/pull/2062)

## Wazuh v3.11.4 - Kibana v6.8.6, v7.4.2, v7.6.0 - Revision 484
### Changed

- Restructuring of the optimize/wazuh directory. Now the Wazuh configuration file (wazuh.yml) is placed on /usr/share/kibana/optimize/wazuh/config. [#2116](https://github.com/wazuh/wazuh-kibana-app/pull/2116)
- Improve performance of Dasboards reports generation. [1802344](https://github.com/wazuh/wazuh-kibana-app/commit/18023447c6279d385df84d7f4a5663ed2167fdb5)

### Fixed

- Discover time range selector is now displayed on the Cluster section. [08901df](https://github.com/wazuh/wazuh-kibana-app/commit/08901dfcbe509f17e4fab26877c8b7dae8a66bff)
- Added the win_auth_failure rule group to Authentication failure metrics. [#2099](https://github.com/wazuh/wazuh-kibana-app/pull/2099)
- Negative values in Syscheck attributes now have their correct value in reports. [7c3e84e](https://github.com/wazuh/wazuh-kibana-app/commit/7c3e84ec8f00760b4f650cfc00a885d868123f99)


## Wazuh v3.11.4 - Kibana v7.6.1 - Revision 858

### Added

- Support for Kibana v7.6.1


## Wazuh v3.11.4 - Kibana v6.8.6, v7.4.2, v7.6.0 - Revision 857

### Added

- Support for Wazuh v3.11.4

## Wazuh v3.11.3 - Kibana v6.8.6, v7.3.2, v7.5.1 - Revision 483

## Wazuh v3.11.3 - Kibana v7.6.0 - Revision 856

### Added

- Support for Kibana v7.6.0


## Wazuh v3.11.3 - Kibana v7.4.2 - Revision 855

### Added

- Support for Kibana v7.4.2

## Wazuh v3.11.3 - Kibana v7.5.2 - Revision 854

### Added

Expand All @@ -25,7 +61,14 @@ All notable changes to the Wazuh app project will be documented in this file.
- Windows Updates table is now displayed in the Inventory Data report [#2028](https://github.com/wazuh/wazuh-kibana-app/pull/2028)


## Wazuh v3.11.2 - Kibana v6.8.6, v7.3.2, v7.5.1 - Revision 481
## Wazuh v3.11.2 - Kibana v7.5.2 - Revision 853

### Added

- Support for Kibana v7.5.2


## Wazuh v3.11.2 - Kibana v6.8.6, v7.3.2, v7.5.1 - Revision 852

### Added

Expand All @@ -38,6 +81,7 @@ All notable changes to the Wazuh app project will be documented in this file.
### Fixed

- The xml validator now correctly handles the `--` string within comments [#1980](https://github.com/wazuh/wazuh-kibana-app/pull/1980)
- The AWS map visualization wasn't been loaded until the user interacts with it [dd31bd7](https://github.com/wazuh/wazuh-kibana-app/commit/dd31bd7a155354bc50fe0af22fca878607c8936a)


## Wazuh v3.11.1 - Kibana v6.8.6, v7.3.2, v7.5.1 - Revision 581
Expand Down
267 changes: 138 additions & 129 deletions README.md

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ export default kibana =>
init(server, options) {
return initApp(server, options);
}
});
});
7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "wazuh",
"version": "3.11.4",
"revision": "0485",
"code": "0485-0",
"version": "3.12.0",
"revision": "0490",
"code": "0490-0",
"kibana": {
"version": "6.8.7"
},
Expand Down Expand Up @@ -38,7 +38,6 @@
"angular-chart.js": "1.1.1",
"angular-cookies": "1.6.5",
"angular-material": "1.1.18",
"dom-to-image": "^2.6.0",
"install": "^0.10.1",
"js2xmlparser": "^3.0.0",
"json2csv": "^4.1.2",
Expand Down
131 changes: 5 additions & 126 deletions public/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ import 'uiExports/autocompleteProviders';

// Require CSS
import './less/loader';
// Require lib to dashboards PDFs
require ('./utils/dom-to-image.js');
import { uiModules } from 'ui/modules';
import chrome from 'ui/chrome';

Expand Down Expand Up @@ -81,134 +83,11 @@ app.config([
}
]);

app.run(function($rootScope, $route, $location, appState, $window) {
app.run(function() {
chrome
.setRootTemplate('<wz-menu></wz-menu><div ng-view></div>')
.setRootController(() => require('./app'));
appState.setNavigation({ status: false });
appState.setNavigation({
reloaded: false,
discoverPrevious: false,
discoverSections: ['/overview/', '/agents', '/wazuh-dev']
});

$rootScope.$on('$routeChangeSuccess', () => {
appState.setNavigation({ prevLocation: $location.path() });
if (!appState.getNavigation().reloaded) {
appState.setNavigation({ status: true });
} else {
appState.setNavigation({ reloaded: false });
}
});

$rootScope.$on('$locationChangeSuccess', () => {
const navigation = appState.getNavigation();
appState.setNavigation({ currLocation: $location.path() });
if (navigation.currLocation !== navigation.prevLocation) {
if (navigation.discoverSections.includes(navigation.currLocation)) {
appState.setNavigation({ discoverPrevious: navigation.prevLocation });
}
} else {
if (!navigation.status && navigation.prevLocation) {
if (
!navigation.discoverSections.includes(navigation.currLocation) &&
$location.search().tabView !== 'cluster-monitoring'
) {
appState.setNavigation({ reloaded: true });
$location.search('configSubTab', null);
$location.search('editingFile', null);
$route.reload();
//discover sections
} else if (
navigation.discoverSections.includes(navigation.currLocation)
) {
if (navigation.currLocation === navigation.discoverSections[1]) {
$window.history.pushState(
{
page: chrome.addBasePath(
'wazuh#' + navigation.discoverPrevious + '/'
)
},
'',
chrome.addBasePath('wazuh#' + navigation.discoverPrevious + '/')
);
} else if (
navigation.currLocation === navigation.discoverSections[2]
) {
if (
$location.search().tab &&
$location.search().tab !== 'welcome'
) {
$window.history.pushState(
{
page: chrome.addBasePath(
'wazuh#' + navigation.discoverPrevious
)
},
'',
chrome.addBasePath('wazuh#' + navigation.discoverPrevious)
);
$window.history.pushState(
{
page: chrome.addBasePath(
'wazuh#' +
navigation.discoverPrevious +
'?agent=' +
$location.search().agent
)
},
'',
chrome.addBasePath(
'wazuh#' +
navigation.discoverPrevious +
'?agent=' +
$location.search().agent
)
);
} else {
$window.history.pushState(
{
page: chrome.addBasePath(
'wazuh#' + navigation.discoverPrevious
)
},
'',
chrome.addBasePath('wazuh#' + navigation.discoverPrevious)
);
}
} else if (
navigation.currLocation === navigation.discoverSections[0] ||
navigation.currLocation === navigation.discoverSections[3]
) {
$window.history.pushState(
{
page: chrome.addBasePath('wazuh#' + navigation.discoverPrevious)
},
'',
chrome.addBasePath('wazuh#' + navigation.discoverPrevious)
);
}
$window.history.pushState(
{ page: chrome.addBasePath('wazuh#' + $location.$$url) },
'',
chrome.addBasePath('wazuh#' + $location.$$url)
);
} else if ($location.search().tabView === 'cluster-monitoring') {
$window.history.pushState(
{ page: chrome.addBasePath('wazuh#/manager/') },
'',
chrome.addBasePath('wazuh#/manager/')
);
$window.history.pushState(
{ page: 'wazuh#' + $location.$$url },
'',
chrome.addBasePath('wazuh#' + $location.$$url)
);
}
}
}
appState.setNavigation({ status: false });
});
.setRootController(() => require('./app'))

});

// Added due to Kibana 6.3.0. Do not modify.
Expand Down
2 changes: 1 addition & 1 deletion public/controllers/agent/components/register-agent.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ export class RegisterAgent extends Component {
} && sudo installer -pkg ./wazuh-agent.pkg -target /`,
winText: `Invoke-WebRequest -Uri https://packages.wazuh.com/3.x/windows/wazuh-agent-${
this.state.wazuhVersion
}-1.msi -OutFile wazuh-agent.msi; wazuh-agent.msi /q ADDRESS='${
}-1.msi -OutFile wazuh-agent.msi; ./wazuh-agent.msi /q ADDRESS='${
this.state.serverAddress
}' AUTHD_SERVER='${this.state.serverAddress}'${
this.state.needsPassword
Expand Down
2 changes: 1 addition & 1 deletion public/controllers/agent/components/welcome.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export class WelcomeScreen extends Component {
<EuiSpacer size="l" />
<EuiFlexGrid columns={2}>
{this.buildTabCard('general', 'dashboardApp')}
{this.buildTabCard('fim', 'loggingApp')}
{this.buildTabCard('fim', 'filebeatApp')}
{this.buildTabCard('configuration', 'gear')}
{this.buildTabCard('syscollector', 'notebookApp')}
</EuiFlexGrid>
Expand Down
17 changes: 10 additions & 7 deletions public/controllers/misc/health-check.js
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,7 @@ export class HealthCheck {
this.checks.template = configuration['checks.template'];
this.checks.api = configuration['checks.api'];
this.checks.setup = configuration['checks.setup'];
this.checks.fields = configuration['checks.fields'];

this.results.push(
{
Expand All @@ -249,7 +250,7 @@ export class HealthCheck {
{
id: 4,
description: 'Check index pattern known fields',
status: 'Checking...'
status: this.checks.fields ? 'Checking...' : 'disabled'
}
);

Expand All @@ -261,12 +262,14 @@ export class HealthCheck {

this.checksDone = true;

try {
await this.genericReq.request('GET', '/elastic/known-fields/all', {});
this.results[this.results.length - 1].status = 'Ready';
} catch (error) {
this.results[this.results.length - 1].status = 'Error';
this.handleError(error);
if(this.checks.fields){
try {
await this.genericReq.request('GET', '/elastic/known-fields/all', {});
this.results[this.results.length - 1].status = 'Ready';
} catch (error) {
this.results[this.results.length - 1].status = 'Error';
this.handleError(error);
}
}

if (!this.errors || !this.errors.length) {
Expand Down
2 changes: 1 addition & 1 deletion public/controllers/overview/components/welcome.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ export class WelcomeScreen extends Component {
</EuiFlexGroup>
<EuiFlexGrid columns={2}>
{this.buildTabCard('general', 'dashboardApp')}
{this.buildTabCard('fim', 'loggingApp')}
{this.buildTabCard('fim', 'filebeatApp')}
{this.props.extensions.aws &&
this.buildTabCard('aws', 'logoAWSMono')}
</EuiFlexGrid>
Expand Down
2 changes: 1 addition & 1 deletion public/controllers/settings/components/add-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ export class AddApi extends Component {
const editConfigChildren = (
<div>
<EuiText>
Modify <EuiCode>kibana/plugins/wazuh/wazuh.yml</EuiCode> to set the
Modify <EuiCode>/usr/share/kibana/optimize/wazuh/config/wazuh.yml</EuiCode> to set the
connection information.
</EuiText>
<EuiSpacer />
Expand Down
4 changes: 2 additions & 2 deletions public/controllers/settings/components/api-is-down.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ export class ApiIsDown extends Component {
const apiExample = `# Example Wazuh API configuration
hosts:
- production:
url: http://172.16.1.2
url: https://172.16.1.2
port: 55000
user: foo
password: bar
Expand Down Expand Up @@ -223,7 +223,7 @@ hosts:
<div>
<EuiText>
Review the settings in the{' '}
<EuiCode>kibana/plugins/wazuh/wazuh.yml</EuiCode> file.
<EuiCode>/usr/share/kibana/optimize/wazuh/config/wazuh.yml</EuiCode> file.
</EuiText>
<EuiSpacer />
<EuiCodeBlock language="yaml">{apiExample}</EuiCodeBlock>
Expand Down
Loading

0 comments on commit 8e9dff0

Please sign in to comment.