From 2b098ba9dafc7d8e147e9d2171225edbbb2dec91 Mon Sep 17 00:00:00 2001 From: Ad Schellevis Date: Mon, 9 Nov 2015 22:24:22 +0100 Subject: [PATCH] (auth) add api auth to auth factory --- .../mvc/app/library/OPNsense/Auth/AuthenticationFactory.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/opnsense/mvc/app/library/OPNsense/Auth/AuthenticationFactory.php b/src/opnsense/mvc/app/library/OPNsense/Auth/AuthenticationFactory.php index 140fbe504..e657970ff 100644 --- a/src/opnsense/mvc/app/library/OPNsense/Auth/AuthenticationFactory.php +++ b/src/opnsense/mvc/app/library/OPNsense/Auth/AuthenticationFactory.php @@ -66,6 +66,7 @@ class AuthenticationFactory { $servers = array(); $servers['Local Database'] = array("name" => "Local Database", "type" => "local"); + $servers['Local API'] = array("name" => "Local API Database", "type" => "api"); $configObj = Config::getInstance()->object(); foreach ($configObj->system->children() as $key => $value) { if ($key == 'authserver' && !empty($value->type) && !empty($value->name)) { @@ -106,6 +107,9 @@ class AuthenticationFactory case 'voucher': $authObject = new Voucher(); break; + case 'api': + $authObject = new API(); + break; default: $authObject = null; }