Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add: Added conversion routines for different CPE notation formats. #827

Merged
merged 7 commits into from
Jul 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ if (BUILD_TESTS AND NOT SKIP_SRC)

add_custom_target (tests
DEPENDS array-test alivedetection-test boreas_error-test boreas_io-test
cli-test cvss-test ping-test sniffer-test util-test networking-test
cli-test cpeutils-test cvss-test ping-test sniffer-test util-test networking-test
passwordbasedauthentication-test xmlutils-test version-test osp-test
nvti-test hosts-test)

Expand Down
22 changes: 20 additions & 2 deletions util/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -109,11 +109,11 @@ endif (BUILD_WITH_LDAP)
include_directories (${GLIB_INCLUDE_DIRS} ${GPGME_INCLUDE_DIRS} ${GCRYPT_INCLUDE_DIRS}
${LIBXML2_INCLUDE_DIRS})

set (FILES passwordbasedauthentication.c compressutils.c fileutils.c gpgmeutils.c kb.c ldaputils.c
set (FILES cpeutils.c passwordbasedauthentication.c compressutils.c fileutils.c gpgmeutils.c kb.c ldaputils.c
nvticache.c mqtt.c radiusutils.c serverutils.c sshutils.c uuidutils.c
xmlutils.c)

set (HEADERS passwordbasedauthentication.h authutils.h compressutils.h fileutils.h gpgmeutils.h kb.h
set (HEADERS cpeutils.h passwordbasedauthentication.h authutils.h compressutils.h fileutils.h gpgmeutils.h kb.h
ldaputils.h nvticache.h mqtt.h radiusutils.h serverutils.h sshutils.h
uuidutils.h xmlutils.h)

Expand Down Expand Up @@ -161,6 +161,24 @@ if (BUILD_TESTS)
add_custom_target (tests-passwordbasedauthentication
DEPENDS passwordbasedauthentication-test)

add_executable (cpeutils-test
EXCLUDE_FROM_ALL
cpeutils_tests.c)

add_test (cpeutils-test cpeutils-test)

target_include_directories (cpeutils-test PRIVATE ${CGREEN_INCLUDE_DIRS})

target_link_libraries (cpeutils-test ${CGREEN_LIBRARIES}
${GLIB_LDFLAGS} ${GIO_LDFLAGS} ${GPGME_LDFLAGS} ${ZLIB_LDFLAGS}
${RADIUS_LDFLAGS} ${LIBSSH_LDFLAGS} ${GNUTLS_LDFLAGS}
${GCRYPT_LDFLAGS} ${LDAP_LDFLAGS} ${REDIS_LDFLAGS}
${LIBXML2_LDFLAGS} ${UUID_LDFLAGS}
${LINKER_HARDENING_FLAGS})

add_custom_target (tests-cpeutils
DEPENDS cpeutils-test)

add_executable (xmlutils-test
EXCLUDE_FROM_ALL
xmlutils_tests.c)
Expand Down
Loading
Loading