From 10d2c0bbaa2b5c933a37056c784d3de84fa82eaf Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 2 Aug 2017 09:30:39 -0400 Subject: sploitset ftpwn mounts ftp directory on breach --- ShiftOS_TheReturn/Hacking.cs | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'ShiftOS_TheReturn') diff --git a/ShiftOS_TheReturn/Hacking.cs b/ShiftOS_TheReturn/Hacking.cs index 5c473df..e670756 100644 --- a/ShiftOS_TheReturn/Hacking.cs +++ b/ShiftOS_TheReturn/Hacking.cs @@ -81,6 +81,18 @@ namespace ShiftOS.Engine } } + public static byte[] GetLootBytes(string lootid) + { + foreach (var type in ReflectMan.Types.Where(x => x.GetInterfaces().Contains(typeof(IHackableProvider)))) + { + var @interface = (IHackableProvider)Activator.CreateInstance(type, null); + var bytes = @interface.FindLootBytes(lootid); + if (bytes != null) + return bytes; + } + throw new NaughtyDeveloperException("Seems like the loot system's trying to work without any loot. This isn't normal."); + } + public static void InitHack(Objects.Hackable data) { var hsys = new HackableSystem(); @@ -212,6 +224,7 @@ namespace ShiftOS.Engine Objects.Payload[] GetPayloads(); Objects.Port[] GetPorts(); Objects.Loot[] GetLoot(); + byte[] FindLootBytes(string lootid); } public class HackableSystem -- cgit v1.2.3