Bug fixes, some work on exploit generator