Kali Linux ToolsSecurity

FunkLoad

1

FunkLoad Package Description

FunkLoad is a functional and load web tester, written in Python, whose main use cases are:

  • Functional testing of web projects, and thus regression testing as well.
  • Performance testing: by loading the web application and monitoring your servers it helps you to pinpoint bottlenecks, giving a detailed report of performance measurement.
  • Load testing tool to expose bugs that do not surface in cursory testing, like volume testing or longevity testing.
  • Stress testing tool to overwhelm the web application resources and test the application recoverability.
  • Writing web agents by scripting any web repetitive task.

Source: http://funkload.nuxeo.org/intro.html
funkload Homepage | Kali funkload Repo

  • Author: Benoit Delbosc, Nuxeo SAS
  • License: GPLv2

Tools included in the funkload package

fl-record – Launch a TCPWatch proxy and record activities
root@kali:~# fl-record -h
Usage
=====
fl-record [options] [test_name]

fl-record launch a TCPWatch proxy and record activities, then output
a FunkLoad script or generates a FunkLoad unit test if test_name is specified.

The default proxy port is 8090.

Note that tcpwatch.py executable must be accessible from your env.

See http://funkload.nuxeo.org/ for more information.

Examples
========
fl-record foo_bar
Run a proxy and create a FunkLoad test case,
generates test_FooBar.py and FooBar.conf file.
To test it:  fl-run-test -dV test_FooBar.py
fl-record -p 9090
Run a proxy on port 9090, output script to stdout.
fl-record -i /tmp/tcpwatch
Convert a tcpwatch capture into a script.

Options
=======
–version               show program’s version number and exit
–help, -h              show this help message and exit
–verbose, -v           Verbose output
–port=PORT, -p PORT    The proxy port.
–tcp-watch-input=TCPWATCH_PATH, -i TCPWATCH_PATH
Path to an existing tcpwatch capture.
–loop=LOOP, -l LOOP    Loop mode.

fl-credential-ctl – Execute action on the XML/RPC server

root@kali:~# fl-credential-ctl -h
Usage
=====
fl-credential-ctl config_file action

action can be: start|startd|stop|restart|status|test

Execute action on the XML/RPC server.

Options
=======
–version    show program’s version number and exit
–help, -h   show this help message and exit
–quiet, -q  Verbose output

fl-run-test – Launch a FunkLoad unit test

root@kali:~# fl-run-test -h
Usage
=====
fl-run-test [options] file [class.method|class|suite] […]

fl-run-test launch a FunkLoad unit test.

A FunkLoad unittest use a configuration file named [class].conf, this
configuration is overriden by the command line options.

See http://funkload.nuxeo.org/ for more information.

Examples
========
fl-run-test myFile.py
Run all tests (including doctest with python2.4).
fl-run-test myFile.py test_suite
Run suite named test_suite.
fl-run-test myFile.py MyTestCase.testSomething
Run a single test MyTestCase.testSomething.
fl-run-test myFile.py MyTestCase
Run all ‘test*’ test methods and doctest in MyTestCase.
fl-run-test myFile.py MyTestCase -u http://localhost
Same against localhost.
fl-run-test myDocTest.txt
Run doctest from plain text file (requires python2.4).
fl-run-test myDocTest.txt -d
Run doctest with debug output (requires python2.4).
fl-run-test myfile.py -V
Run default set of tests and view in real time each
page fetch with firefox.
fl-run-test myfile.py MyTestCase.testSomething -l 3 -n 100
Run MyTestCase.testSomething, reload one hundred
time the page 3 without concurrency and as fast as
possible. Output response time stats. You can loop
on many pages using slice -l 2:4.
fl-run-test myFile.py -e [Ss]ome
Run all tests that match the regex [Ss]ome.
fl-run-test myFile.py -e ‘!xmlrpc$’
Run all tests that does not ends with xmlrpc.
fl-run-test myFile.py –list
List all the test names.
fl-run-test -h
More options.

Options
=======
–version               show program’s version number and exit
–help, -h              show this help message and exit
–quiet, -q             Minimal output.
–verbose, -v           Verbose output.
–debug, -d             FunkLoad and doctest debug output.
–debug-level=DEBUG_LEVEL
Debug level 3 is more verbose.
–url=MAIN_URL, -u MAIN_URL
Base URL to bench without ending ‘/’.
–sleep-time-min=FTEST_SLEEP_TIME_MIN, -m FTEST_SLEEP_TIME_MIN
Minumum sleep time between request.
–sleep-time-max=FTEST_SLEEP_TIME_MAX, -M FTEST_SLEEP_TIME_MAX
Maximum sleep time between request.
–dump-directory=DUMP_DIR
Directory to dump html pages.
–firefox-view, -V      Real time view using firefox, you must have a running
instance of firefox in the same host.
–no-color              Monochrome output.
–loop-on-pages=LOOP_STEPS, -l LOOP_STEPS
Loop as fast as possible without concurrency on pages,
expect a page number or a slice like 3:5. Output some
statistics.
–loop-number=LOOP_NUMBER, -n LOOP_NUMBER
Number of loop.
–accept-invalid-links  Do not fail if css/image links are not reachable.
–simple-fetch          Don’t load additional links like css or images when
fetching an html page.
–stop-on-fail          Stop tests on first failure or error.
–regex=REGEX, -e REGEX
The test names must match the regex.
–list                  Just list the test names.
–pause                 Pause between request, press ENTER to continue.

