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

Can’t install on Kali due to libcurl 7.58 needed vs 7.65 used by all other apps #153

Closed
ih8github opened this issue Jul 18, 2020 · 12 comments

Comments

@ih8github
Copy link

ih8github commented Jul 18, 2020

In Kali wifite needs this to work properly, but this needs old versions of SSL and curl libs (I can be specific as needed).

hcxtools make can’t find curl.h. So trying to install the libcurl4-OpenSSL-dev you get a message that it requires an old (7.58) version of libcurl4.

libcurl4 is installed with the newest version (7.65), which is necessary for maltego, metasploit, etc.

hcxtools requires libcurl4=7.58.0-2ubuntu3.9

which would break and therefore uninstall all of those other major apps. I’m not sure why hcxtools can’t just use 7.65?

Any workaround? Can the old library be installed in some sort of virtual environment just for hcxtools or something?

@ih8github ih8github changed the title Can’t install on Kali without breaking everything else due to downgrades Can’t install on Kali due to libcurl 7.58 needed vs 7.65 used by all other apps Jul 18, 2020
@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

That is a KALI issue and you should report it there.
hcxdumptool is running fine on the latest curl:
$ pacman -Q | grep curl
curl 7.71.1-1
As you can see, 7.71 is in use here!

I assume, your package management is broken or outdated.
latest curl version on KALI:
curl 7.68.0-1 imported into kali-rolling
https://pkg.kali.org/pkg/curl

latest KALI:
Kali 2020.2 – 12th May, 2020 – The second 2020 Kali Rolling release. Kernel 5.5.0, XFCE 4.14.4
https://www.kali.org/kali-linux-releases/

Everything else is outdated and will no longer be under mantainance

Which version of KALI do you use?

@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

Cloese this, because it isn't an hcxtools issue, but you can still ask your questions here.

@ZerBea ZerBea closed this as completed Jul 19, 2020
@ih8github
Copy link
Author

Alright let’s open an Issue on Kali and link it to this one

I hear and believe what you’re saying but I think you were showing the curl bin version not library

@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

What version of KALI do you use?

Here is the file list of Arch Linux:
https://www.archlinux.org/packages/core/x86_64/curl/files/

If you install something on Arch Linux, all development files are included! I never(!) understood, why you need 2 packages running Debian and Debian Clones!
https://stackoverflow.com/questions/1157192/what-do-the-dev-packages-in-the-linux-package-repositories-actually-contain
If a dev package doesn't match to the tool package, it is an issue of the distribution - or your packet management system isn't updated.

@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

compiling without any issue on Arch Linux ( -lcrypto -lssl -lcurl inclusive) :

$ make clean
$ make
mkdir -p .deps
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpcapngtool.d -o hcxpcapngtool hcxpcapngtool.c -lz -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhashtool.d -o hcxhashtool hcxhashtool.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpsktool.d -o hcxpsktool hcxpsktool.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxwltool.d -o hcxwltool hcxwltool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhash2cap.d -o hcxhash2cap hcxhash2cap.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlancap2wpasec.d -o wlancap2wpasec wlancap2wpasec.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/whoismac.d -o whoismac whoismac.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpmkidtool.d -o hcxpmkidtool hcxpmkidtool.c -lcrypto -lssl -lpthread  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcx2john.d -o wlanhcx2john wlanhcx2john.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpcaptool.d -o hcxpcaptool hcxpcaptool.c -lz -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhashcattool.d -o hcxhashcattool hcxhashcattool.c -lcrypto -lssl -lpthread  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxmactool.d -o hcxmactool hcxmactool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxessidtool.d -o hcxessidtool hcxessidtool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanwkp2hcx.d -o wlanwkp2hcx wlanwkp2hcx.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcxinfo.d -o wlanhcxinfo wlanhcxinfo.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcx2ssid.d -o wlanhcx2ssid wlanhcx2ssid.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcxcat.d -o wlanhcxcat wlanhcxcat.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanpmk2hcx.d -o wlanpmk2hcx wlanpmk2hcx.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanjohn2hcx.d -o wlanjohn2hcx wlanjohn2hcx.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"

now installing:

$ sudo make install
install -D -m 0644 manpages/hcxpcapngtool.1 /usr/local/share/man/man1/hcxpcapngtool.1
install -D -m 0755 hcxpcapngtool /usr/local/bin/hcxpcapngtool
install -D -m 0644 manpages/hcxhashtool.1 /usr/local/share/man/man1/hcxhashtool.1
install -D -m 0755 hcxhashtool /usr/local/bin/hcxhashtool
install -D -m 0644 manpages/hcxpsktool.1 /usr/local/share/man/man1/hcxpsktool.1
install -D -m 0755 hcxpsktool /usr/local/bin/hcxpsktool
install -D -m 0755 hcxwltool /usr/local/bin/hcxwltool
install -D -m 0644 manpages/hcxhash2cap.1 /usr/local/share/man/man1/hcxhash2cap.1
install -D -m 0755 hcxhash2cap /usr/local/bin/hcxhash2cap
install -D -m 0644 manpages/wlancap2wpasec.1 /usr/local/share/man/man1/wlancap2wpasec.1
install -D -m 0755 wlancap2wpasec /usr/local/bin/wlancap2wpasec
install -D -m 0755 whoismac /usr/local/bin/whoismac
install -D -m 0755 hcxpmkidtool /usr/local/bin/hcxpmkidtool
install -D -m 0755 wlanhcx2john /usr/local/bin/wlanhcx2john
install -D -m 0644 manpages/hcxpcaptool.1 /usr/local/share/man/man1/hcxpcaptool.1
install -D -m 0755 hcxpcaptool /usr/local/bin/hcxpcaptool
install -D -m 0755 hcxhashcattool /usr/local/bin/hcxhashcattool
install -D -m 0755 hcxmactool /usr/local/bin/hcxmactool
install -D -m 0755 hcxessidtool /usr/local/bin/hcxessidtool
install -D -m 0755 wlanwkp2hcx /usr/local/bin/wlanwkp2hcx
install -D -m 0755 wlanhcxinfo /usr/local/bin/wlanhcxinfo
install -D -m 0755 wlanhcx2ssid /usr/local/bin/wlanhcx2ssid
install -D -m 0755 wlanhcxcat /usr/local/bin/wlanhcxcat
install -D -m 0755 wlanpmk2hcx /usr/local/bin/wlanpmk2hcx
install -D -m 0755 wlanjohn2hcx /usr/local/bin/wlanjohn2hcx

@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

Have you updated KALI to latest version?
Have you updated your packages list?
https://www.kali.org/docs/general-use/kali-linux-sources-list-repositories/
https://computingforgeeks.com/add-kali-linux-official-repositories-to-sources-list/

What is the output of:
$ cat /etc/os-release

Did you run make clean, before you run make?

@ih8github
Copy link
Author

In case you want to jump in:

https://bugs.kali.org/view.php?id=6588

@steev
Copy link

steev commented Jul 19, 2020

Where are you getting this

hcxtools requires libcurl4=7.58.0-2ubuntu3.9

from - that is an ubuntu package, and not kali package. If you're mixing and matching things from ubuntu... you're gonna have a bad time, but hcxtools builds just fine on a kali installation.

~/git/temp/hcxtools$ cat /etc/os-release
PRETTY_NAME="Kali GNU/Linux Rolling"
NAME="Kali GNU/Linux"
ID=kali
VERSION="2020.2"
VERSION_ID="2020.2"
VERSION_CODENAME="kali-rolling"
ID_LIKE=debian
ANSI_COLOR="1;31"
HOME_URL="https://www.kali.org/"
SUPPORT_URL="https://forums.kali.org/"
BUG_REPORT_URL="https://bugs.kali.org/"
~/git/temp/hcxtools$ make
mkdir -p .deps
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpcapngtool.d -o hcxpcapngtool hcxpcapngtool.c -lz -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhashtool.d -o hcxhashtool hcxhashtool.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpsktool.d -o hcxpsktool hcxpsktool.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxwltool.d -o hcxwltool hcxwltool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhash2cap.d -o hcxhash2cap hcxhash2cap.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlancap2wpasec.d -o wlancap2wpasec wlancap2wpasec.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/whoismac.d -o whoismac whoismac.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpmkidtool.d -o hcxpmkidtool hcxpmkidtool.c -lcrypto -lssl -lpthread  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcx2john.d -o wlanhcx2john wlanhcx2john.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxpcaptool.d -o hcxpcaptool hcxpcaptool.c -lz -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhashcattool.d -o hcxhashcattool hcxhashcattool.c -lcrypto -lssl -lpthread  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxmactool.d -o hcxmactool hcxmactool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxessidtool.d -o hcxessidtool hcxessidtool.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanwkp2hcx.d -o wlanwkp2hcx wlanwkp2hcx.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcxinfo.d -o wlanhcxinfo wlanhcxinfo.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcx2ssid.d -o wlanhcx2ssid wlanhcx2ssid.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanhcxcat.d -o wlanhcxcat wlanhcxcat.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanpmk2hcx.d -o wlanpmk2hcx wlanpmk2hcx.c -lcrypto -lssl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/wlanjohn2hcx.d -o wlanjohn2hcx wlanjohn2hcx.c   -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"

