Hello,

I have followed the guide as per:
https://www.packetfence.org/doc/PacketFence_Installation_Guide.html#_command_line_interface_telnet_and_ssh
and I cannot find the place in Configuration → Policies and Access Control
→ Switches
to add the credentials, so I have added them to my switches.conf file
grep '10.2.2.60' /usr/local/pf/conf/switches.conf -A 9
[10.2.2.60]
deauthMethod=SSH
description=CAP AC
controllerIp=10.2.2.60
type=Mikrotik
cliTransport=SSH
cliUser=admin
cliPwd=<redacted>
ExternalPortalEnforcement=Y
radiusSecret=<redacted>
registrationVlan=102
isolationVlan=103

But when I try to de-associate a node I receive an error:
ERROR: [mac:12:e1:f9:6d:95:4a] Can't call method "exec" on an undefined
value at /usr/local/pf/lib/pf/Switch/Mikrotik.pm line 343.

I did a bit of digging and added a line of debugging here:
https://github.com/inverse-inc/packetfence/blob/1369b3819f3b1986d11da2bd75925187d7a62b00/lib/pf/Switch/Mikrotik.pm#L337
I added:
$logger->info("SSH connection to mikrotik access point with
credentials:$self->{_cliUser}, $self->{_cliPwd}");
then retarted.  I see the line printing in my logs, but the login and
password are blank.  Somehow my settings from switches.conf is not making
it to the deauthenticateMacSSH subroutine.
Dec  7 18:39:24 radius packetfence_httpd.webservices:
httpd.webservices(4423) INFO: [mac:12:e1:f9:6d:95:4a] SSH connection to
mikrotik access point with credentials:,
 (pf::Switch::Mikrotik::deauthenticateMacSSH)

Thank you for your help,
Adrian
_______________________________________________
PacketFence-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/packetfence-users

Reply via email to