Skip to content

Releases: spearmin10/iptgen

0.15.0

Choose a tag to compare

@spearmin10 spearmin10 released this 16 Apr 11:23
bff923d

iptgen

iptgen is a tool for generating network packets from scripts. You can either send them over your network or save them to a PCAP file.

Installing

Install using the standard procedure:

Windows

  1. Install the npcap driver. You can download it from https://nmap.org/npcap/.

  2. Extract the contents of iptgen.win32.zip.

Linux

  1. Choose the archive that matches your platform: iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz.

  2. Extract the archive.

Binaries

Here are binaries:

Usage

To send packets over your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

To create a PCAP file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all available options, run:

iptgen.bin --help

Syntex for scripts

A script is a text file consisting of a list of Process or String (used as comments), concatenated together.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in an infinite loop.

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

The `for-loop` statement specifies the iteration process. The session is closed either when looping back or when breaking the loop. A new port is assigned to a new session each time the session is closed.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in an infinite loop. The session is closed each time the loop restarts. A new port is assigned to a new session whenever the previous session is closed.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

The `for-loop` statement is used to specify iteration. A new process, separate from the session, is created on each iteration. Each process can use different client and server IP addresses.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. This statement does not affect control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process, separate from the session, is created. New client and server IP addresses can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["t...
Read more

0.14.0

Choose a tag to compare

@spearmin10 spearmin10 released this 07 Mar 17:37
4ee9f02

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

iptgen.win32.zip

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

...

Read more

0.13.0

Choose a tag to compare

@spearmin10 spearmin10 released this 11 Mar 12:27
2fab2ce

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port ...
Read more

0.12.0

Choose a tag to compare

@spearmin10 spearmin10 released this 09 Feb 06:17
3603500

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port ...
Read more

0.11.0

Choose a tag to compare

@spearmin10 spearmin10 released this 26 Sep 09:43
3603500

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port ...
Read more

0.10.0

Choose a tag to compare

@spearmin10 spearmin10 released this 19 Sep 05:33
1ac20dd

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port ...
Read more

0.9.0

Choose a tag to compare

@spearmin10 spearmin10 released this 15 Jan 09:16
1ac20dd

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port is ...
Read more

0.8.0

Choose a tag to compare

@spearmin10 spearmin10 released this 08 Jan 07:14
7921e4a

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port is ...
Read more

0.7.0

Choose a tag to compare

@spearmin10 spearmin10 released this 30 Dec 12:41
7921e4a

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port is ...
Read more

0.6.0

Choose a tag to compare

@spearmin10 spearmin10 released this 24 Dec 05:51
77ee98b

iptgen

iptgen is a tool to generate network packets from scripts to play them onto your netowrk or create a pcap file.

Installing

Install in the standard way:

Windows

  1. Install npcap driver. Visit https://nmap.org/npcap/ to download and install it.

  2. Extract iptgen.win32.zip.

Linux

  1. Choose the archive file appropriate for your platform, iptgen.linux-x86_64.tar.gz or iptgen.linux-i686.tar.gz, and extract it.

Binaries

Here are binaries:

Usage

For playing packets onto your network.

iptgen.bin --in.file <script-file> --out.eth <ifname>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.eth eth0

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.eth Ethernet0

For creating a pcap file.

iptgen.bin --in.file <script-file> --out.file <filename>

e.g.

** Linux
sudo iptgen.bin --in.file ./scripts/http-upload.json --out.file http.pcap

** Windows
iptgen.exe --in.file ./scripts/http-upload.json --out.file http.pcap

To see all options that are available, run:

iptgen.bin --help

Syntex for scripts

A script is text that a list of Process or String (comment) are concatenated.

Process

Data Type: Object[String, Any] or Array[Object[String, Any]]

Details
Key Type Description
client String Client IP Address (e.g. 192.168.1.2), Port numer is optional.
server String Server IP Address (e.g. 1.2.3.4:80), Port numer is optional.
eth.src (Optional) String Client MAC Address (e.g. 11:22:33:44:55:66)
eth.dst (Optional) String Server MAC Address (e.g. 11:22:33:44:55:66)
sequence Sequence Sequence of sessions

Sequence

Data Type: Array[Operation]

Operation

Standard Syntex

Data Type: Object[String, Any]

Compact Syntex

Data Type: Operation or Array[Operation]

Operation: none

No operation.

Standard Syntex

Key Type Value
op String none
{
  "op": "none"
}

Compact Syntex

Index Type Value / Description
[0] String none
["none"]

Operation: for

`for-loop` statement for specifying iteration.

Standard Syntex

Key Type Value
op String for
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Sequence l.sequence
["for", [0, 10], "i",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: loop

Run operations in the infinite loop

Standard Syntex

Key Type Value
op String loop
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop",
  "l.sequence": [
    ["dns.q.a", "www.domain.com", "3.3.3.3"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop
[1] Sequence l.sequence
["loop",
  [
    ["dns.q.a", "www.domain.com", "2.2.2.2"]
  ]
]

Operation: for.session

`for-loop` statement for specifying iteration. The session is closed whenever looping back or when breaking the loop. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String for.session
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased
l.name String Name of the counter
l.sequence Sequence Sequence of operations in the loop
{
  "op": "for.session",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String for.session
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step
[2] String l.name
[3] Sequence l.sequence
["for.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: loop.session

Run operations in the infinite loop. The session is closed whenever looping back. A new port is assigned for a new session when closing the session.

Standard Syntex

Key Type Value
op String loop.session
l.sequence Sequence Sequence of operations in the loop
{
  "op": "loop.session",
  "l.sequence": [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
}

Compact Syntex

Index Type Value / Description
[0] String loop.session
[1] Sequence l.sequence
["loop.session", [0, 10], "i",
  [
    ["tcp.send", "text", "Hello"],
    ["tcp.recv", "text", "Hello"]
  ]
]

Operation: for.process

`for-loop` statement for specifying iteration. A new process separated from the session is created on each iteration. New client/server IPs can be used in the processes.

Standard Syntex

Key Type Value
op String for.process
l.begin Number Start value of the counter
l.end Number End value of the counter
l.step Number Specifies the amount the counter is increased (default:1)
l.name String Name of the counter
l.sequence Process Sequence of processes in the loop
{
  "op": "for.process",
  "l.begin": 0,
  "l.end": 10,
  "l.name": "i",
  "l.sequence": {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
}

Compact Syntex

Index Type Value / Description
[0] String for.process
[1] Array[l.begin, l.end, l.strp] [0]: l.begin, [1]: l.end, [2]: l.step (default:1)
[2] String l.name
[3] Process l.sequence
["for.process", [0, 10], "i",
  {
    "client": "1.1.1.1", 
    "server": "2.2.2.2:80",
    "sequence": [
      ["tcp.send", "text", "Hello"],
      ["tcp.recv", "text", "Hello"]
    ]
  }
]

Operation: comment

Comment statement. The statement doesn't affect the control flow.

Standard Syntex

Key Type Value
op String comment or `` (empty)
Any Comment
{
  "op": "comment",
  "": "This is a comment."
}
{
  "op": "",
  "": "This is a comment."
}

Compact Syntex

Index Type Value / Description
[0] String comment or `` (empty)
[1-] Any Comment
["comment", "This is a comment."]
["", "This is a comment."]

Operation: process

A new process separated from the session is created. New client/server IPs can be used in the process.

Standard Syntex

Key Type Value
op String process
sequence Process Sequence of processes
{
  "op": "process",
  "sequence": [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
}

Compact Syntex

Index Type Value / Description
[0] String process
[1] Process sequence
["process",
  [
    {
      "client": "1.1.1.1",
      "server": "2.2.2.2:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    },
    {
      "client": "3.3.3.3",
      "server": "4.4.4.4:9999",
      "sequence": [
        ["tcp.send", "text", "Hello"]
      ]
    }
  ]
]

Operation: session.new

The session is closed and a new port is ...
Read more