[BUG] 30-sslsniff: make: *** [Makefile:86: /home/pegasus/Documents/bpf-developer-tutorial/src/30-sslsniff/.output/libbpf.a] Error 2
Describe the bug When I'm trying to build the sslsniff tool from lesson 30 I face the following error: make: *** [Makefile:86: /home/pegasus/Documents/bpf-developer-tutorial/src/30-sslsniff/.output/libbpf.a] Error 2
To Reproduce
use make from the 30-sslsniff directory.
pegasus@pegasus:~/Documents/bpf-developer-tutorial/src/30-sslsniff$ make
MKDIR .output
MKDIR .output/libbpf
LIB libbpf.a
make[1]: *** /home/pegasus/Documents/bpf-developer-tutorial/src/third_party/libbpf/src: No such file or directory. Stop.
make: *** [Makefile:86: /home/pegasus/Documents/bpf-developer-tutorial/src/30-sslsniff/.output/libbpf.a] Error 2
Expected behavior It should build the tool properly
Screenshots
Desktop (please complete the following information):
pegasus@pegasus:~$ cat /etc/os-release
PRETTY_NAME="Ubuntu 24.04 LTS"
NAME="Ubuntu"
VERSION_ID="24.04"
VERSION="24.04 LTS (Noble Numbat)"
VERSION_CODENAME=noble
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=noble
LOGO=ubuntu-logo
pegasus@pegasus:~$ uname -a
Linux pegasus 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Seems to miss submodules. Try
git submodule init --update --recursive
I already have my libbpf inside the 30-sslsniff directory and built it there. Where should I have it?
Where should I have it?
git submodule update --init --recursive
Run this under the top-level of bpf-developer-tutorial directory. This will init the git submodule in ./src/thirdparty/libbpf
The output
pegasus@pegasus:~/Documents/bpf-developer-tutorial$ git submodule init --update --recursive
usage: git submodule [--quiet] [--cached]
or: git submodule [--quiet] add [-b <branch>] [-f|--force] [--name <name>] [--reference <repository>] [--] <repository> [<path>]
or: git submodule [--quiet] status [--cached] [--recursive] [--] [<path>...]
or: git submodule [--quiet] init [--] [<path>...]
or: git submodule [--quiet] deinit [-f|--force] (--all| [--] <path>...)
or: git submodule [--quiet] update [--init [--filter=<filter-spec>]] [--remote] [-N|--no-fetch] [-f|--force] [--checkout|--merge|--rebase] [--[no-]recommend-shallow] [--reference <repository>] [--recursive] [--[no-]single-branch] [--] [<path>...]
or: git submodule [--quiet] set-branch (--default|--branch <branch>) [--] <path>
or: git submodule [--quiet] set-url [--] <path> <newurl>
or: git submodule [--quiet] summary [--cached|--files] [--summary-limit <n>] [commit] [--] [<path>...]
or: git submodule [--quiet] foreach [--recursive] <command>
or: git submodule [--quiet] sync [--recursive] [--] [<path>...]
or: git submodule [--quiet] absorbgitdirs [--] [<path>...]
Or clone the entire repo with --recursive arg
The output
pegasus@pegasus:~/Documents/bpf-developer-tutorial$ git submodule init --update --recursive usage: git submodule [--quiet] [--cached] or: git submodule [--quiet] add [-b <branch>] [-f|--force] [--name <name>] [--reference <repository>] [--] <repository> [<path>] or: git submodule [--quiet] status [--cached] [--recursive] [--] [<path>...] or: git submodule [--quiet] init [--] [<path>...] or: git submodule [--quiet] deinit [-f|--force] (--all| [--] <path>...) or: git submodule [--quiet] update [--init [--filter=<filter-spec>]] [--remote] [-N|--no-fetch] [-f|--force] [--checkout|--merge|--rebase] [--[no-]recommend-shallow] [--reference <repository>] [--recursive] [--[no-]single-branch] [--] [<path>...] or: git submodule [--quiet] set-branch (--default|--branch <branch>) [--] <path> or: git submodule [--quiet] set-url [--] <path> <newurl> or: git submodule [--quiet] summary [--cached|--files] [--summary-limit <n>] [commit] [--] [<path>...] or: git submodule [--quiet] foreach [--recursive] <command> or: git submodule [--quiet] sync [--recursive] [--] [<path>...] or: git submodule [--quiet] absorbgitdirs [--] [<path>...]
sry it should be git submodule update --init --recursive I made a typo
@oluceps Thanks I was able to run it. Following the suggestions you provided.
But sslsniff is unable to provide any output.
@oluceps Thanks I was able to run it. Following the suggestions you provided. But sslsniff is unable to provide any output.
Try curl --tlsv1.2 https://example.com/
@oluceps same result.
@oluceps same result.
Try use the same user as sslsniff when running curl
They are the same user. What do you mean? @Officeyutong
They are the same user.
What do you mean?
@Officeyutong
You are using root to run sslsniff but using pegasus to run curl
Without using sudo ./sslsniff It doesn't work.
The documentation also suggests to use sudo sslsniff in one terminal and in another terminal use curl.
It works fine with sudo curl though.
But I want to also capture normal firefox or curl traffic from sslsniff. Without using sudo.
How can I achieve it?
Without using
sudo ./sslsniffIt doesn't work.The documentation also suggests to use
sudo sslsniffin one terminal and in another terminal usecurl.It works fine with
sudo curlthough. But I want to also capture normal firefox orcurltraffic from sslsniff. Without using sudo. How can I achieve it?
It's an issue to be solved...I don't know how to capture traffic by other users. If you are interested in it, you may try to research on it
It should be able to capture traffic by other users. Let's see what happend.
The cilium slack has some discussion about that. Maybe we can add them in the tutorial.
Can you speak chinese? 我试了chrome也是无法获取到流量,看到chrome使用的是/lib/x86_64-linux-gnu/libgnutls.so,不过在sslsniff开始的输出中,看到了对gnutls的支持


