diff --git a/tap/tlstapper/bpf/common.c b/tap/tlstapper/bpf/common.c index 02b79c026..a4dad45a6 100644 --- a/tap/tlstapper/bpf/common.c +++ b/tap/tlstapper/bpf/common.c @@ -18,12 +18,9 @@ static __always_inline int add_address_to_chunk(struct pt_regs *ctx, struct tls_ struct fd_info *fdinfo = bpf_map_lookup_elem(&file_descriptor_to_ipv4, &key); - log_error(ctx, LOG_DEBUG, 0, 0, 0); if (fdinfo == NULL) { - log_error(ctx, LOG_DEBUG, 1, 0, 0); return 0; } - log_error(ctx, LOG_DEBUG, 2, 0, 0); int err; diff --git a/tap/tlstapper/bpf/go_uprobes.c b/tap/tlstapper/bpf/go_uprobes.c index af49bb48d..28e3c6aad 100644 --- a/tap/tlstapper/bpf/go_uprobes.c +++ b/tap/tlstapper/bpf/go_uprobes.c @@ -217,6 +217,8 @@ static __always_inline void go_crypto_tls_uprobe(struct pt_regs *ctx, struct bpf log_error(ctx, LOG_ERROR_PUTTING_SSL_CONTEXT, pid_tgid, err, 0l); } + log_error(ctx, LOG_DEBUG, 1, 1, pid_tgid); + return; } diff --git a/tap/tlstapper/bpf/tcp_kprobes.c b/tap/tlstapper/bpf/tcp_kprobes.c index 6a83933e0..958fcba69 100644 --- a/tap/tlstapper/bpf/tcp_kprobes.c +++ b/tap/tlstapper/bpf/tcp_kprobes.c @@ -70,10 +70,16 @@ static __always_inline void tcp_kprobe(struct pt_regs *ctx, struct bpf_map_def * SEC("kprobe/tcp_sendmsg") void BPF_KPROBE(tcp_sendmsg) { + __u64 id = bpf_get_current_pid_tgid(); + log_error(ctx, LOG_DEBUG, 2, 1, id); + tcp_kprobe(ctx, &openssl_write_context, true); } SEC("kprobe/tcp_recvmsg") void BPF_KPROBE(tcp_recvmsg) { + __u64 id = bpf_get_current_pid_tgid(); + log_error(ctx, LOG_DEBUG, 2, 2, id); + tcp_kprobe(ctx, &openssl_read_context, false); }