aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--config/blinkled/binaries/blinkledbin9311 -> 0 bytes
-rw-r--r--config/blinkled/blinkled.inc75
-rw-r--r--config/blinkled/blinkled.xml105
3 files changed, 0 insertions, 180 deletions
diff --git a/config/blinkled/binaries/blinkled b/config/blinkled/binaries/blinkled
deleted file mode 100644
index 2a8681a5..00000000
--- a/config/blinkled/binaries/blinkled
+++ /dev/null
Binary files differ
diff --git a/config/blinkled/blinkled.inc b/config/blinkled/blinkled.inc
deleted file mode 100644
index ef2b6db8..00000000
--- a/config/blinkled/blinkled.inc
+++ /dev/null
@@ -1,75 +0,0 @@
-<?php
-/*
- blinkled.inc
- part of pfSense (https://www.pfSense.org/)
- Copyright (C) 2009 Jim Pingle
- Copyright (C) 2015 ESF, LLC
- All rights reserved.
-
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
- 1. Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- 2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
- THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
- OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- POSSIBILITY OF SUCH DAMAGE.
-*/
-
-require_once("config.inc");
-require_once("functions.inc");
-
-function sync_package_blinkled() {
- global $config;
- $blinkled_config = $config['installedpackages']['blinkled']['config'][0];
- /* Kill all instances of blinkled */
- if (is_process_running("blinkled")) {
- mwexec("/usr/bin/killall -9 blinkled");
- }
- /* If blinkled is not running, start it */
- if (!is_process_running("blinkled")) {
- blinkled_start();
- }
-}
-
-function blinkled_launch($int, $led) {
- mwexec("/usr/local/bin/blinkled -i " . escapeshellarg($int) . " -l /dev/led/led" . escapeshellarg($led));
-}
-
-function blinkled_start() {
- global $config;
- $blinkled_config = $config['installedpackages']['blinkled']['config'][0];
- if (!($blinkled_config['enable'])) {
- return;
- }
-
- if (($blinkled_config['enable_led2']) && ($blinkled_config['iface_led2'])) {
- blinkled_launch(convert_friendly_interface_to_real_interface_name($blinkled_config['iface_led2']), 2);
- }
- if (($blinkled_config['enable_led3']) && ($blinkled_config['iface_led3'])) {
- blinkled_launch(convert_friendly_interface_to_real_interface_name($blinkled_config['iface_led3']), 3);
- }
-}
-
-function validate_form_blinkled($post, &$input_errors) {
- /* Make sure both aren't using the same interface */
- if (($post['iface_led2']) && ($post['iface_led3']) &&
- (($post['enable_led2']) && ($post['enable_led3'])) &&
- ($post['iface_led2'] == $post['iface_led3'])) {
- $input_errors[] = 'You cannot set two LEDs for a single interface. Please choose seperate interfaces.';
- }
-}
-
-?>
diff --git a/config/blinkled/blinkled.xml b/config/blinkled/blinkled.xml
deleted file mode 100644
index 65a574af..00000000
--- a/config/blinkled/blinkled.xml
+++ /dev/null
@@ -1,105 +0,0 @@
-<?xml version="1.0" encoding="utf-8" ?>
-<!DOCTYPE packagegui SYSTEM "../schema/packages.dtd">
-<?xml-stylesheet type="text/xsl" href="../xsl/package.xsl"?>
-<packagegui>
- <copyright>
- <![CDATA[
-/* $Id$ */
-/* ====================================================================================== */
-/*
- blinkled.xml
- part of pfSense (https://www.pfSense.org/)
- Copyright (C) 2009-2012 Jim Pingle
- Copyright (C) 2015 ESF, LLC
- All rights reserved.
-*/
-/* ====================================================================================== */
-/*
- Redistribution and use in source and binary forms, with or without
- modification, are permitted provided that the following conditions are met:
-
-
- 1. Redistributions of source code must retain the above copyright notice,
- this list of conditions and the following disclaimer.
-
- 2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
-
- THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
- INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
- AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
- OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
- POSSIBILITY OF SUCH DAMAGE.
-*/
-/* ====================================================================================== */
- ]]>
- </copyright>
- <title>Interfaces: Assign LEDs</title>
- <name>blinkled</name>
- <version>0.4.4</version>
- <savetext>Save</savetext>
- <include_file>/usr/local/pkg/blinkled.inc</include_file>
- <menu>
- <name>Assign LEDs</name>
- <tooltiptext>Assign LEDs to indicate network activity.</tooltiptext>
- <section>Interfaces</section>
- <url>/pkg_edit.php?xml=blinkled.xml</url>
- </menu>
- <additional_files_needed>
- <item>https://packages.pfsense.org/packages/config/blinkled/blinkled.inc</item>
- <prefix>/usr/local/pkg/</prefix>
- </additional_files_needed>
- <!-- TODO: Make the blinkled.sh script really usable for start/stop/restart -->
- <service>
- <name>blinkled</name>
- <rcfile>blinkled.sh</rcfile>
- <executable>blinkled</executable>
- <description>Network Activity LED Indicator Daemon</description>
- </service>
- <fields>
- <field>
- <fielddescr>Enable blinkled</fielddescr>
- <fieldname>enable</fieldname>
- <type>checkbox</type>
- <enablefields>enable_led2,enable_led3,iface_led2,iface_led3</enablefields>
- <description>if this is enabled, it will use LED #2 and #3 to
- indicate network activity. Be aware, however, that this will
- possibly consume some system resources in the process.</description>
- </field>
- <field>
- <fielddescr>Enable LED #2</fielddescr>
- <fieldname>enable_led2</fieldname>
- <type>checkbox</type>
- </field>
- <field>
- <fielddescr>Interface For LED #2</fielddescr>
- <fieldname>iface_led2</fieldname>
- <type>interfaces_selection</type>
- <description>Pick an interface to blink for activity on LED #2</description>
- </field>
- <field>
- <fielddescr>Enable LED #3</fielddescr>
- <fieldname>enable_led3</fieldname>
- <type>checkbox</type>
- </field>
- <field>
- <fielddescr>Interface For LED #3</fielddescr>
- <fieldname>iface_led3</fieldname>
- <type>interfaces_selection</type>
- <description>Pick an interface to blink for activity on LED #3</description>
- </field>
- </fields>
- <custom_php_validation_command>
- validate_form_blinkled($_POST, $input_errors);
- </custom_php_validation_command>
- <custom_php_resync_config_command>
- sync_package_blinkled();
- </custom_php_resync_config_command>
-</packagegui>