mirror of
https://github.com/opnsense/plugins.git
synced 2026-05-28 04:34:15 -04:00
security/tor: fix iterator
This commit is contained in:
parent
51ddd9099c
commit
138e3e277f
3 changed files with 8 additions and 7 deletions
|
|
@ -1,7 +1,8 @@
|
|||
PLUGIN_NAME= tor
|
||||
PLUGIN_VERSION= 1.7
|
||||
PLUGIN_COMMENT= The Onion Router
|
||||
PLUGIN_DEPENDS= tor ruby
|
||||
PLUGIN_MAINTAINER= franz.fabian.94@gmail.com
|
||||
PLUGIN_NAME= tor
|
||||
PLUGIN_VERSION= 1.7
|
||||
PLUGIN_REVISION= 1
|
||||
PLUGIN_COMMENT= The Onion Router
|
||||
PLUGIN_DEPENDS= tor ruby
|
||||
PLUGIN_MAINTAINER= ranz.fabian.94@gmail.com
|
||||
|
||||
.include "../../Mk/plugins.mk"
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ use \OPNsense\Tor\HiddenService;
|
|||
|
||||
$hostnames = array();
|
||||
$services = new HiddenService();
|
||||
foreach ($services->service->__items as $service) {
|
||||
foreach ($services->service->iterateItems() as $service) {
|
||||
$directory_name = ((string)$service->name);
|
||||
$hostnamefile = TOR_DATA_DIR . '/' . $directory_name . '/hostname';
|
||||
if (file_exists($hostnamefile)) {
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ require_once('tor_helper.php');
|
|||
use \OPNsense\Tor\HiddenService;
|
||||
|
||||
$services = new HiddenService();
|
||||
foreach ($services->service->__items as $service) {
|
||||
foreach ($services->service->iterateItems() as $service) {
|
||||
$directory_name = ((string)$service->name);
|
||||
$hostdir = TOR_DATA_DIR . '/' . $directory_name;
|
||||
if (!file_exists($hostdir)) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue