Git Product home page Git Product logo

Comments (13)

ZerBea avatar ZerBea commented on September 23, 2024

hcxtools moved to OpenSSL 3.0 since 10.03.2023.

changelog:

10.03.2023
==========
release v6.2.8
moved to EVP API 3.0 (from now on OpenSSL >= 3.0 is mandatory)

README.md (section Requirements):
* libopenssl (>= 3.0) and openssl-dev installed

OpenSSL < v3.0 does not provide this new API
https://www.openssl.org/docs/man3.0/man3/EVP_MAC.html
and it is mandatory to upgrade to at least v3.0

You received the ERRORS and the WARNINGS, because the 3.0 header files are missing on your system.

More information is e.g. here:
#228

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

If the development files are installed:

$ pacman -Q | grep ssl
openssl 3.0.8-1

hcxtools compile (-lssl) as expected:

$ make
mkdir -p .deps
cc -O3 -Wall -Wextra -std=gnu99    -MMD -MF .deps/hcxpcapngtool.d -o hcxpcapngtool hcxpcapngtool.c -lssl -lcrypto  -lz   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99    -MMD -MF .deps/hcxhashtool.d -o hcxhashtool hcxhashtool.c -lssl -lcrypto  -lcurl   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99   -MMD -MF .deps/hcxpsktool.d -o hcxpsktool hcxpsktool.c -lssl -lcrypto   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99   -MMD -MF .deps/hcxpmktool.d -o hcxpmktool hcxpmktool.c -lssl -lcrypto   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99   -MMD -MF .deps/hcxeiutool.d -o hcxeiutool hcxeiutool.c   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99   -MMD -MF .deps/hcxwltool.d -o hcxwltool hcxwltool.c   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99   -MMD -MF .deps/hcxhash2cap.d -o hcxhash2cap hcxhash2cap.c   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99    -MMD -MF .deps/wlancap2wpasec.d -o wlancap2wpasec wlancap2wpasec.c -lssl -lcrypto  -lcurl   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB
cc -O3 -Wall -Wextra -std=gnu99    -MMD -MF .deps/whoismac.d -o whoismac whoismac.c -lssl -lcrypto  -lcurl   -DVERSION_TAG=\"6.3.0-3-gd615cc2\" -DVERSION_YEAR=\"2023\" -DWANTZLIB

the same applies to install:

$ sudo make install
install -D -m 0755 hcxpcapngtool /usr/bin/hcxpcapngtool
install -D -m 0755 hcxhashtool /usr/bin/hcxhashtool
install -D -m 0755 hcxpsktool /usr/bin/hcxpsktool
install -D -m 0755 hcxpmktool /usr/bin/hcxpmktool
install -D -m 0755 hcxeiutool /usr/bin/hcxeiutool
install -D -m 0755 hcxwltool /usr/bin/hcxwltool
install -D -m 0755 hcxhash2cap /usr/bin/hcxhash2cap
install -D -m 0755 wlancap2wpasec /usr/bin/wlancap2wpasec
install -D -m 0755 whoismac /usr/bin/whoismac

from hcxtools.

goliath29 avatar goliath29 commented on September 23, 2024

I have removed Openssl and updated to Openssl 3.1.0, but am still unable to run the make command, displaying the same error as above.

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

Have you installed the OpenSSL includes, too.
I ask this, because your compilers does not find them.

By default installation, they are placed here:
/usr/include/openssl/

