Skip to content

Instantly share code, notes, and snippets.

@Ovyerus
Last active September 25, 2017 15:41
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Ovyerus/c80b2d35f7ba859295ac624d79f1ad13 to your computer and use it in GitHub Desktop.
Save Ovyerus/c80b2d35f7ba859295ac624d79f1ad13 to your computer and use it in GitHub Desktop.
Documentation for Hacknet's hacker scripts

Hacknet Scripts

Executing a Hacker Script

Hacknet.HackerScriptExecuter.runScript("HackerScripts/Script.txt", os);
// This implies that you're running this in a Pathfinder command.
// If not, you'll have to replace `os` with an instance of the players os
// somehow.

Default scripts are ThemeHack.txt (Naix's theme deleter) and SystemHack.txt (Striker's VMBootloaderTrap) To use your own script, create one using the documentation below and then add it to the Content/HackerScripts folder in your Hacknet installation path.

Script Documentation

Each line must end ​ $#%#$ and a Windows new line (\r\n) directly after (​ $#%#$\r\n). <> are just used to differentiate arguments from the command. Do not include them when you write your script.

config <playerComp> <computerNameOrIP> <delay>

Configures the script so that Hacknet knows who is being aimed at and who is attacking.

playerComp Literally just 'playerComp', don't change this.

computerName The name or IP of the computer that is executing the script.

delay Time to wait after in seconds

delay <delay>

Pause execution of the script.

delay Time to delay in seconds.

connect

Connects the attackers computer to the target.

openPort <portNumber>

Opens a port on the target's computer.

portNumber The number of the port to open.

delete <directory> <file>

Deletes the specified file off the target's computer.

directory Location of the file to delete.

file The file to delete.

reboot

Reboots the target's computer.

forkbomb

Executes a forkbomb attack on the target's computer, forcing a reboot.

disconnect

Disconnects the attacker from the target's computer.

systakeover

Executes the sequence when the player's system gets attacked by Striker.

clearTerminal

Clears the target's terminal.

write <text>

Prints text to the target's console without a line ending(?).

text Text to print.

writel <text>

Prints text to the target's console.

text Text to print.

hideNetMap

Hides the target's netmap.

hideRam

Hides the target's RAM display,

hideDisplay

Hides the target's display.

stopMusic

Stops any currently playing music on the target's computer.

trackseq

Something about forkbomb tracing, not quite sure.

instanttrace

Trigger an instantainious ETAS (Emergency Trace Aversion Sequence.)

flash

Flash the target's screen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment