wazuh / wazuh-qa

Wazuh - Quality Assurance
GNU General Public License v2.0
61 stars 30 forks source link

Research vulnerable packages for usage in VDT System tests #4529

Closed Deblintrake09 closed 6 months ago

Deblintrake09 commented 8 months ago
Target version Related issue Related PR/dev branch
4.8.0 #4369

Description

This Issue aims to research packages usable for the different OSs that will be supported in the new Vulnerability Detector System tests, for each test case.

Systems

Test cases

Considerations

Deblintrake09 commented 7 months ago

Proposed packages

X86_64

System E2E-VD-3 E2E-VD-4 E2E-VD-5 E2E-VD-6 E2E-VD-7 E2E-VD-9 E2E-VD-10 E2E-VD-11
Windows 11 CVE-2022-41325 - VLC Media Player 3.0.6 Mantains CVE-2022-41325 - VLC Media Player 3.0.6 -> 3.0.7 Loses CVE-2019-13962 / Adds CVE-2019-14437 - VLC Media Player 3.0.7 -> 3.0.7.1 Mantains CVE-2022-41325 / Adds CVE-2021-25801 - VLC Media Player 3.0.7.1 -> 3.0.11 Loses CVE-2021-25801 / No new vulns - VLC Media Player 3.0.11 -> 3.0.12 No CVE - VLC Media Player 3.0.18 No CVE - VLC Media Player 3.0.19 NO CVE - Adds CVE-2023-44487 - Nodejs 19.7.0 -> Nodejs v20.0.0
Windows Server 2022 CVE-2022-41325 - VLC Media Player 3.0.6 Mantains CVE-2022-41325 - VLC Media Player 3.0.6 -> 3.0.7 Loses CVE-2019-13962 / Adds CVE-2019-14437 - VLC Media Player 3.0.7 -> 3.0.7.1 Mantains CVE-2022-41325 / Adds CVE-2021-25801 - VLC Media Player 3.0.7.1 -> 3.0.11 Loses CVE-2021-25801 / No new vulns - VLC Media Player 3.0.11 -> 3.0.12 No CVE - VLC Media Player 3.0.18 No CVE - VLC Media Player 3.0.19 NO CVE - Adds CVE-2023-44487 - Nodejs 19.7.0 -> Nodejs v20.0.0
Ubuntu 2022 CVE-2023-33244 - Obsidian 0.13.23 Mantains CVE-2023-33244 - Obsidian 0.13.24 Mantains CVE-2023-33244 / Adds CVE-2023-27035 - Obsidian 1.1.9 Loses CVE-2023-33244 - Obsidian 1.2.8 NO CVEs - Obsidian 1.2.8
Centos 7 New CVE-2018-15173 - NMap 6.46-1 Mantains CVE-2018-15173 - NMap 6.47-1 Mantains CVE-2018-15173 / New CVE-2018-1000161 - NMap 7.00-1 New CVE-2017-18594 / Solved CVE-2018-1000161 - NMap 7.70-1 Solves CVE-2017-18594 + CVE-2018-15173 - NMap 7.80-1 No CVE - NMap 7.80-1 No CVE - NMap 7.90-1 PostgreSQL 14.9 -> PostgreSQL 15.4
macOS New CVE-2014-9323 - Firebird 2.0.7 Mantains CVE-2014-9323 / - Firebird 2.0.7 -> 2.1.3 Loses CVE-2013-2492 - Firebird 2.1.3 -> 2.1.6 No CVEs - Firebird 2.1.7 No CVEs - Firebird 2.1.7 -> 2.5.8 Becomes vuln CVE-2014-9323 / - Firebird 2.1.7 -> 2.5.0

ARM64

System E2E-VD-3 E2E-VD-4 E2E-VD-5 E2E-VD-6 E2E-VD-7 E2E-VD-9 E2E-VD-10 E2E-VD-11
Ubuntu 22
Centos 7
macOS
Deblintrake09 commented 7 months ago

Update

Deblintrake09 commented 7 months ago

Update

imagen

Rebits commented 7 months ago

I have conducted research on potential vulnerable package options. We propose using the following applications to conduct the suggested tests.

Rebits commented 7 months ago

Parallel approach packages

In order to proceed with a parallel approach we need to use different packages for each tests due to pytest-xdist do not allow dependent tests cases.

Case Packages Download Links CVE Information
Vulnerability Package Installation Firebird 2.0.7 RPM, Deb: None, Win, macOS Firebirdsql2.0.7
Updating a vulnerable package that remains vulnerable to the same CVE Rclone 1.49.5 -> 1.50.0 RPM1495, RPM1500, DEB1495, DEB1500, Win1495, Win1500, macOS: None RClone1.49.5, RClone1.50.0
Updating a vulnerable package that becomes vulnerable to another CVE Nmap 6.47 -> 7.00 RPM647, RPM700, WIN647, WIN700, macOS647, macOS700, Deb: None Nmap6.47, Nmap7.00
Vulnerable package that update is also vulnerable to another CVE MongoDB 4.2.11 -> 4.4.10 RPM4211, RPM4410, DEB4211, DEB4410, WIN4211, WIN4410, macOS, macOS MongoDB4.2.11, MongoDB4.4.10
Vulnerable package that update cease to be vulnerable Webmin 2.000 -> 2.003 RPM2003, RPM2000, DEB2003, deb2000 WebMin
Non-vulnerable package BleachBit 4.4.2 RPM, DEB, Win None
Non-vulnerable package that remain non-vulnerable update Mercurial 4.9.1 -> 6.5.1 RPM491, RPM651, DEB none, Windows None, macOS None Mercurial4.9.1
Non-vulnerable package that become vulnerable CounchDB 3.2.3 -> 3.3.0 RPM323, RPM330, DEB323, DEB330, Win: None, macOS: None Couchdb323, Couchdb332
Deblintrake09 commented 7 months ago

Update Research 18/10/2023

Deblintrake09 commented 7 months ago

Update Research 19/10/2023

Deblintrake09 commented 7 months ago

Update Research 20/10/2023

Rebits commented 6 months ago

Regarding new changes in the tests requirements is required to research possible packages for ARM architectures: https://github.com/wazuh/wazuh-qa/issues/4369#issuecomment-1776968917

juliamagan commented 6 months ago

Update

Started reviewing information on installing specific packages in macOS ARM

Rebits commented 6 months ago

Meeting with @juliamagan regarding research of ARM packages.

It seems nodejs could be a good option to supply almost all the cases for macOS: https://nodejs.org/dist/ Further research is required

juliamagan commented 6 months ago

macOS ARM

Case Packages Download links CVE info
E2E-VD-3: Installation of a vulnerable package Nodejs 17.0.1 node-v17.0.1.pkg Node.js-17.0.1
E2E-VD-4: Updating a vulnerable package that remains vulnerable to the same CVE Nodejs 17.0.1 -> 17.1.0 node-v17.1.0.pkg Node.js-17.1.0
E2E-VD-5: Updating a vulnerable package that becomes vulnerable to another CVE Nodejs 17.1.0 -> 18.0.0 node-v18.0.0.pkg Node.js-18.0.0
E2E-VD-6: Updating a vulnerable package that becomes vulnerable to another CVE and retains the previous one Nodejs 18.0.0 -> 18.0.1 node-v18.0.1.pkg Node.js-18.0.1
E2E-VD-7: Updating a vulnerable package that ceases to be vulnerable Nodejs 18.0.1 -> 19.5.0 node-v19.5.0.pkg Node.js-19.5.0
E2E-VD-8: Deleting a vulnerable package Any of the previous ones - -
E2E-VD-9: Installation of a non-vulnerable package Nodejs 19.5.0 node-v19.5.0.pkg Node.js-19.5.0
E2E-VD-10: Updating a non-vulnerable package that remains non-vulnerable Nodejs 19.5.0 -> 19.6.0 node-v19.6.0.pkg Node.js-19.6.0
E2E-VD-11: Updating a non-vulnerable package that becomes vulnerable Nodejs 19.6.0 -> 20.0.0 node-v20.0.0.pkg Node.js-20.0.0

CentOS 7

Case Packages Download links CVE info
E2E-VD-3: Installation of a vulnerable package
E2E-VD-4: Updating a vulnerable package that remains vulnerable to the same CVE
E2E-VD-5: Updating a vulnerable package that becomes vulnerable to another CVE
E2E-VD-6: Updating a vulnerable package that becomes vulnerable to another CVE and retains the previous one
E2E-VD-7: Updating a vulnerable package that ceases to be vulnerable
E2E-VD-8: Deleting a vulnerable package Any of the previous ones - -
E2E-VD-9: Installation of a non-vulnerable package
E2E-VD-10: Updating a non-vulnerable package that remains non-vulnerable
E2E-VD-11: Updating a non-vulnerable package that becomes vulnerable

It has been more difficult to find packages for CentOS than for macOS, it seemed that Docker could be a good option, but we are missing packages for the last two cases. Although there are future versions that may not be vulnerable or have new vulnerabilities, we found no information about these packages.

Docker: 18.09.5 -> 18.09.6 -> 19.03.0 (2) -> 20.10.15 -> Any of the previous ones -> 20.10.15 18.03.0 -> 18.06.0 ->

juliamagan commented 6 months ago

CentOS 7

Case Packages Download links CVE info
E2E-VD-3: Installation of a vulnerable package Postgresql 11.17 postgresql11-libs-11.17 and postgresql11-11.17 Postgresql-11.17
E2E-VD-4: Updating a vulnerable package that remains vulnerable to the same CVE Postgresql 11.17 -> 11.18 postgresql11-libs-11.18 and postgresql11-11.18 Postgresql-11.18
E2E-VD-5: Updating a vulnerable package that becomes vulnerable to another CVE Postgresql 11.18 -> 11.20 postgresql11-libs-11.20 and postgresql11-11.20 Postgresql-11.20
E2E-VD-6: Updating a vulnerable package that becomes vulnerable to another CVE and retains the previous one Postgresql 11.20 -> 12.12 postgresql12-libs-12.12 and postgresql12-12.12 Postgresql-12.12
E2E-VD-7: Updating a vulnerable package that ceases to be vulnerable Postgresql 12.12 -> 12.16 postgresql12-libs-12.16 and postgresql12-12.16 Postgresql-12.16
E2E-VD-8: Deleting a vulnerable package Any of the previous ones - -
E2E-VD-9: Installation of a non-vulnerable package Postgresql 12.16 postgresql12-libs-12.16 and postgresql12-12.16 Postgresql-12.16
E2E-VD-10: Updating a non-vulnerable package that remains non-vulnerable Postgresql 12.16 -> 13.12 postgresql13-libs-13.12 and postgresql13-13.12 Postgresql-13.12
E2E-VD-11: Updating a non-vulnerable package that becomes vulnerable Postgresql 13.12 -> 14.5 postgresql14-libs-14.5 and postgresql14-14.5 Postgresql-14.5

Ubuntu 22

juliamagan commented 6 months ago

Ubuntu 22

Case Packages Download links CVE info
E2E-VD-3: Installation of a vulnerable package Grafana 8.5.5 grafana-enterprise_8.5.5_arm64.deb Grafana-8.5.5
E2E-VD-4: Updating a vulnerable package that remains vulnerable to the same CVE Grafana 8.5.5 -> 8.5.6 grafana-enterprise_8.5.6_arm64.deb Grafana-8.5.6
E2E-VD-5: Updating a vulnerable package that becomes vulnerable to another CVE Grafana 8.5.6 -> 9.1.1 grafana-enterprise_9.1.1_arm64.deb Grafana-9.1.1
E2E-VD-6: Updating a vulnerable package that becomes vulnerable to another CVE and retains the previous one Grafana 9.1.1 -> 9.2.0 grafana-enterprise_9.2.0_arm64.deb Grafana-9.2.0
E2E-VD-7: Updating a vulnerable package that ceases to be vulnerable Grafana 9.2.0 -> 9.4.17 grafana-enterprise_9.4.17_arm64.deb Grafana-9.4.17
E2E-VD-8: Deleting a vulnerable package Any of the previous ones - -
E2E-VD-9: Installation of a non-vulnerable package Grafana 9.4.17 grafana-enterprise_9.4.17_arm64.deb Grafana-9.4.17
E2E-VD-10: Updating a non-vulnerable package that remains non-vulnerable Grafana 9.4.17 -> 9.5.13 grafana-enterprise_9.5.13_arm64.deb Grafana-9.5.13
E2E-VD-11: Updating a non-vulnerable package that becomes vulnerable Grafana 9.4.17 -> 10.0.0 grafana-enterprise_10.0.0_arm64.deb Grafana-10.0.0
juliamagan commented 6 months ago

