Adversarial C2 Protocol Implemented in Zig

Keep retrying if there is no interface

+7 -1
+7 -1
src/main.zig
··· 146 146 147 147 if (flags.connect != null) { 148 148 reconnect: while (true) { 149 - client = try .init(); 149 + client = SaprusClient.init() catch |err| switch (err) { 150 + error.NoInterfaceFound => { 151 + try init.io.sleep(.fromMilliseconds(100), .boot); 152 + continue :reconnect; 153 + }, 154 + else => |e| return e, 155 + }; 150 156 defer client.deinit(); 151 157 log.debug("Starting connection", .{}); 152 158