From 4fbb098daa349a663015426d1210f1b59d0478c4 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Thu, 23 Oct 2014 16:46:09 -0700 Subject: Testnet work... getting there! --- control/NodeControlService.cpp | 18 ------------------ 1 file changed, 18 deletions(-) (limited to 'control') diff --git a/control/NodeControlService.cpp b/control/NodeControlService.cpp index 604c0917..c4edc132 100644 --- a/control/NodeControlService.cpp +++ b/control/NodeControlService.cpp @@ -120,7 +120,6 @@ void NodeControlService::_doCommand(IpcConnection *ipcc,const char *commandLine) ipcc->printf("200 help leave "ZT_EOL_S); ipcc->printf("200 help terminate []"ZT_EOL_S); ipcc->printf("200 help updatecheck"ZT_EOL_S); - //ipcc->printf("200 help inject "); } else if (cmd[0] == "auth") { if ((cmd.size() > 1)&&(_authToken.length() > 0)&&(_authToken == cmd[1])) { Mutex::Lock _l(_connections_m); @@ -240,23 +239,6 @@ void NodeControlService::_doCommand(IpcConnection *ipcc,const char *commandLine) } else { ipcc->printf("200 OK"ZT_EOL_S); } - } else if (cmd[0] == "inject") { - if (cmd.size() >= 6) { - MAC from,to; - unsigned char from2[6]; - unsigned char to2[6]; - from.fromString(cmd[2].c_str()); - to.fromString(cmd[3].c_str()); - from.copyTo(from2,6); - to.copyTo(to2,6); - if (_node->injectPacketFromHost(Utils::hexStrToU64(cmd[1].c_str()),from2,to2,Utils::hexStrToUInt(cmd[4].c_str()),cmd[5].c_str(),(unsigned int)cmd[5].length()+1)) { - ipcc->printf("200 OK"ZT_EOL_S); - } else { - ipcc->printf("500 inject failed or not supported by this tap device"ZT_EOL_S); - } - } else { - ipcc->printf("400 missing required arguments"ZT_EOL_S); - } } else { ipcc->printf("404 %s No such command. Use 'help' for help."ZT_EOL_S,cmd[0].c_str()); } -- cgit v1.2.3