[Xen-devel] [PATCH XEN] Fuzzing the hypervisor

2017-08-17 Thread Felix Schmoll
n/trace_pc.c b/xen/common/trace_pc.c new file mode 100644 index 00..722572c500 --- /dev/null +++ b/xen/common/trace_pc.c @@ -0,0 +1,96 @@ +/** + * trace_pc.c + * + * Implementation of the program counter tracing h

[Xen-devel] [PATCH XTF] Fuzzing the hypervisor

2017-08-17 Thread Felix Schmoll
Changes based on commit 8956f82ce1321b89deda6895d58e5788d2198477 --- include/xen/xen.h | 1 + include/xtf/hypercall.h| 8 +- tests/mk_hcall/.main.c.swo | Bin 0 -> 12288 bytes tests/mk_hcall/Makefile| 9 +++ tests/mk_hcall/main.c | 51 + tests/xtf-server/Ma

[Xen-devel] [PATCH AFL] Fuzzing the hypervisor

2017-08-17 Thread Felix Schmoll
Changes based on version 2.43b of AFL --- Makefile | 2 +- afl-fuzz.c | 233 ++--- hash_map.h | 82 ++ 3 files changed, 306 insertions(+), 11 deletions(-) create mode 100644 hash_map.h diff --git a/Makefile b/Makefi

[Xen-devel] [GSoC] Fuzzing the Hypervisor

2017-08-17 Thread Felix Schmoll
This email will be a technical description of what I, Felix Schmoll, as a Google Summer of Code student, did over summer. === Introduction / What is the project? === Fuzzing is a recent trend for systematic testing of interfaces by trying more or less random inputs and iterating over them. A

[Xen-devel] [PATCH v3] xen: Implement hypercall for tracing of program counters

2017-08-11 Thread Felix Schmoll
to be included for tracing might still be too extensive, resulting in indeterministic tracing output for some use cases. Signed-off-by: Felix Schmoll --- Changed since v2: * Fix bug that hypercall wouldn't return -EFAULT * Adjust error return codes of hypercall * Add description to Kc

Re: [Xen-devel] [PATCH v2] xen: Implement hypercall for tracing of program counters

2017-07-30 Thread Felix Schmoll
Thanks. Will do. ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel

[Xen-devel] [PATCH v2] xen: Implement hypercall for tracing of program counters

2017-07-26 Thread Felix Schmoll
to be included for tracing might still be too extensive, resulting in indeterministic tracing output for some use cases. Signed-off-by: Felix Schmoll --- Changed since v1: * Fixed bug that prevented xen from compiling when CONFIG_TRACE_PC was disabled * Adapted formatting to coding style

Re: [Xen-devel] [PATCH XTF v4] Implement pv_read_some

2017-07-25 Thread Felix Schmoll
2017-07-25 8:58 GMT+02:00 Felix Schmoll : > 2017-07-24 12:38 GMT+02:00 Andrew Cooper : >> >> >> Given the confusion this has caused on IRC, I'd prefer that the code was >> explicit. Is the following ok? >> >> cons = pv_ring->in_cons; >> prod

Re: [Xen-devel] [PATCH XTF v4] Implement pv_read_some

2017-07-25 Thread Felix Schmoll
2017-07-24 12:38 GMT+02:00 Andrew Cooper : > > > Given the confusion this has caused on IRC, I'd prefer that the code was > explicit. Is the following ok? > > cons = pv_ring->in_cons; > prod = LOAD_ACQUIRE(&pv_ring->in_prod); > > If so, I can fix up on commit. > > ~Andrew > > I'm not really convin

Re: [Xen-devel] Notes from Design Summit Hypervisor Fuzzing Session

2017-07-24 Thread Felix Schmoll
2017-07-21 15:15 GMT+02:00 Lars Kurth : > Hi all, > please find attached my notes. A lot of it went over my head, so I may > have gotten things wrong and some are missing > Feel free to modify, chip in, clarify, as needed > Lars > > Session URL: http://sched.co/AjHN > > OPTION 1: Userspace Approac

[Xen-devel] [PATCH XTF v4] Implement pv_read_some

2017-07-23 Thread Felix Schmoll
Implement reading from PV console. Making use of polling. Signed-off-by: Felix Schmoll --- Changed since v3: * Add to comment: read function blocks if no data available --- common/console.c | 26 ++ include/xtf/console.h | 2 ++ 2 files changed, 28 insertions

Re: [Xen-devel] [PATCH XTF v3] Implement pv_read_some

2017-07-21 Thread Felix Schmoll
> > > Much better. Just one final question. Do you intend this function to > block until data becomes available? (because that appears to be how it > behaves.) > > Yes. I could split it up into two functions if that bothers you. Or do you just want me to include that in the comment?

[Xen-devel] [PATCH XTF v3] Implement pv_read_some

2017-07-20 Thread Felix Schmoll
Implement reading from PV console. Making use of polling. Signed-off-by: Felix Schmoll --- Changed since v2: * Change function name from pv_read to pv_read_some * Add comment to function name * Remove unnecessary code --- common/console.c | 24 include/xtf

[Xen-devel] [PATCH v3] Add option to xenconsole to always forward console input

2017-07-20 Thread Felix Schmoll
Currently the default behaviour of the xenconsole client is to ignore any input to stdin, unless stdin and stdout are both ttys. The new option allows to manually overwrite this, causing the client to forward input regardless. Signed-off-by: Felix Schmoll --- Changed since v2: * change name

Re: [Xen-devel] [PATCH v2] xenconsole: Add pipe option

2017-07-19 Thread Felix Schmoll
2017-07-17 17:14 GMT+02:00 Ian Jackson : > Felix Schmoll writes ("[PATCH v2] xenconsole: Add pipe option"): > > Add pipe option to xenconsole that forwards console input. > > Thanks. IMO the commit message could do with better explanation. It > should mention t

Re: [Xen-devel] [PATCH XTF v2] Implement pv_read

2017-07-19 Thread Felix Schmoll
2017-07-18 17:04 GMT+02:00 Andrew Cooper : > On 18/07/17 15:53, Felix Schmoll wrote: > > Implement reading from PV console. Making use of polling. > > > > Signed-off-by: Felix Schmoll > > --- > > common/console.c | 22 ++ > > inc

[Xen-devel] [PATCH XTF v2] Implement pv_read

2017-07-18 Thread Felix Schmoll
Implement reading from PV console. Making use of polling. Signed-off-by: Felix Schmoll --- common/console.c | 22 ++ include/xtf/console.h | 2 ++ 2 files changed, 24 insertions(+) diff --git a/common/console.c b/common/console.c index 7cb2361..5895ccc 100644 --- a

[Xen-devel] [PATCH XTF] Implement pv_read

2017-07-17 Thread Felix Schmoll
Implement reading from PV console. Making use of polling. Signed-off-by: Felix Schmoll --- This is based on the console-branch of andyhhp, so that one has to be merged before applying this patch. --- common/console.c | 27 ++- include/xtf/console.h | 2 ++ 2 files

[Xen-devel] [PATCH v2] xenconsole: Add pipe option

2017-07-17 Thread Felix Schmoll
Add pipe option to xenconsole that forwards console input. Signed-off-by: Felix Schmoll --- Changed since v1: * introduce separate pipe flag * remove changes to libxl --- tools/console/client/main.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tools/console

[Xen-devel] [PATCH] xl console: Add interactive option

2017-07-02 Thread Felix Schmoll
Added an interactive option to the 'xl console'-command that forwards the input stream of the console to the underlying pty. Made corresponding changes to libxl, xl and xenconsole. Signed-off-by: Felix Schmoll --- tools/console/client/main.c | 4 tools/libxl/libxl.h

Re: [Xen-devel] [RFC v2] Proposal: Fuzzing the Hypervisor

2017-06-27 Thread Felix Schmoll
> > So what happens when the hypervisor does crash? Won't you lose the > test case that caused the crash? > > -George > That is discussed further below: "Also, the test cases need to be written to a file before actually being applied in order to survive a crash. As pointed out by Andy, the file

[Xen-devel] [RFC v2] Proposal: Fuzzing the Hypervisor

2017-06-23 Thread Felix Schmoll
Hi, here a new version of my proposal for fuzzing the hypervisor. The original can be found here: [1]. == 1. Motivation and Description == Fuzzing is a recent trend for systematic testing of interfaces by trying more or less random i

[Xen-devel] [PATCH RFC] Implement hypercall for tracing of program counters

2017-06-21 Thread Felix Schmoll
to be included for tracing might still be too extensive, resulting in indeterministic tracing output for some use cases. It is also not clear what other causes of indeterminism there might be. Signed-off-by: Felix Schmoll --- tools/libxc/include/xenctrl.h | 2 ++ tools/libxc/xc_private.c

[Xen-devel] [RFC] Proposal: Fuzzing the Hypervisor - Tracing

2017-05-23 Thread Felix Schmoll
Hi, I'm Felix Schmoll, one of the GSoC students this year. Go Xen! In order to begin I am herewith posting an implementation proposal for the first part of the project for comments. == 1. Motivation and Description == Fuzzing

Re: [Xen-devel] [PATCH] Enable compiling with gcc tracing

2017-03-31 Thread Felix Schmoll
2017-03-30 17:46 GMT+02:00 Wei Liu : > Cool. I think Xen should boot with this. > > You've successfully finished what I asked for. Now you can divert your > energy to polish your application. :-) > > On Thu, Mar 30, 2017 at 05:39:56PM +0200, Felix Schmoll wrote: > >

[Xen-devel] [PATCH] Enable compiling with gcc tracing

2017-03-30 Thread Felix Schmoll
= This is an experimental patch as in a final version you would not want all files to be compiled with this option by default. Signed-off-by: Felix Schmoll --- xen/Rules.mk| 9 - xen/include/xen/hypercall.h | 1 + xen/include/xen/my_tracer.h | 6 ++ xen/m

[Xen-devel] [GSoc] Adding Floating Point support to Mini-OS

2017-03-29 Thread Felix Schmoll
Hi, while looking at this some more I came to the following questions/assumptions, so I'd be grateful if you could shortly address them: -While implementing our own kernel last semester me and my team-mate came to believe that pusha/popa were faster that pushing/popping the individual registers,

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-29 Thread Felix Schmoll
2017-03-29 17:54 GMT+02:00 Wei Liu : > On Wed, Mar 29, 2017 at 04:24:15PM +0200, Felix Schmoll wrote: > > Hi, > > > > here the final patch for the domain_id: > > Please have a look at > > https://wiki.xenproject.org/wiki/Submitting_Xen_Project_Patches > >

[Xen-devel] [PATCH] Enable compiling with gcc tracing

2017-03-29 Thread Felix Schmoll
= This is an experimental patch as in a final version you would not want all files to be compiled with this option by default. Signed-off-by: Felix Schmoll --- xen/Rules.mk| 1 + xen/common/kernel.c | 2 ++ xen/include/xen/hypercall.h | 2 ++ 3 files changed, 5 insertion

[Xen-devel] [PATCH] Implement new hypercall to return domain id

2017-03-29 Thread Felix Schmoll
Minimal implementation of a new hypercall that returns the domain id of the invoking domain with adjustments in libxc. Signed-off-by: Felix Schmoll --- tools/libxc/include/xenctrl.h | 1 + tools/libxc/xc_private.c | 6 ++ xen/arch/arm/traps.c | 1 + xen/arch/x86/hvm

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-29 Thread Felix Schmoll
u : > On Wed, Mar 29, 2017 at 07:52:47AM +0200, Felix Schmoll wrote: > > > > > > Yes. That would be good. > > > > > > > I'm free every afternoon this week (German time, I suppose you're in > > Europe), so just let me know at least three hour

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-28 Thread Felix Schmoll
ced Xen developer to be > able to finish all three goals in three months. > > Felix, don't feel frustrated if you don't have everything figured out > because even I have not had everything figured out. ;-) > > > > > > On 27 Mar 2017, at 14:07, Felix Schmo

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-27 Thread Felix Schmoll
2017-03-26 15:04 GMT+02:00 Wei Liu : > On Sun, Mar 26, 2017 at 01:33:08PM +0200, Felix Schmoll wrote: > [...] > > > So just one last time to be clear about this: You can't just ignore > > interrupts and write all other edges to a shared memory region, like the > >

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-26 Thread Felix Schmoll
2017-03-24 13:56 GMT+01:00 Wei Liu : > On Fri, Mar 24, 2017 at 08:34:46AM +0100, Felix Schmoll wrote: > > Hi, > > > > this time for real: > > > > so I've been reading up on the task quite a bit now and I'd be thankful > if > > you could clarif

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-24 Thread Felix Schmoll
t: Building the user space application (user space is generally easier than kernel and you don't have to get any offsets right or alike) Questions: *What if the CPU doesn't have an FPU? Is that even possible for the given two architectures? Any comments would be appreciated. Felix 2

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-23 Thread Felix Schmoll
Sorry, the email went out too early accidentally, just ignore it for now, I still have to fill in the template. 2017-03-23 8:18 GMT+01:00 Felix Schmoll : > Hi, > > so I've been reading up on the task quite a bit now and I'd be thankful if > you could clarify what exactly y

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-23 Thread Felix Schmoll
do you expect to be easiest: 2017-03-22 12:21 GMT+01:00 Wei Liu : > On Wed, Mar 22, 2017 at 10:54:38AM +0100, Felix Schmoll wrote: > > > > Got it working! Thanks for all the help, will look into the "actual" task > > now :D > > That's good. > > IIRC

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-22 Thread Felix Schmoll
2017-03-22 9:52 GMT+01:00 Wei Liu : > On Wed, Mar 22, 2017 at 09:47:06AM +0100, Felix Schmoll wrote: > > 2017-03-21 17:14 GMT+01:00 Wei Liu : > > > > > On Tue, Mar 21, 2017 at 04:13:24PM +, Wei Liu wrote: > > > > On Mon, Mar 20, 2017 at 0

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-22 Thread Felix Schmoll
2017-03-21 17:14 GMT+01:00 Wei Liu : > On Tue, Mar 21, 2017 at 04:13:24PM +, Wei Liu wrote: > > On Mon, Mar 20, 2017 at 09:12:54AM +0100, Felix Schmoll wrote: > > [...] > > > From 7e50f50b2a1e95cbc813354d68c71315d4d1394b Mon Sep 17 00:00:00 2001 > > > From: F

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-20 Thread Felix Schmoll
2017-03-20 17:18 GMT+01:00 Wei Liu : > On Mon, Mar 20, 2017 at 09:12:54AM +0100, Felix Schmoll wrote: > > 2017-03-16 17:27 GMT+01:00 Wei Liu : > > > > #undef COMP > > diff --git a/xen/common/kernel.c b/xen/common/kernel.c > > index 4b87c60845..de07ee529b 100

Re: [Xen-devel] [GSoC] GSoC Introduction : Fuzzing Xen hypercall interface

2017-03-16 Thread Felix Schmoll
2017-03-13 12:14 GMT+01:00 Wei Liu : > Hi Felix > > Thanks for your interest in this project. > > On Sun, Mar 12, 2017 at 09:48:11PM +0100, Felix Ekkehard Schmoll wrote: > > Hi, > > > > I’m interested in the “Fuzzing Xen hypercall interface” project so I > > just wanted to introduce myself: > > >