$ cd /usr/include/openssl/
$ grep -r EVP_MAC
types.h:typedef struct evp_mac_st EVP_MAC;
types.h:typedef struct evp_mac_ctx_st EVP_MAC_CTX;
evp.h:EVP_MAC *EVP_MAC_fetch(OSSL_LIB_CTX *libctx, const char *algorithm,
evp.h:int EVP_MAC_up_ref(EVP_MAC *mac);
evp.h:void EVP_MAC_free(EVP_MAC *mac);
evp.h:const char *EVP_MAC_get0_name(const EVP_MAC *mac);
evp.h:const char *EVP_MAC_get0_description(const EVP_MAC *mac);
evp.h:int EVP_MAC_is_a(const EVP_MAC *mac, const char *name);
evp.h:const OSSL_PROVIDER *EVP_MAC_get0_provider(const EVP_MAC *mac);
evp.h:int EVP_MAC_get_params(EVP_MAC *mac, OSSL_PARAM params[]);
evp.h:EVP_MAC_CTX *EVP_MAC_CTX_new(EVP_MAC *mac);
evp.h:void EVP_MAC_CTX_free(EVP_MAC_CTX *ctx);
evp.h:EVP_MAC_CTX *EVP_MAC_CTX_dup(const EVP_MAC_CTX *src);
evp.h:EVP_MAC *EVP_MAC_CTX_get0_mac(EVP_MAC_CTX *ctx);
evp.h:int EVP_MAC_CTX_get_params(EVP_MAC_CTX *ctx, OSSL_PARAM params[]);
evp.h:int EVP_MAC_CTX_set_params(EVP_MAC_CTX *ctx, const OSSL_PARAM params[]);
evp.h:size_t EVP_MAC_CTX_get_mac_size(EVP_MAC_CTX *ctx);
evp.h:size_t EVP_MAC_CTX_get_block_size(EVP_MAC_CTX *ctx);
evp.h:int EVP_MAC_init(EVP_MAC_CTX *ctx, const unsigned char *key, size_t keylen,
evp.h:int EVP_MAC_update(EVP_MAC_CTX *ctx, const unsigned char *data, size_t datalen);
evp.h:int EVP_MAC_final(EVP_MAC_CTX *ctx,
evp.h:int EVP_MAC_finalXOF(EVP_MAC_CTX *ctx, unsigned char *out, size_t outsize);
evp.h:const OSSL_PARAM *EVP_MAC_gettable_params(const EVP_MAC *mac);
evp.h:const OSSL_PARAM *EVP_MAC_gettable_ctx_params(const EVP_MAC *mac);
evp.h:const OSSL_PARAM *EVP_MAC_settable_ctx_params(const EVP_MAC *mac);
evp.h:const OSSL_PARAM *EVP_MAC_CTX_gettable_params(EVP_MAC_CTX *ctx);
evp.h:const OSSL_PARAM *EVP_MAC_CTX_settable_params(EVP_MAC_CTX *ctx);
evp.h:void EVP_MAC_do_all_provided(OSSL_LIB_CTX *libctx,
evp.h:                             void (*fn)(EVP_MAC *mac, void *arg),
evp.h:int EVP_MAC_names_do_all(const EVP_MAC *mac,
tls1.h:                             EVP_CIPHER_CTX *, EVP_MAC_CTX *, int));

And they are missing on versions < 3.x:

$ cd /usr/include/openssl-1.0/openssl/
$ grep -r EVP_MAC
$ 

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

While evp.h is present on all OpenSSL versions.

$ locate evp.h
/usr/include/openssl/evp.h
/usr/include/openssl-1.0/openssl/evp.h
/usr/include/xmlsec1/xmlsec/openssl/evp.h

The new EVP API is only present on > 3.0
/usr/include/openssl/evp.h

older versions do not provide this API:
/usr/include/openssl-1.0/openssl/evp.h

from hcxtools.

goliath29 avatar goliath29 commented on September 23, 2024

I have since reinstalled libssl, openssl and hcxtools again to no success.

I do have the evp.h as mentioned above, but the error still persists.

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

How have you installed openssl?
Via package manager of your Linux distribution? In that case your distribution should know where to find the includes.
or
From source? In that case, your Linux distribution does not know about the includes and you have to set path by hand.
How to do this, depend on your Linux distribution.

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

This will show the active version:

$ openssl version
OpenSSL 3.0.8 7 Feb 2023 (Library: OpenSSL 3.0.8 7 Feb 2023)

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

This will show gcc default include path:

$ `gcc -print-prog-name=cc1` -v
 /usr/lib/gcc/x86_64-pc-linux-gnu/13.1.1/include
 /usr/local/include
 /usr/lib/gcc/x86_64-pc-linux-gnu/13.1.1/include-fixed
 /usr/include

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

This will cd into the default openssl path:
$ cd /usr/include/openssl

this will list the EVP API:

$ grep -R EVP_MAC
types.h:typedef struct evp_mac_st EVP_MAC;
types.h:typedef struct evp_mac_ctx_st EVP_MAC_CTX;
...

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

That should be the default on all Linux distributions.

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

It looks the other conditions apply

* zlib and zlib-dev installed (for gzip compressed cap/pcap/pcapng files)
* libcurl (>= 7.56) and curl-dev installed (used by whoismac and wlancap2wpasec)
* pkg-config installed

and pkg-config find them.
Is openssl.pc present in pkg-config dir and point it to the correct path?

$ cat /usr/lib/pkgconfig/openssl.pc
prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: OpenSSL
Description: Secure Sockets Layer and cryptography libraries and tools
Version: 3.0.8
Requires: libssl libcrypto

BTW:
Which gcc version do you use?

The other conditions

from hcxtools.

ZerBea avatar ZerBea commented on September 23, 2024

Closed due to missing dependency.

from hcxtools.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.