From ae0bd09a47526ba83db013cbb55a9b489570e6b0 Mon Sep 17 00:00:00 2001 From: Deon George Date: Sun, 14 Apr 2024 10:43:07 +1000 Subject: [PATCH] Add Debug command Packet:Address --- app/Console/Commands/Debug/PacketAddress.php | 57 ++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 app/Console/Commands/Debug/PacketAddress.php diff --git a/app/Console/Commands/Debug/PacketAddress.php b/app/Console/Commands/Debug/PacketAddress.php new file mode 100644 index 0000000..80a933b --- /dev/null +++ b/app/Console/Commands/Debug/PacketAddress.php @@ -0,0 +1,57 @@ +argument('ftn')); + + switch ($this->argument('type')) { + case 'echomail': + $o = new Echomail; + break; + + case 'netmail': + $o = new Netmail; + break; + + default: + $this->error('Unknown type: '.$this->argument('type')); + exit(1); + } + + $o = $o->where('id',$this->argument('dbid'))->get(); + + dd(hex_dump($ao->getPacket($o))); + } +} \ No newline at end of file