forked from opnsense/plugins
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
64 changed files
with
142 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
@@ -52,7 +53,7 @@ public function getAction() | |
|
||
public function setAction() | ||
{ | ||
$result = array("result"=>"failed"); | ||
$result = array("result" => "failed"); | ||
if ($this->request->isPost()) { | ||
// load model and update with provided data | ||
$mdlClient = new Client(); | ||
|
@@ -63,7 +64,7 @@ public function setAction() | |
if (!array_key_exists("validations", $result)) { | ||
$result["validations"] = array(); | ||
} | ||
$result["validations"]["client.".$msg->getField()] = $msg->getMessage(); | ||
$result["validations"]["client." . $msg->getField()] = $msg->getMessage(); | ||
} | ||
// serialize model to config and save | ||
if ($valMsgs->count() == 0) { | ||
|
@@ -179,7 +180,7 @@ public function toggle_handler($uuid, $elements, $element) | |
if ($this->request->isPost()) { | ||
$mdlSetting = $this->getModel(); | ||
if ($uuid != null) { | ||
$node = $mdlSetting->getNodeByReference($elements . '.'. $element .'.' . $uuid); | ||
$node = $mdlSetting->getNodeByReference($elements . '.' . $element . '.' . $uuid); | ||
if ($node != null) { | ||
if ($node->enabled->__toString() == "1") { | ||
$result['result'] = "Disabled"; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/controllers/OPNsense/Freeradius/Api/DhcpController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2019 Michael Muenz <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
@@ -49,7 +50,7 @@ public function getAction() | |
|
||
public function setAction() | ||
{ | ||
$result = array("result"=>"failed"); | ||
$result = array("result" => "failed"); | ||
if ($this->request->isPost()) { | ||
// load model and update with provided data | ||
$mdlEAP = new EAP(); | ||
|
@@ -61,7 +62,7 @@ public function setAction() | |
if (!array_key_exists("validations", $result)) { | ||
$result["validations"] = array(); | ||
} | ||
$result["validations"]["eap.".$msg->getField()] = $msg->getMessage(); | ||
$result["validations"]["eap." . $msg->getField()] = $msg->getMessage(); | ||
} | ||
|
||
// serialize model to config and save | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
@@ -49,7 +50,7 @@ public function getAction() | |
|
||
public function setAction() | ||
{ | ||
$result = array("result"=>"failed"); | ||
$result = array("result" => "failed"); | ||
if ($this->request->isPost()) { | ||
// load model and update with provided data | ||
$mdlGeneral = new General(); | ||
|
@@ -61,7 +62,7 @@ public function setAction() | |
if (!array_key_exists("validations", $result)) { | ||
$result["validations"] = array(); | ||
} | ||
$result["validations"]["general.".$msg->getField()] = $msg->getMessage(); | ||
$result["validations"]["general." . $msg->getField()] = $msg->getMessage(); | ||
} | ||
|
||
// serialize model to config and save | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/controllers/OPNsense/Freeradius/Api/LdapController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/controllers/OPNsense/Freeradius/Api/LeaseController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2019 Michael Muenz <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
@@ -53,7 +54,7 @@ public function getAction() | |
|
||
public function setAction() | ||
{ | ||
$result = array("result"=>"failed"); | ||
$result = array("result" => "failed"); | ||
if ($this->request->isPost()) { | ||
// load model and update with provided data | ||
$mdlUser = new User(); | ||
|
@@ -64,7 +65,7 @@ public function setAction() | |
if (!array_key_exists("validations", $result)) { | ||
$result["validations"] = array(); | ||
} | ||
$result["validations"]["user.".$msg->getField()] = $msg->getMessage(); | ||
$result["validations"]["user." . $msg->getField()] = $msg->getMessage(); | ||
} | ||
// serialize model to config and save | ||
if ($valMsgs->count() == 0) { | ||
|
@@ -180,7 +181,7 @@ public function toggle_handler($uuid, $elements, $element) | |
if ($this->request->isPost()) { | ||
$mdlSetting = $this->getModel(); | ||
if ($uuid != null) { | ||
$node = $mdlSetting->getNodeByReference($elements . '.'. $element .'.' . $uuid); | ||
$node = $mdlSetting->getNodeByReference($elements . '.' . $element . '.' . $uuid); | ||
if ($node != null) { | ||
if ($node->enabled->__toString() == "1") { | ||
$result['result'] = "Disabled"; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/Client.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/Dhcp.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/Eap.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/General.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/Ldap.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/Lease.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/freeradius/src/opnsense/mvc/app/models/OPNsense/Freeradius/User.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Freeradius; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/Api/BgpController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Fabian Franz | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/Api/DiagnosticsController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2017 Frank Wall | ||
* Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/Api/RipController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2017 Fabian Franz | ||
* | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/Api/ServiceController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2015 - 2017 Deciso B.V. | ||
* Copyright (C) 2017 Fabian Franz | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/BgpController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/DiagnosticsController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/GeneralController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
All rights reserved. | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/IsisController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
All rights reserved. | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/Ospf6Controller.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/OspfController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
All rights reserved. | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/controllers/OPNsense/Quagga/RipController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
All rights reserved. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Quagga; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/frr/src/opnsense/mvc/app/models/OPNsense/Quagga/General.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Quagga; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Quagga; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/* | ||
Copyright (C) 2017 Fabian Franz | ||
Copyright (C) 2017 Michael Muenz <[email protected]> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
namespace OPNsense\Quagga; | ||
|
||
use OPNsense\Base\BaseModel; | ||
|
1 change: 1 addition & 0 deletions
1
net/haproxy/src/opnsense/mvc/app/controllers/OPNsense/HAProxy/Api/ServiceController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2016 Frank Wall | ||
* Copyright (C) 2015 Deciso B.V. | ||
|
1 change: 1 addition & 0 deletions
1
net/haproxy/src/opnsense/mvc/app/controllers/OPNsense/HAProxy/Api/SettingsController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2016 Frank Wall | ||
* Copyright (C) 2015 Deciso B.V. | ||
|
1 change: 1 addition & 0 deletions
1
net/haproxy/src/opnsense/mvc/app/controllers/OPNsense/HAProxy/Api/StatisticsController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2016 Frank Wall | ||
* Copyright (C) 2015 Deciso B.V. | ||
|
1 change: 1 addition & 0 deletions
1
net/haproxy/src/opnsense/mvc/app/controllers/OPNsense/HAProxy/StatisticsController.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2016 Frank Wall | ||
* Copyright (C) 2015 Deciso B.V. | ||
|
1 change: 1 addition & 0 deletions
1
net/haproxy/src/opnsense/mvc/app/models/OPNsense/HAProxy/HAProxy.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright (C) 2016-2017 Frank Wall | ||
* Copyright (C) 2015 Deciso B.V. | ||
|
Oops, something went wrong.