diff --git a/README.md b/README.md index 89ac6a1..123bbf4 100644 --- a/README.md +++ b/README.md @@ -1,17 +1,53 @@ -# AScrossfire +# crossfire -hello world +distributed brute force infrastructure -## components +takes the difficulty out of creating custom brute force jobs -- base: #lang for configuration/definitions -- server: distribute jobs to workers - - base definitions of input classes and how to divide them - - dynamic slicing and scheduling based on agents' reported work rate - - fairly randomized distribution -- agent: accepts and runs jobs - - optional: containerization - - optional: appimage-like behavior - - required: run binary with infrastructure to get assigned brute force range, log and report - progress. via library interface as well as stdio interface -- client: submit jobs and view progress via command line (and maybe racket/gui and framework???) +## status + +### base +- 🚧 input space manipulation functions + - ✅ data types: interval, iset (interval set), pattern (vector of interval set) + - ✅ pos->iset-pos, iset-count, pattern-count + - 🚧 partitioning functions +- 🚧 #lang for configuration/definitions + - (input) mode + - stdio: user program gets input by stdio, integers separated by space, one per line + - callback: input generator compiled into user program, user main calls `crossfire_main` + with callback function that returns true or false + - other modes?? + - SMP: performed by crossfire or performed by the user code + - "performed by user code" can also mean GPU, for example +- 🚧 codegen for input generator (in C) + - 🚧 stdio mode + - 🚧 callback mode + - success reporting mechanism + - low priority: configurable "character" type -- currently a "character" is a uint64\_t + +### server: distribute jobs to workers +- base definitions of input classes and how to divide them +- dynamic slicing and scheduling based on agents' reported work rate +- low priority: randomized input space distribution +- ability to compile input generator with different parameters and distribute to agents + - low priority: support for multiple architectures +- agent authentication +- client authentication + +# agent: accept and run jobs +- securely connect to server +- retrieve assigned tasks +- report number of cores available (configurable limit) +- report work rate +- report successes +- low priority: defer to external brute force program (eg, hashcat on GPU) + +# client: submit jobs and view progress +- command line interface + - securely connect to server + - `crossfire new`: create new crossfire project + - `crossfire test`: test project locally, replicates configuration of server with single local + agent to debug issues + - `crossfire submit`: submit task to server + - `crossfire status`: check status of task (or network as a whole) +- low priority: gui interface diff --git a/crossfire/codegen.template b/crossfire/codegen.template index 27accb5..dff8fe0 100644 --- a/crossfire/codegen.template +++ b/crossfire/codegen.template @@ -34,7 +34,7 @@ typedef struct { @(for/list ([i (in-naturals)] [iset (in-vector pattern)]) (output-iset i iset)) -int inputgen_main(callback cb) { +int crossfire_main(callback cb) { char buf [ @(* 20 (vector-length pattern)) ]; @(for/list ([num (in-naturals)] [iset-pos (in-vector pp-start)]) @list{size_t @(format "i~a" num) = @(car iset-pos) ; @@ -79,7 +79,7 @@ l_inner: @list{ssize_t res = snprintf(buf, sizeof(buf), @(format "\"~a\\n\"" fmt), @vs ); fwrite(buf, res, 1, stdout);}] ['callback - @list{ if (cb( @vs )) { report_success( @vs ); return 0; } }]) + @list{ if (cb( @vs )) { cf_report_success( @vs ); return 0; } }]) @(for/list ([iset (in-vector pattern)]) "}}") l_end: @@ -89,11 +89,11 @@ l_end: @(if (equal? mode 'stdout) @list{ int main() { - return inputgen_main(NULL); + return crossfire_main(NULL); } } @list{ -void report_success( @arg-vs ) { +void cf_report_success( @arg-vs ) { // TODO } })