lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date:	Tue, 19 Jul 2016 00:57:46 -0700
From:	Sargun Dhillon <sargun@...gun.me>
To:	linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Cc:	alexei.starovoitov@...il.com, daniel@...earbox.net
Subject: [PATCH net-next v2 0/2] bpf: add copy_to_user helper & example


This patch series contains two patches that add support for a copy_to_user
helper to BPF programs. This allows them to manipulate user memory during
the course of tracing. The second patch in the series has an example that
uses it, in one the intended ways to divert execution.

Thanks to Alexei Starovoitov for review, I've made changes based on his
recommendations.
---
v1->v2: restrict writing to user space, as opposed to globally

Sargun Dhillon (2):
  Add bpf_copy_to_user BPF helper to be called in tracers (kprobes)
  Add example of using bpf_copy_to_user in bpf kprobes

 include/uapi/linux/bpf.h   | 11 +++++++
 kernel/trace/bpf_trace.c   | 31 +++++++++++++++++++
 samples/bpf/Makefile       |  4 +++
 samples/bpf/bpf_helpers.h  |  2 ++
 samples/bpf/tracex7_kern.c | 53 ++++++++++++++++++++++++++++++++
 samples/bpf/tracex7_user.c | 76 ++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 177 insertions(+)
 create mode 100644 samples/bpf/tracex7_kern.c
 create mode 100644 samples/bpf/tracex7_user.c

-- 
2.7.4

Powered by blists - more mailing lists