ssllatency.bt(8)
π ssllatency.bt(8) π
okay so this is the System Manager's Manual page for ssllatency.bt, and it's giving main character energy π¦β¨
πΈ NAME πΈ
ssllatency.bt is a bpftrace/eBPF tool that shows a histogram of SSL/TLS handshake latency ππ
π SYNOPSIS π
ssllatency.bt
β¨ DESCRIPTION β¨
okay so ssllatency shows you the latency distribution for OpenSSL handshake functions π₯Ί this is lowkey so useful for performance analysis when you're comparing different crypto cipher suites, or async SSL acceleration by CPU or offload device, etc π
it works by dynamically tracing the uprobes in OpenSSL and related crypto libs π but heads up, it might need updating to keep up with future changes to those functions π
Root only! Since this uses BPF, only the root user can run this tool π
π§ REQUIREMENTS π§
you'll need CONFIG_BPF and bpftrace π οΈ
π EXAMPLES π
trace SSL/TLS handshake latency, and print a histogram when you hit Ctrl-C π―
# ssllatency.bt
π FIELDS π
okay so here's how to read the output, bestie π«Ά
- 0th β a function name shows up in
@hist[...]followed by its latency histogram, and then@stat[...]followed by the total call count, the average, and the total latency in microseconds π non-zero failed calls get traced separately (in@histF[]and@statF[]) for some functions π - 1st, 2nd β this is a range of latency in microseconds, shown in
[...)set notation π - 3rd β a column showing the count of operations in that range π’
- 4th β an ASCII histogram representing the count column π¨
π¦ OVERHEAD π¦
ngl the overhead is basically nothing π SSL/TLS handshakes already include network latency, and the crypto functions being traced are CPU intensive, so the call frequency should be low and the overhead of this tool is expected to be negligible β¨
π SOURCE π
this comes from bpftrace π«§
https://github.com/bpftrace/bpftrace
also check out the bpftrace distribution for a companion _examples.txt file π it has example usage, output, and commentary for this tool π
there's also a bcc tool called sslsniff that can show SSL/TLS handshake event latency before sniffing the plaintext in SSL_read/write π this tool gives you more detailed crypto latency distribution during the handshake event π₯
https://github.com/iovisor/bcc
π§ OS π§
Linux only, bestie π§
π§ STABILITY π§
this is Unstable β still in development π οΈπ
π AUTHOR π
written by Tao Xu π
π SEE ALSO π
sslsnoop.bt(8) π«Ά
and that's the whole page π the footer says it's from the USER COMMANDS section, dated 2021-12-28 π stay iconic, bestie β¨π¦
π¦ where this page comes from
- alpine 3.24: bpftrace-tools-doc 0.26.1-r0 Β· Apache-2.0
- arch rolling: bpftrace 0.27.0-2 Β· Apache-2.0
- centos-stream 10: bpftrace 0.26.1-1.el10 Β· Apache-2.0
- centos-stream 9: bpftrace 0.26.1-1.el9 Β· ASL 2.0
- debian trixie: bpftrace 0.23.2-1 Β· Apache-2.0
- fedora 43: bpftrace 0.24.0-1.fc43 Β· Apache-2.0
- fedora 43: bpftrace 0.24.2-1.fc43 Β· Apache-2.0
- fedora 44: bpftrace 0.24.2-3.fc44 Β· Apache-2.0
- nixos 26.05: bpftrace 0.25.1
- nixpkgs unstable: bpftrace 0.27.1
- opensuse-leap 16.0: bpftrace-tools 0.23.5-160000.1.2 Β· Apache-2.0
- ubuntu questing: bpftrace 0.23.5-1ubuntu1 Β· Apache-2.0
- ubuntu resolute: bpftrace 0.25.0-1ubuntu1 Β· Apache-2.0
- ubuntu stonking: bpftrace 0.25.0-1ubuntu2 Β· Apache-2.0
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms