View on GitHub


Is Not Just A Ping Utility.

Download OWASP NINJA-PingU v1.0.1 research Plugins DEV FAQ main

Plugin Development

Bulding NINJA PingU plugins is very easy. The three following C functions have to be implemented to accomplish this.

· Plugin Initializer

To carry out plugin initialization actions, the following function has to be declared:
void onInitPlugin();

· Plugin Finalizer

To carry out plugin end actions, the following function has to be declared:
void onStopPlugin();

· Scanner Input Provide

The messages that the scanner will send after a successful connection are provided by the following function.
void getServiceInput(int port, char *msg);

· Scanner Output Analysis

The responses of the target will be given to the following function.
void provideOutput(char *host, int port, char *msg);

Plugin Integration

Integrating a NINJA PingU is very easy, you can add to the Makefile the following file for automatic compilation.

gcc -c src/plugin/PLUGINNAME/scanner.c -o src/plugin/PLUGINNAME/scanner.o -pedantic -g -Wall -std=c99 -fpic -I.
gcc -o src/plugin/PLUGINNAME/ src/plugin/PLUGINNAME/scanner.o -shared

Using your plugin in NINJA PingU can be achieved by using the -m flag with your plugin name. For instance.

$ ./bin/npingu -m PLUGINNAME

More Documentation

More information about plugin development and code samples can be found in the NINJA PingU codebase.