Abstract address session() details
This commit is contained in:
@@ -372,7 +372,7 @@ abstract class Packet extends FTNBase implements \Iterator, \Countable
|
||||
'H' => $date->format('H'), // Hour
|
||||
'M' => $date->format('i'), // Minute
|
||||
'S' => $date->format('s'), // Second
|
||||
'password' => strtoupper((! is_null($passwd)) ? $passwd : $o->session('pktpass')), // Packet Password
|
||||
'password' => strtoupper((! is_null($passwd)) ? $passwd : $o->pass_packet), // Packet Password
|
||||
];
|
||||
}
|
||||
|
||||
@@ -505,7 +505,7 @@ abstract class Packet extends FTNBase implements \Iterator, \Countable
|
||||
public function password(string $password=NULL): self
|
||||
{
|
||||
if ($password && (strlen($password) < 9))
|
||||
$this->pass_p = $password;
|
||||
$this->pass_p = strtoupper($password);
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
@@ -82,7 +82,7 @@ final class FSC39 extends Packet
|
||||
$this->tftn_p->host_id, // Dest Net
|
||||
(Setup::PRODUCT_ID & 0xff), // Product Code Lo
|
||||
Setup::PRODUCT_VERSION_MAJ, // Product Version Major
|
||||
$this->pass_p ?: $this->tftn_p->session('pktpass'), // Packet Password
|
||||
$this->pass_p ?: $this->tftn_p->pass_packet, // Packet Password
|
||||
$this->fftn_p->zone->zone_id, // Orig Zone
|
||||
$this->tftn_p->zone->zone_id, // Dest Zone
|
||||
'', // Reserved
|
||||
|
@@ -69,7 +69,7 @@ final class FSC45 extends Packet
|
||||
$this->tftn_p->host_id, // Dest Net
|
||||
(Setup::PRODUCT_ID & 0xff), // Product Code
|
||||
Setup::PRODUCT_VERSION_MAJ, // Product Version
|
||||
$this->pass_p ?: $this->tftn_p->session('pktpass'), // Packet Password
|
||||
$this->pass_p ?: $this->tftn_p->pass_packet, // Packet Password
|
||||
$this->fftn_p->zone->zone_id, // Orig Zone
|
||||
$this->tftn_p->zone->zone_id, // Dest Zone
|
||||
$this->fftn_p->zone->domain->name, // Orig Domain
|
||||
|
@@ -82,7 +82,7 @@ final class FSC48 extends Packet
|
||||
$this->tftn_p->host_id, // Dest Net
|
||||
(Setup::PRODUCT_ID & 0xff), // Product Code Lo
|
||||
Setup::PRODUCT_VERSION_MAJ, // Product Version Major
|
||||
$this->pass_p ?: $this->tftn_p->session('pktpass'), // Packet Password
|
||||
$this->pass_p ?: $this->tftn_p->pass_packet, // Packet Password
|
||||
$this->fftn_p->zone->zone_id, // Orig Zone
|
||||
$this->tftn_p->zone->zone_id, // Dest Zone
|
||||
$this->fftn_p->point_id ? $this->fftn_p->host_id : 0x00, // Aux Net
|
||||
|
@@ -75,7 +75,7 @@ final class FTS1 extends Packet
|
||||
$this->tftn_p->host_id, // Dest Net
|
||||
(Setup::PRODUCT_ID & 0xff), // Product Code Lo
|
||||
Setup::PRODUCT_VERSION_MAJ, // Product Version Major
|
||||
$this->pass_p ?: $this->tftn_p->session('pktpass'), // Packet Password
|
||||
$this->pass_p ?: $this->tftn_p->pass_packet, // Packet Password
|
||||
$this->fftn_p->zone->zone_id, // Orig Zone
|
||||
$this->tftn_p->zone->zone_id, // Dest Zone
|
||||
'', // Reserved
|
||||
|
@@ -106,7 +106,7 @@ class Tic extends FTNBase
|
||||
$result->put('REPLACES',$this->file->replaces);
|
||||
$result->put('AREA',$this->file->filearea->name);
|
||||
$result->put('AREADESC',$this->file->filearea->description);
|
||||
if ($x=strtoupper($this->to->session('ticpass')))
|
||||
if ($x=$this->to->pass_tic)
|
||||
$result->put('PW',$x);
|
||||
$result->put('CRC',sprintf("%X",$this->file->crc));
|
||||
|
||||
@@ -351,7 +351,7 @@ class Tic extends FTNBase
|
||||
throw new SizeMismatchException(sprintf('TIC file size [%d] doesnt match file [%s] (%d)',$this->file->size,$fs->path($rel_path_name),$y));
|
||||
|
||||
// Validate Password
|
||||
if (strtoupper($pw) !== ($y=strtoupper($this->file->fftn->session('ticpass'))))
|
||||
if (strtoupper($pw) !== ($y=$this->file->fftn->pass_tic))
|
||||
throw new InvalidPasswordException(sprintf('TIC file PASSWORD [%s] doesnt match system [%s] (%s)',$pw,$this->file->fftn->ftn,$y));
|
||||
|
||||
// Validate Sender is linked
|
||||
|
Reference in New Issue
Block a user