Remaining AMD64 Packages

macOS

We can use the same Nodejs packages

Ubuntu

We can use the same Grafana packages

juliamagan commented 6 months ago

Conclusion

arm64

System E2E-VD-3 E2E-VD-4 E2E-VD-5 E2E-VD-6 E2E-VD-7 E2E-VD-8 E2E-VD-9 E2E-VD-10 E2E-VD-11
macOS Sonoma node-v17.0.1.pkg node-v17.1.0.pkg node-v18.0.0.pkg node-v18.0.1.pkg node-v19.5.0.pkg Any of the previous ones (except 19.5.0) node-v19.5.0.pkg node-v19.6.0.pkg node-v20.0.0.pkg
CentOS 7 postgresql11-libs-11.17 and postgresql11-11.17 postgresql11-libs-11.18 and postgresql11-11.18 postgresql11-libs-11.20 and postgresql11-11.20 postgresql12-libs-12.12 and postgresql12-12.12 postgresql12-libs-12.16 and postgresql12-12.16 Any of the previous ones (except 12.16) postgresql12-libs-12.16 and postgresql12-12.16 postgresql13-libs-13.12 and postgresql13-13.12 postgresql14-libs-14.5 and postgresql14-14.5
Ubuntu 22 grafana-enterprise_8.5.5_arm64.deb grafana-enterprise_8.5.6_arm64.deb grafana-enterprise_9.1.1_arm64.deb grafana-enterprise_9.2.0_arm64.deb grafana-enterprise_9.4.17_arm64.deb Any of the previous ones (except 9.4.17) grafana-enterprise_9.4.17_arm64.deb grafana-enterprise_9.5.13_arm64.deb grafana-enterprise_10.0.0_arm64.deb

Research:

x64

System E2E-VD-3 E2E-VD-4 E2E-VD-5 E2E-VD-6 E2E-VD-7 E2E-VD-8 E2E-VD-9 E2E-VD-10 E2E-VD-11
macOS node-v17.0.1.pkg node-v17.1.0.pkg node-v18.0.0.pkg node-v18.0.1.pkg node-v19.5.0.pkg Any of the previous ones (except 19.5.0) node-v19.5.0.pkg node-v19.6.0.pkg node-v20.0.0.pkg
CentOS 7 NMap 6.46-1 NMap 6.47-1 NMap 7.00-1 NMap 7.70-1 NMap 7.80-1 Any of the previous ones (except 7.80-1) NMap 7.80-1 NMap 7.90-1 PostgreSQL 14.9 -> PostgreSQL 15.4
Ubuntu 22 grafana-enterprise_8.5.5_amd64.deb grafana-enterprise_8.5.6_amd64.deb grafana-enterprise_9.1.1_amd64.deb grafana-enterprise_9.2.0_amd64.deb grafana-enterprise_9.4.17_amd64.deb Any of the previous ones (except 9.4.17) grafana-enterprise_9.4.17_amd64.deb grafana-enterprise_9.5.13_amd64.deb grafana-enterprise_10.0.0_amd64.deb
Windows 11 VLC Media Player 3.0.6 VLC Media Player 3.0.6 -> 3.0.7 VLC Media Player 3.0.7 -> 3.0.7.1 VLC Media Player 3.0.7.1 -> 3.0.11 VLC Media Player 3.0.11 -> 3.0.12 Any of the previous ones (except 3.0.18) VLC Media Player 3.0.18 VLC Media Player 3.0.19 Nodejs 19.7.0 -> Nodejs v20.0.0
Windows Server 2022 VLC Media Player 3.0.6 VLC Media Player 3.0.6 -> 3.0.7 VLC Media Player 3.0.7 -> 3.0.7.1 VLC Media Player 3.0.7.1 -> 3.0.11 VLC Media Player 3.0.11 -> 3.0.12 Any of the previous ones (except 3.0.18) VLC Media Player 3.0.18 VLC Media Player 3.0.19 Nodejs 19.7.0 -> Nodejs v20.0.0

Research:

Deblintrake09 commented 6 months ago

LGTM! Approved!

davidjiglesias commented 6 months ago

LGTM!