GithubHelp home page GithubHelp logo

resurrecting-open-source-projects / packit Goto Github PK

View Code? Open in Web Editor NEW
45.0 15.0 16.0 540 KB

network packet generator and capture tool

License: GNU General Public License v2.0

Shell 1.19% C 92.88% Makefile 1.91% M4 4.03%
network networking network-monitoring network-security tcp tcp-ip udp icmp security-tools libpcap

packit's Introduction

PACKIT

Network injection and capture tool



1. HELP THIS PROJECT
2. WHAT IS PACKIT?
3. BUILDING FROM SOURCE


  1. HELP THIS PROJECT

Packit needs your help. If you are a programmer and if you wants to help a nice project, this is your opportunity.

My name is Eriberto and I am not a C developer. I imported Packit from its old repository[1] to GitHub (the original homepage and developer are inactive). After this, I applied all patches found in Debian project and other places for this program. All my work was registered in ChangeLog file (version 1.1 and later releases). I also maintain Packit packaged in Debian[2].

If you are interested to help Packit, read the CONTRIBUTING.md file.

[1] http://packetfactory.openwall.net/projects/packit
[2] https://packages.qa.debian.org/p/packit.html


  1. WHAT IS PACKIT?

Packit (PACket toolKIT) is a network auditing tool. It uses libpcap and can make real packages (frames) that are able to travel in a network. Packit also allows one to add personalized payloads. Other good feature is the possibility to read dump files created by tcpdump.

Packit has an ability to customize, inject, monitor and manipulate IP traffic. By allowing you to define (spoof) nearly all TCP, UDP, ICMP, IP, ARP, RARP, and Ethernet header options, Packit can be useful for the following scenarios:

  • tests in firewalls;
  • tests in Intrusion Detection Systems (IDS);
  • tests in Intrusion Prevention Systems (IPS);
  • tests in proxies;
  • tests in port scanning detectors;
  • network traffic simulations;
  • security tests; and
  • general TCP/IP auditing and pentests.

Packit is also an excellent tool for learning TCP/IP. However, this program does not support IPv6. (but you can help to implement it)


  1. BUILDING FROM SOURCE

Packit requires the following elements to compile:

  • autoconf >= 2.69
  • libnet >= 1.1.2
  • libpcap >= 0.8

Packit source installation is simple:

$ ./autogen.sh
$ ./configure
$ make

Then as 'root':

# make install

The autogen.sh can be used with the 'clean' option to remove all generated files. Example:

$ ./autogen.sh clean

packit's People

Contributors

davidpolverari avatar edwardbetts avatar eribertomota avatar rup0rt avatar sbirmi avatar thesamesam avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

packit's Issues

Patches from Debian

Hi @Rup0rt @sbirmi

There are two available patches from Debian here:

https://bugs.debian.org/cgi-bin/pkgreport.cgi?repeatmerged=no&src=packit

The titles from these patches:

packit: buffer overflows with options deEgjlsxXyY randomised
packit: 802.1Q VLAN tagged packet injection support

Today, I released the 1.5 version and uploaded to Debian. If needed, I can upload new versions up to Jan 25 to release in new Debian (Stretch, to be released up to June).

Thanks for all work.

Cheers,

Eriberto

Cannot inject packets in Monitor Mode

Hi, I have been using packit to inject UDP packets through a wireless interface and it works fine while the interface operates in Managed mode (it acts as a WiFi STA associated with an AP). To check it is working fine, I am capturing the injected packets with Wireshark on a different PC.

However, I do need to operate the interface in Monitor mode and packit doesn't seem to work in this mode (I can no longer receive the injected packets when using Wireshark).

My question is if packit should work in Monitor mode, and if so, is it required additional configuration for the wireless interface to make it work?

Thank you very much in advance for your help.

Sincerely,

Dayrene

Patch to 802.1Q VLAN tagged packet injection support

This issue was reported in Debian by Dennis Vshivkov [email protected][1]. There is a patch.

