Implement bashreadline with libbpf.
authorKui-Feng Lee <kuifeng@fb.com>
Wed, 15 Dec 2021 23:57:17 +0000 (15:57 -0800)
committeryonghong-song <ys114321@gmail.com>
Sat, 18 Dec 2021 18:13:07 +0000 (10:13 -0800)
commit23bbba177adde437e0b0e2a7b0f29f58b4c02a43
treebb814e54b2a1910e14471f9adfc71c676ed61c19
parent00bb8e1f4944a6f8546c06dcc4c9184f08ef8bc8
Implement bashreadline with libbpf.

Bashreadline will print user inputs, returning from readline, of every
instance of bash shell.  Readline is in bash itself, linked
statically, for some devices, while others may link to libreadline.so.
This implementation finds the symbol in bash if possible. Or, it tries
to find libreadline.so using ldd if the symbol is not in bash.

Signed-off-by: Kui-Feng Lee <kuifeng@fb.com>
libbpf-tools/.gitignore
libbpf-tools/Makefile
libbpf-tools/bashreadline.bpf.c [new file with mode: 0644]
libbpf-tools/bashreadline.c [new file with mode: 0644]
libbpf-tools/bashreadline.h [new file with mode: 0644]