aboutsummaryrefslogtreecommitdiffstats
path: root/config/openbgpd
diff options
context:
space:
mode:
authordoktornotor <notordoktor@gmail.com>2015-09-07 20:23:01 +0200
committerdoktornotor <notordoktor@gmail.com>2015-09-07 20:23:01 +0200
commitd81c24e5983d4a1fadda795720ac69906e1283ac (patch)
treedf3098cca3a51e64ac4f1e847e97589b743730e2 /config/openbgpd
parent72ff5393d4e0b9836b624ab8b55f962980dd7a31 (diff)
downloadpfsense-packages-d81c24e5983d4a1fadda795720ac69906e1283ac.tar.gz
pfsense-packages-d81c24e5983d4a1fadda795720ac69906e1283ac.tar.bz2
pfsense-packages-d81c24e5983d4a1fadda795720ac69906e1283ac.zip
openbgpd code style fixes
Diffstat (limited to 'config/openbgpd')
-rw-r--r--config/openbgpd/openbgpd_neighbors.xml131
1 files changed, 66 insertions, 65 deletions
diff --git a/config/openbgpd/openbgpd_neighbors.xml b/config/openbgpd/openbgpd_neighbors.xml
index 5553c022..6872b793 100644
--- a/config/openbgpd/openbgpd_neighbors.xml
+++ b/config/openbgpd/openbgpd_neighbors.xml
@@ -2,47 +2,47 @@
<!DOCTYPE packagegui SYSTEM "../schema/packages.dtd">
<?xml-stylesheet type="text/xsl" href="../xsl/package.xsl"?>
<packagegui>
- <copyright>
- <![CDATA[
+ <copyright>
+ <![CDATA[
/* $Id$ */
-/* ========================================================================== */
+/* ====================================================================================== */
/*
- openbgpd_neighbors.xml
- part of pfSense (http://www.pfSense.com)
- Copyright (C) 2007 Scott Ullrich (sullrich@gmail.com)
- All rights reserved.
- */
-/* ========================================================================== */
+ openbgpd_neighbors.xml
+ part of pfSense (https://www.pfSense.org/)
+ Copyright (C) 2007 Scott Ullrich (sullrich@gmail.com)
+ 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:
+ 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.
+ 1. Redistributions of source code must retain the above copyright notice,
+ this list of conditions and the following disclaimer.
- 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>
- <description>Describe your package here</description>
- <requirements>Describe your package requirements here</requirements>
- <faq>Currently there are no FAQ items provided.</faq>
+ 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>
<name>OpenBGPDNeighbors</name>
- <version>1</version>
+ <version>0.9.3.6</version>
<title>Services: OpenBGPD Neighbors</title>
<include_file>/usr/local/pkg/openbgpd.inc</include_file>
<tabs>
@@ -76,7 +76,7 @@
<columnitem>
<fielddescr>Group</fielddescr>
<fieldname>groupname</fieldname>
- </columnitem>
+ </columnitem>
<columnitem>
<fielddescr>Neighbor</fielddescr>
<fieldname>neighbor</fieldname>
@@ -100,13 +100,13 @@
<field>
<fielddescr>TCP-MD5 key</fielddescr>
<fieldname>md5sigkey</fieldname>
- <description>The md5 key to communicate with the peer. Does not work with Cisco BGP routers. If the Local Addr option is not set listening ip will be used.</description>
+ <description>The MD5 key to communicate with the peer. Does not work with Cisco BGP routers. If the 'Local Addr' option is not set, listening IP will be used.</description>
<type>input</type>
</field>
<field>
<fielddescr>TCP-MD5 password</fielddescr>
<fieldname>md5sigpass</fieldname>
- <description>The md5 password to communicate with the peer. Use this when communicating with a Cisco BGP router. If the Local Addr option is not set listenning ip will be used.</description>
+ <description>The MD5 password to communicate with the peer. Use this when communicating with a Cisco BGP router. If the 'Local Addr' option is not set, listening IP will be used.</description>
<type>input</type>
</field>
<field>
@@ -124,13 +124,13 @@
<field>
<fielddescr>Neighbor Parameters</fielddescr>
<fieldname>Neighbor Parameters</fieldname>
- <type>rowhelper</type>
- <rowhelper>
+ <type>rowhelper</type>
+ <rowhelper>
<rowhelperfield>
- <fielddescr>Parameters</fielddescr>
- <fieldname>parameters</fieldname>
- <description>Neighbor settings.</description>
- <type>select</type>
+ <fielddescr>Parameters</fielddescr>
+ <fieldname>parameters</fieldname>
+ <description>Neighbor settings</description>
+ <type>select</type>
<options>
<option><name>Announce all</name><value>announce all</value></option>
<option><name>Announce none</name><value>announce none</value></option>
@@ -148,40 +148,42 @@
<option><name>Softreconfig out no</name><value>softreconfig out no</value></option>
<option><name>Tcp md5sig password X</name><value>tcp md5sig password</value></option>
<option><name>Local address X</name><value>local-address</value></option>
- <option><name>set nexthop X</name><value>set nexthop</value></option>
- <option><name>set nexthop blackhole</name><value>set nexthop blackhole</value></option>
- <option><name>set nexthop reject</name><value>set nexthop reject</value></option>
- <option><name>set nexthop no-modify</name><value>set nexthop no-modify</value></option>
- <option><name>set nexthop self</name><value>set nexthop self</value></option>
+ <option><name>set nexthop X</name><value>set nexthop</value></option>
+ <option><name>set nexthop blackhole</name><value>set nexthop blackhole</value></option>
+ <option><name>set nexthop reject</name><value>set nexthop reject</value></option>
+ <option><name>set nexthop no-modify</name><value>set nexthop no-modify</value></option>
+ <option><name>set nexthop self</name><value>set nexthop self</value></option>
</options>
</rowhelperfield>
<rowhelperfield>
- <fielddescr>Value</fielddescr>
- <fieldname>parmvalue</fieldname>
- <type>input</type>
- <size>25</size>
+ <fielddescr>Value</fielddescr>
+ <fieldname>parmvalue</fieldname>
+ <type>input</type>
+ <size>25</size>
</rowhelperfield>
- </rowhelper>
+ </rowhelper>
</field>
</fields>
<custom_php_command_before_form>
+ <![CDATA[
$newoptions = array();
$new_groups = array();
- if($config['installedpackages']['openbgpdgroups']['config']) {
- foreach($config['installedpackages']['openbgpdgroups']['config'] as $item)
- $new_groups[] = $item['name'];
- $counter = 0;
- foreach($new_groups as $group) {
+ if ($config['installedpackages']['openbgpdgroups']['config']) {
+ foreach ($config['installedpackages']['openbgpdgroups']['config'] as $item) {
+ $new_groups[] = $item['name'];
+ }
+ $counter = 0;
+ foreach ($new_groups as $group) {
$newoptions['option'][$counter]['name'] = $group;
$newoptions['option'][$counter]['value'] = $group;
$counter++;
- }
+ }
$newoptions['option'][$counter]['name'] = "";
- $newoptions['option'][$counter]['value'] = "";
+ $newoptions['option'][$counter]['value'] = "";
$pkg['fields']['field'][4]['options'] = $newoptions;
$counter = 0;
- foreach($pkg['fields']['field'] as $field) {
- if($field['name'] == "group") {
+ foreach ($pkg['fields']['field'] as $field) {
+ if ($field['name'] == "group") {
$foundgroupid = $counter;
echo "found it: $counter";
}
@@ -190,11 +192,10 @@
} else {
$newoptions['option'][0]['name'] = "";
$newoptions['option'][0]['value'] = "";
- $pkg['fields']['field'][4]['options'] =$newoptions;
+ $pkg['fields']['field'][4]['options'] = $newoptions;
}
+ ]]>
</custom_php_command_before_form>
- <custom_php_deinstall_command>
- </custom_php_deinstall_command>
<custom_php_resync_config_command>
openbgpd_install_conf();
</custom_php_resync_config_command>