[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=287667

The original text, written in 2004:

"The attached patch adds an -I option, to specify 802.1Q VLAN
ID/CFI/priority combination number."

I tested the patch over 1.0 version and it didn't work. The submitter email address is bouncing.

I attached the original patch. This bug is relative to #7.

Eriberto

packit_1.0_dot1q.patch.txt

Buffer overflows with options deEgjlsxXyY randomised

This issue was reported in Debian by Dennis Vshivkov [email protected][1]. There is a patch.

[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=287666

The original text, written in 2004:

"The attached patch represents the following:

! Fixed buffer overruns with `R' (random) argument supplied to the following
options: -d, -e, -E, -g, -j, -l, -s, -x, -X, -y, -Y. The ones that deal
with IP addresses probably never triggered, as malloc() usually never
allocates less than 16 bytes which are required to store any NUL-terminated
IP address anyway. However, the others, used to specify MAC addresses,
which take up to 18 bytes, often were 1 or 2 bytes off the buffer, and
produced segfaults and/or no useful results intermittently because of this."

I tested the patch over 1.0 version and it didn't work. The submitter email address is bouncing.

I will attach the original patch. This bug is relative to #7.

Eriberto

packit_1.0_fix-overruns.patch.txt

confusing message when arguments specified incorrectly

Use case: "Oh, I am reading the manual page and I see I can use "-c 1" to get one packet. Let's try it..."

packit -c 1 -m capture "not port ssh"

Error: No destination IP address defined

Expected result:

An error message with more information on the problem in the arguments.

Warnings when building in Debian Sid

When building in Debian Sid, I can see:

gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o init.o init.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o define_defaults.o define_defaults.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o error.o error.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o injection.o injection.c
injection.c: In function ‘injection_init’:
injection.c:88:5: warning: ‘pcap_lookupdev’ is deprecated: use 'pcap_findalldevs' and use the first device [-Wdeprecated-declarations]
   88 |     if(!g_device && (g_device = pcap_lookupdev(error_buf)) == NULL)
      |     ^~
In file included from globals.h:39,
                 from injection.h:29,
                 from injection.c:29:
/usr/include/pcap/pcap.h:328:16: note: declared here
  328 | PCAP_API char *pcap_lookupdev(char *)
      |                ^~~~~~~~~~~~~~
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o capture.o capture.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_arp_hdr.o shape_arp_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_tcp_hdr.o shape_tcp_hdr.c
capture.c: In function ‘capture_init’:
capture.c:65:13: warning: ‘pcap_lookupdev’ is deprecated: use 'pcap_findalldevs' and use the first device [-Wdeprecated-declarations]
   65 |             if((g_device = pcap_lookupdev(error_buf)) == NULL)
      |             ^~
In file included from globals.h:39,
                 from capture.h:30,
                 from capture.c:28:
/usr/include/pcap/pcap.h:328:16: note: declared here
  328 | PCAP_API char *pcap_lookupdev(char *)
      |                ^~~~~~~~~~~~~~
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_udp_hdr.o shape_udp_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_icmpv4_hdr.o shape_icmpv4_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_ipv4_hdr.o shape_ipv4_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_ethernet_hdr.o shape_ethernet_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o shape_packet.o shape_packet.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o utils.o utils.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o stats.o stats.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o usage.o usage.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o exit.o exit.c
utils.c: In function ‘retrieve_rand_ipv4_addr’:
utils.c:101:21: warning: passing argument 1 to restrict-qualified parameter aliases with argument 3 [-Wrestrict]
  101 |             sprintf((char*)ip, "%s.%d", ip, oct);
      |                     ^~~~~~~~~
utils.c: In function ‘retrieve_rand_ethernet_addr’:
utils.c:122:20: warning: passing argument 1 to restrict-qualified parameter aliases with argument 3 [-Wrestrict]
  122 |            sprintf((char*)eaddr, "%s:%0x", eaddr, oct);
      |                    ^~~~~~~~~~~~
exit.c: In function ‘injection_clean_exit’:
exit.c:43:13: warning: ignoring return value of ‘fgets’, declared with attribute warn_unused_result [-Wunused-result]
   43 |             fgets(a, 2, stdin);
      |             ^~~~~~~~~~~~~~~~~~
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o main.o main.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_ts.o print_ts.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_arp_hdr.o print_arp_hdr.c
main.c: In function ‘randomisable_str’:
main.c:96:11: warning: pointer targets in assignment from ‘char *’ to ‘u_int8_t *’ {aka ‘unsigned char *’} differ in signedness [-Wpointer-sign]
   96 |  if ((*to = strdup(optarg)) == NULL)
      |           ^
In file included from /usr/include/string.h:495,
                 from /usr/include/libnet.h:63,
                 from globals.h:38,
                 from utils.h:31,
                 from utils.c:30:
In function ‘strncpy’,
    inlined from ‘format_ethernet_addr’ at utils.c:554:9:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 18 equals destination size [-Wstringop-truncation]
  106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/string.h:495,
                 from /usr/include/libnet.h:63,
                 from main.h:30,
                 from main.c:33:
In function ‘strncpy’,
    inlined from ‘parse_capture_options’ at main.c:145:17:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 32 equals destination size [-Wstringop-truncation]
  106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In function ‘strncpy’,
    inlined from ‘parse_capture_options’ at main.c:149:17:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 32 equals destination size [-Wstringop-truncation]
  106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In function ‘strncpy’,
    inlined from ‘parse_port_range’ at utils.c:590:9:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:10: warning: ‘__builtin_strncpy’ specified bound 11 equals destination size [-Wstringop-truncation]
  106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
utils.c: In function ‘parse_port_range’:
utils.c:605:31: warning: ‘spread[0]’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  605 |     range = spread[1] - spread[0] + 1;
      |                         ~~~~~~^~~
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_tcp_hdr.o print_tcp_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_udp_hdr.o print_udp_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_icmpv4_hdr.o print_icmpv4_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_ipv4_hdr.o print_ipv4_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_ethernet_hdr.o print_ethernet_hdr.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_pktdump.o print_pktdump.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_capture.o print_capture.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o print_injection.o print_injection.c
gcc -DHAVE_CONFIG_H -I. -I..  -I.. -I../includes -I/usr/include/pcap -Wdate-time -D_FORTIFY_SOURCE=2  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall -c -o contrib/pcap_setnonblock.o contrib/pcap_setnonblock.c
gcc  -g -O2 -fdebug-prefix-map=/PKGS/packit/packit=. -fstack-protector-strong -Wformat -Werror=format-security -Wall  -Wl,-z,relro -Wl,-z,now -o packit init.o define_defaults.o error.o injection.o capture.o shape_arp_hdr.o shape_tcp_hdr.o shape_udp_hdr.o shape_icmpv4_hdr.o shape_ipv4_hdr.o shape_ethernet_hdr.o shape_packet.o utils.o stats.o contrib/pcap_setnonblock.o usage.o exit.o main.o print_ts.o print_arp_hdr.o print_tcp_hdr.o print_udp_hdr.o print_icmpv4_hdr.o print_ipv4_hdr.o print_ethernet_hdr.o print_pktdump.o print_capture.o print_injection.o  -lpcap -lpcap -lpcap -lnet

Cheers,

Eriberto

Feature Request: latest version for ubuntu 18.04

I'm using Ubuntu 18.04 and the latest version is not installed with apt.
Restricted to the network environment, I can only install software from the apt's official source (lanuchpad) or its mirror.
I want to get new features like 802.11q , what do I need to do, or what additional adaptions do I need to do?

Possible memory leaks

There are possibly some memory leaks caused by strdup usage without corresponding free anywhere in sight.

investigate shape_ethernet_hdr: storing ETH_BROADCAST (6 bytes) in pointer (on 32bit systems)

I don't have a 32-bit system but the code looks buggy.

[shape_ethernet_hdr.c]

    if(ehdr_o.d_addr == NULL
       && (injection_type == ETHERTYPE_ARP || injection_type == ETHERTYPE_REVARP))
        ehdr_o.d_addr = ETH_BROADCAST;   <<<<<<<<<< buggy assignment

[globals.h]

   #define ETH_BROADCAST                   0xffffffffffff      /* ff:ff:ff:ff:ff:ff */

[inject_defs.h]

    u_int8_t *d_addr;                      /* destination ethernet address string */  <<<<<< (pointer)
    u_int8_t dhw_addr[18];
} ehdr_o;

I am not sure how this assignment would work on a 32-bit system and would the expectation here is.

This should be exercised by running packit -t ARP -A 1 -y 9.9.9.9 -e "0:9:9:9:9:9" (if someone can try this out).

Call stack:

#0  shape_ethernet_hdr (pkt_d=0x555555762460) at shape_ethernet_hdr.c:76
#1  0x0000555555558bee in shape_packet () at shape_packet.c:78
#2  0x0000555555556b4e in without_response (port_range=port_range@entry=0) at injection.c:336
#3  0x0000555555556f8a in injection_init () at injection.c:99
#4  0x0000555555555f86 in main (argc=9, argv=0x7fffffffe5d8) at main.c:612

Include SPDX short identifiers copyright block comments

According to https://spdx.org/, SPDX (Software Packet Data Exchange) is

"an open standard for communicating software bill of materials (including components, licenses, copyrights, and security references)."

SPDX short identifiers provide a unobtrusive, machine-readable and language-independent way to convey license information. It makes header files smaller and allows organizations and other interested third-parties (eg.: Linux distribution developers) to automatically parse license information of all source files in a project.

What follows is an example of a tentative copyright block comment using SPDX short identifiers:

/*
 * Packit -- network injection and capture tool
 *
 * Original author: Darren Bounds <[email protected]>
 *
 * Copyright 2002-2004 Darren Bounds <[email protected]>
 * Copyright 2004-2005 Dennis Vshivkov <[email protected]>
 * Copyright 2006      Deniz Adrian <[email protected]>
 * Copyright 2013      Mats Erik Andersson <[email protected]>
 * Copyright 2017      Robert Krause <[email protected]>
 * Copyright 2017      Sharad B
 * Copyright 2020      David Polverari <[email protected]>
 * Copyright 2020      Jeroen Roovers <[email protected]>
 *
 * SPDX-License-Identifier: GPL-2.0-or-later
 * See LICENSE file for more information.
 *
 * packit official page at https://github.com/resurrecting-open-source-projects/packit
 */

It could be reduced even further, by adopting other strategies, like moving the name of the authors/contributors to other files and referencing them on the header:

/*
 * Packit -- network injection and capture tool
 *
 * Original author: Darren Bounds <[email protected]>
 *
 * Copyright 2002-2020 Darren Bounds <[email protected]> and Contributors.
 * See CONTRIBUTORS file for details.
 *
 * SPDX-License-Identifier: GPL-2.0-or-later
 * See LICENSE file for more information.
 *
 * packit official page at https://github.com/resurrecting-open-source-projects/packit
 */

Even if we can't remove the standard GPL header, I think the addition of SPDX short identifiers still benefits a lot of third-parties. Thus I propose a discussion to check whether and how we could use those SPDX short identifiers on the project.

Error when defining the payload as HEX when using the option -p

Hi,

I am using packit with the option -p to inject UDP packets with a specific payload. When I use the ASCII format, as in the command below, it works.

$ packit -m inject -t udp -s 172.16.5.54 -d 172.16.4.227 -S 403 -D 80 -c 10000 -w 0 -b 20 -p 'Hi, this is my message'

However, when I try the Hex format:

$ sudo packit -m inject -t udp -s 172.16.5.54 -d 172.16.4.227 -S 403 -D 80 -c 10000 -w 0 -b 20 -p '0x 70 61 63 6B 69 74'

it fails reporting the following:

packit: malloc.c:2401: sysmalloc: Assertion `(old_top == initial_top (av) && old_size == 0) || ((unsigned long) (old_size) >= MINSIZE && prev_inuse (old_top) && ((unsigned long) old_end & (pagesize - 1)) == 0)' failed.
Aborted

Could you please help me to solve this problem?

Thank you very much in advance for your help.

Sincerely,

Dayrene

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.