From 58dc090c837abb54873d112b065d58f1785fdbbd Mon Sep 17 00:00:00 2001 From: Deon George Date: Tue, 21 May 2024 23:05:03 +1000 Subject: [PATCH] Use packets domain for packet validation, not remote sytems address --- app/Jobs/PacketProcess.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Jobs/PacketProcess.php b/app/Jobs/PacketProcess.php index 27f214a..50fb5f4 100644 --- a/app/Jobs/PacketProcess.php +++ b/app/Jobs/PacketProcess.php @@ -78,7 +78,7 @@ class PacketProcess implements ShouldQueue break; } - if (! our_nodes($this->do)->contains($pkt->fftn)) { + if (! our_nodes($pkt->fftn->zone->domain)->contains($pkt->fftn)) { Log::error(sprintf('%s:! Packet [%s] is from a system that is not configured with us? [%s] for [%s]',self::LOGKEY,$this->filename,$pkt->fftn_t,$this->do->name)); // @todo Notification::route('netmail',$pkt->fftn)->notify(new UnexpectedPacketFromYou($this->filename)); @@ -87,7 +87,7 @@ class PacketProcess implements ShouldQueue } // Check the packet is to our address, if not we'll reject it. - if (! our_address($this->do)->contains($pkt->tftn)) { + if (! our_address($pkt->tftn->zone->domain)->contains($pkt->tftn)) { Log::error(sprintf('%s:! Packet [%s] is not to our address? [%s]',self::LOGKEY,$this->filename,$pkt->tftn->ftn)); // @todo Notification::route('netmail',$pkt->fftn)->notify(new UnexpectedPacketToUs($this->filename));