@ant1github
Copy link

ant1github commented Jul 19, 2020

@steev Hi Steev it's me, the author (I had to use a different account within Kali to get into github - long story).

root@kali:~/hcxtools# make
cc -O3 -Wall -Wextra -std=gnu99  -MMD -MF .deps/hcxhashtool.d -o hcxhashtool hcxhashtool.c -lcrypto -lssl -lcurl  -DVERSION_TAG=\"6.0.3-24-ge59a4ed\" -DVERSION_YEAR=\"2020\"
hcxhashtool.c:19:10: fatal error: curl/curl.h: No such file or directory
 #include <curl/curl.h>
          ^~~~~~~~~~~~~
compilation terminated.
make: *** [Makefile:112: hcxhashtool] Error 1
root@kali:~/hcxtools# 

root@kali:~/hcxtools# curl --version
curl 7.65.3 (x86_64-pc-linux-gnu) libcurl/7.65.3 OpenSSL/1.1.1 zlib/1.2.11 libidn2/2.2.0 libpsl/0.20.2 (+libidn2/2.0.5) libssh2/1.8.0 nghttp2/1.39.2 librtmp/2.3
Release-Date: 2019-07-19
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp scp sftp smb smbs smtp smtps telnet tftp 
Features: AsynchDNS GSS-API HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz NTLM NTLM_WB PSL SPNEGO SSL TLS-SRP UnixSockets

That led me to install the libraries mentioned in README.md, which depended on libcurl4 being an older version (I can show those steps if needed).

but to my surprise, the Kali version is from late last year. Is that the problem? I can upgrade if needed:

root@kali:~/hcxtools# cat /etc/os-release 
PRETTY_NAME="Kali GNU/Linux Rolling"
NAME="Kali GNU/Linux"
ID=kali
VERSION="2019.3"
VERSION_ID="2019.3"
VERSION_CODENAME="kali-rolling"
ID_LIKE=debian
ANSI_COLOR="1;31"
HOME_URL="https://www.kali.org/"
SUPPORT_URL="https://forums.kali.org/"
BUG_REPORT_URL="https://bugs.kali.org/"

@steev
Copy link

steev commented Jul 19, 2020

Yes, you should upgrade. I'm not even sure if those old versions are even still on the servers.

@ant1github
Copy link

@steev OK thanks Steev. I will do so and confirm that it's fixed. Many thanks.

@ZerBea
Copy link
Owner

ZerBea commented Jul 19, 2020

That is the keyword: kali-rolling
VERSION="2020.2"
VERSION_ID="2020.2"
VERSION_CODENAME="kali-rolling"

Major problem is that your old sources.list "meet" the newer and updated sources.list on the server and you will run into that issues.
@steev thanks for explainig it.

Be sure, hcxtools and hcxdumptool are rolling releases, too. They depend on latest tools and libs (like Arch Linux, too).
That means: To compile and use the tools, you must update your distribution to latest version. This is mandatory to perform new attack vectors. We need latest (fixed) drivers as well as latest libs. That include gcc, too. I do not support an ancient version of gcc (e.g. gcc 6 https://gcc.gnu.org/gcc-6 found in ancient UBUNTU LTS versions).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants