This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
time="2024-03-19T13:42:16-05:00" level=debug msg="running gadget: verifier error: load program: permission denied: | |
; int ig_trace_dns(struct __sk_buff *skb) | |
0: (bf) r6 = r1 | |
1: (bf) r3 = r10 | |
; | |
2: (07) r3 += -28 | |
; err = bpf_skb_load_bytes(skb, offsetof(struct ethhdr, h_proto), | |
3: (b7) r2 = 12 | |
4: (b7) r4 = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) | |
/* Copyright (c) 2020 Facebook */ | |
#include <stdio.h> | |
#include <unistd.h> | |
#include <sys/resource.h> | |
#include "bpf/libbpf.h" | |
#include "bpf/btf.h" | |
#include "assert.h" | |
static int libbpf_print_fn(enum libbpf_print_level level, const char *format, va_list args) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import ( | |
"fmt" | |
"github.com/cilium/ebpf/rlimit" | |
"github.com/kinvolk/inspektor-gadget/pkg/gadgets/execsnoop/tracer" | |
execsnooptracer "github.com/kinvolk/inspektor-gadget/pkg/gadgets/execsnoop/tracer/core" | |
"github.com/kinvolk/inspektor-gadget/pkg/gadgets/execsnoop/types" | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/btf.c b/src/btf.c | |
index 9aa19c8..065ddc8 100644 | |
--- a/src/btf.c | |
+++ b/src/btf.c | |
@@ -4627,6 +4627,8 @@ struct btf *btf__load_vmlinux_btf(void) | |
const char *path_fmt; | |
bool raw_btf; | |
} locations[] = { | |
+ /* try custom path first */ | |
+ { "/tmp/vmlinux.btf", true /* raw BTF */ }, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
set -e | |
set -x | |
source /etc/os-release | |
KERNEL=$(uname -r) | |
ARCH=$(uname -m) | |
URL="https://github.com/aquasecurity/btfhub/raw/main/$ID/$VERSION_ID/$ARCH/$KERNEL.btf.tar.xz" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/bin/bash | |
set -e | |
######## agents ######## | |
# spire-agent | |
kubectl exec -n spire spire-server-0 -- \ | |
/opt/spire/bin/spire-server entry create \ | |
-node \ | |
-spiffeID spiffe://example.org/ns/spire/sa/spire-agent \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: "cilium.io/v2" | |
kind: CiliumNetworkPolicy | |
metadata: | |
name: "deny-all-egress" | |
spec: | |
endpointSelector: | |
{} | |
egress: | |
- {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"ociVersion": "1.0.2-dev", | |
"annotations": { | |
"io.mauricio.name": "mauriciocontainer" | |
}, | |
"process": { | |
"terminal": true, | |
"user": { | |
"uid": 0, | |
"gid": 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pod without userNamespaceMode, defaults to Host | |
apiVersion: v1 | |
kind: Pod | |
metadata: | |
name: defaut-mode | |
spec: | |
containers: | |
- name: container1 | |
image: busybox | |
command: ["sh"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
__dev_queue_xmit | |
__dev_queue_xmit | |
ip_finish_output2 | |
ip_do_fragment | |
ip_output | |
ip_send_skb | |
udp_send_skb.isra.51 | |
udp_sendmsg | |
sock_sendmsg | |
sock_write_iter |
NewerOlder