fl-build-report – Analyze a FunkLoad bench xml result file and output a report

root@kali:~# fl-build-report -h
Usage
=====
fl-build-report [options] xmlfile [xmlfile…]

or

fl-build-report –diff REPORT_PATH1 REPORT_PATH2

fl-build-report analyze a FunkLoad bench xml result file and output a report.
If there are more than one file the xml results are merged.

See http://funkload.nuxeo.org/ for more information.

Examples
========
fl-build-report funkload.xml
ReST rendering into stdout.
fl-build-report –html -o /tmp funkload.xml
Build an HTML report in /tmp
fl-build-report –html node1.xml node2.xml node3.xml
Build an HTML report merging test result from 3 nodes.
fl-build-report –diff /tmp/test_reader-20080101 /tmp/test_reader-20080102
Build a differential report to compare 2 bench reports,
requires gnuplot.
fl-build-report -h
More options.

Options
=======
–version               show program’s version number and exit
–help, -h              show this help message and exit
–html, -H              Produce an html report.
–with-percentiles, -P  Include percentiles in tables, use 10%, 50% and 90%
for charts, default option.
–no-percentiles        No percentiles in tables display min, avg and max in
charts (gdchart only).
–diff, -d              Create differential report.
–output-directory=OUTPUT_DIR, -o OUTPUT_DIR
Parent directory to store reports, the directoryname
of the report will be generated automatically.
–report-directory=REPORT_DIR, -r REPORT_DIR
Directory name to store the report.
–apdex-T=APDEX_T, -T APDEX_T
Apdex T constant in second, default is set to 1.5s.
Visit http://www.apdex.org/ for more information.

fl-run-bench – Launch a FunkLoad unit test as load test

root@kali:~# fl-run-bench -h
Usage
=====
fl-run-bench [options] file class.method

fl-run-bench launch a FunkLoad unit test as load test.

A FunkLoad unittest use a configuration file named [class].conf, this
configuration is overriden by the command line options.

See http://funkload.nuxeo.org/ for more information.

Examples
========
fl-run-bench myFile.py MyTestCase.testSomething
Bench MyTestCase.testSomething using MyTestCase.conf.
fl-run-bench -u http://localhost:8080 -c 10:20 -D 30 myFile.py \
MyTestCase.testSomething
Bench MyTestCase.testSomething on localhost:8080
with 2 cycles of 10 and 20 users during 30s.
fl-run-bench -h
More options.

Options
=======
–version               show program’s version number and exit
–help, -h              show this help message and exit
–url=MAIN_URL, -u MAIN_URL
Base URL to bench.
–cycles=BENCH_CYCLES, -c BENCH_CYCLES
Cycles to bench, this is a list of number of virtual
concurrent users, to run a bench with 3 cycles with 5,
10 and 20 users use: -c 2:10:20
–duration=BENCH_DURATION, -D BENCH_DURATION
Duration of a cycle in seconds.
–sleep-time-min=BENCH_SLEEP_TIME_MIN, -m BENCH_SLEEP_TIME_MIN
Minimum sleep time between requests.
–sleep-time-max=BENCH_SLEEP_TIME_MAX, -M BENCH_SLEEP_TIME_MAX
Maximum sleep time between requests.
–test-sleep-time=BENCH_SLEEP_TIME, -t BENCH_SLEEP_TIME
Sleep time between tests.
–startup-delay=BENCH_STARTUP_DELAY, -s BENCH_STARTUP_DELAY
Startup delay between thread.
–as-fast-as-possible, -f
Remove sleep times between requests and between tests,
shortcut for -m0 -M0 -t0
–no-color              Monochrome output.
–accept-invalid-links  Do not fail if css/image links are not reachable.
–simple-fetch          Don’t load additional links like css or images when
fetching an html page.
–label=LABEL, -l LABEL
Add a label to this bench run for easier
identification (it will be appended to the directory
name for reports generated from it).
–enable-debug-server   Instantiates a debug HTTP server which exposes an
interface using which parameters can be modified at
run-time. Currently supported parameters:
/cvu?inc=<integer> to increase the number of CVUs,
/cvu?dec=<integer> to decrease the number of CVUs,
/getcvu returns number of CVUs
–debug-server-port=DEBUGPORT
Port at which debug server should run during the test

fl-monitor-ctl – Execute action on the XML/RPC server

root@kali:~# fl-monitor-ctl -h
Usage
=====
fl-monitor-ctl config_file action

action can be: start|startd|stop|restart|status|test

Execute action on the XML/RPC server.

Options
=======
–version    show program’s version number and exit
–help, -h   show this help message and exit
–quiet, -q  Verbose output

FunkLoad Usage Example

root@kali:~# coming soon

Metaphor – Stagefright with ASLR bypass

Next article

You may also like

1 Comment

  1. Hello there I am so grateful I found your blog, I have bookmarked it.

Leave a reply

E-posta hesabınız yayımlanmayacak. Gerekli alanlar * ile işaretlenmişlerdir