aboutsummaryrefslogtreecommitdiffstats
path: root/bruiser
diff options
context:
space:
mode:
authorbloodstalker <thabogre@gmail.com>2018-04-24 13:23:39 +0000
committerbloodstalker <thabogre@gmail.com>2018-04-24 13:23:39 +0000
commit1debe08d0a42a8414af2e9549db03f50d9b935e1 (patch)
treed43a85b2fca8f7a37404cf16a4f7ee257efa534c /bruiser
parentupdated the readme, added a wiki entry, fixed the default.lua script which i ... (diff)
downloadmutator-1debe08d0a42a8414af2e9549db03f50d9b935e1.tar.gz
mutator-1debe08d0a42a8414af2e9549db03f50d9b935e1.zip
finally updated the readmes. they make more sense now.
Diffstat (limited to 'bruiser')
-rw-r--r--bruiser/README.md23
1 files changed, 10 insertions, 13 deletions
diff --git a/bruiser/README.md b/bruiser/README.md
index 2e7889c..b1bdc0c 100644
--- a/bruiser/README.md
+++ b/bruiser/README.md
@@ -1,24 +1,24 @@
## bruiser
### What is it?
-Bruiser is implemented as an interactive commandline interface. It features an embedded lua interpreter plus the history and auto-completion and suggestion features we have all come to expect from shell-like tools.<br/>
-Regarding the actual functionality, it will feature non-blind selective mutations. You can ask it to list information regrading the source codes it is run on. The eventuality of this idea is to help with maintaining code or in giving the viewer an overview of the code. The final feature is the name-sake. It looks at the code and decides how to break it. For more explanation please read on.<br/>
+Bruiser is implemented as an interactive commandline interface. It features an embedded Lua 5.3.4 interpreter plus the history and auto-completion and suggestion features we have all come to expect from shell-like tools.<br/>
+Regarding the actual functionality:<br/>
+Xobj: pull in funtions from ELF objects, call them and get the result back.<br/>
+ASMrewriter: Allows manipulation of machine code.<br/>
+It will feature non-blind selective mutations. You can ask it to list information regrading the source codes it is run on. The eventuality of this idea is to help with maintaining code or in giving the viewer an overview of the code. The final feature is the name-sake. It looks at the code and decides how to break it. For more explanation please read on.<br/>
+
+For working demos you can skip to the end of the README.<br/>
### How does it work?
To put it simply, bruiser is an interactive lua interpreter that uses linenoise for shell-like features(history, tab-completion, auto-suggestion). You get the full power of lua plus the bruiser functions whcih are implemented as lua scripts that call back to the cpp code to get things done.<br/>
To put this into perspective, think you run `list vars` in bruiser. It gets you the list of vars but that's it. You can't save them to a file or do anything else with them. With the old way of doing things I had to add a command that did that and then you could do it but what if you wanted to do something else? What then? Well you get the idea. That would also mean that bruiser's language would be made up gradually which would result in something ugly and warrant a lot of rewrites.<br/>
With the new way of doing things, the user is only limited by their imagination and lua, not me, and there is no learning curve for learning a garbage language that I would have to come up with.<br/>
Also, there is no reason to implement any extra features to be able to automate your use of bruiser. Just run a lua script and tell bruiser to run that.<br/>
-
-### DSL?
-Bruiser has an embedded lua interpreter so nobody would have to deal with a new DSL. It's good old lua.<br/>
+bruiser has a built-in pipe to Python so adding plugin python scripts are simple.(currently the pipe works only one-way)<br/>
### Lua vs Luajit
-In the current implementation, bruiser will only support lua and not luajit. luajit is way faster than lua which will play an important role in bruiser's overall performance but luajit is generally less stable than lua and usually behind in terms of what new features of lua the language it supports.<br/>
-The plan is to add both and for the user to be able to pick which one to use when running bruiser.<br/>
-
-### Prototyping
-I embedded the ability to run python scripts from C++ in bruiser. The feature was added to facilitate fast prototyping since I'd rather first do the experimental features in python and run them through bruiser and then re-implement them in C++ if speed is an actual concern.<br/>
+For the first incarnation, bruiser will only support lua and not luajit. luajit is way faster than lua which will play an important role in bruiser's overall performance but luajit is generally less stable than lua and usually behind in terms of what new features of lua the language it supports.<br/>
+The plan is to add both and for the user to be able to pick which one to use when running bruiser. Unfortunately there is no estimated date.<br/>
### Warning
The current implementation loads all lua libraries which also includes it's `os` library. To give you an idea, `os.execute()` is very similar to `system()` in C. This decision has been made to speed up testing and the dev process.<br/>
@@ -31,9 +31,6 @@ The second point concerns the mutation operators. The classical mutation operato
Imagine we have a classical mutation operator that mutates all `+` operators to `-`. This mutation operator is blind. To put it in simple terms, it takes in text and spits out text with no regards to syntax or semantics.<br/>
`bruiser` will not be using classical blind mutation operators.<br/>
-### How?
-I'm going to write about it as soon as I get my thoughts organized. In the meantime you can look at the source code for some hints.<br/>
-
### Useful Lua Scripts
The dir named `lua-scripts` houses demos, examples and useful lua scripts for bruiser.<br/>
If you happen to write a Lua script for bruiser that you think other people will find useful, then please add it to `lua-scripts` on your fork and make a PR.<br/>