vpnc plugin parameter backport



hi,
I succesfully backported changes from git to networkmanager-vpnc plugin version 0.8.1.
In attachments are diffs and rpm packages


On 02/10/2011 02:00 PM, Jirka Klimes wrote:
On Thursday 10 of February 2011 13:26:22 Jan Malanik wrote:
hi,
it's possible to start vpnc plugin from network manager with parameter
--local-port 0?

thank you Jan Malanik
network-manager-vpnc now uses 'Local Port 0' parameter by  default.

http://git.gnome.org/browse/network-manager-
vpnc/commit/?id=fcb196788634db66b30245f346812070604ff0ef

Jirka




--
Thanks
Jan Malaník
Kernel QE, intern program

--- NetworkManager-vpnc-0.8.1/src/nm-vpnc-service.c	2011-02-16 19:02:45.796122703 +0100
+++ NetworkManager-vpnc-0.8.1-old/src/nm-vpnc-service.c	2011-02-16 20:16:27.128003532 +0100
@@ -51,7 +51,6 @@
 
 #define NM_VPNC_HELPER_PATH		LIBEXECDIR"/nm-vpnc-service-vpnc-helper"
 #define NM_VPNC_UDP_ENCAPSULATION_PORT	0 /* random port */
-#define NM_VPNC_LOCAL_PORT_ISAKMP       0 /* random port */
 
 typedef struct {
 	const char *name;
@@ -405,7 +404,6 @@
 	const char *props_natt_mode;
 	const char *default_username;
 	const char *pw_type;
-        const char *local_port;
 
 	default_username = nm_setting_vpn_get_user_name (s_vpn);
 
@@ -418,16 +416,6 @@
 	                     NM_VPNC_KEY_CISCO_UDP_ENCAPS_PORT " %d\n",
 	                     NM_VPNC_UDP_ENCAPSULATION_PORT);
 
-       local_port = nm_setting_vpn_get_data_item (s_vpn, NM_VPNC_KEY_LOCAL_PORT);
-        if (!local_port) {
-                /* Configure 'Local Port' to 0 (random port) if the value is not set in the setting.
- *                  * Otherwise vpnc would try to use 500 and could clash with other IKE processes.
- *                                   */
-                write_config_option (vpnc_fd,
-                                     NM_VPNC_KEY_LOCAL_PORT " %d\n",
-                                     NM_VPNC_LOCAL_PORT_ISAKMP);
-        }
-	
 	/* Fill username if it's not present */
 	props_username = nm_setting_vpn_get_data_item (s_vpn, NM_VPNC_KEY_XAUTH_USER);
 	if (   default_username

--- NetworkManager-vpnc-0.8.1/src/nm-vpnc-service.h	2011-02-16 19:01:35.790595999 +0100
+++ NetworkManager-vpnc-0.8.1-old/src/nm-vpnc-service.h	2011-02-16 20:16:27.128003532 +0100
@@ -54,7 +54,6 @@
 #define NM_VPNC_KEY_NAT_TRAVERSAL_MODE "NAT Traversal Mode"
 #define NM_VPNC_KEY_DPD_IDLE_TIMEOUT "DPD idle timeout (our side)"
 #define NM_VPNC_KEY_CISCO_UDP_ENCAPS_PORT "Cisco UDP Encapsulation Port"
-#define NM_VPNC_KEY_LOCAL_PORT "Local Port"
 
 #define NM_VPNC_NATT_MODE_NATT        "natt"
 #define NM_VPNC_NATT_MODE_NONE        "none"

--- NetworkManager-vpnc-0.8.1/properties/tests/test-import-export.c	2011-02-16 19:01:04.277389575 +0100
+++ NetworkManager-vpnc-0.8.1-old/properties/tests/test-import-export.c	2011-02-16 20:16:27.121003272 +0100
@@ -95,8 +95,6 @@
 	{ NM_VPNC_KEY_NAT_TRAVERSAL_MODE,    NM_VPNC_NATT_MODE_CISCO },
 	{ NM_VPNC_KEY_DPD_IDLE_TIMEOUT,      "90" },
 	{ NM_VPNC_KEY_CISCO_UDP_ENCAPS_PORT, NULL },
-        { NM_VPNC_KEY_LOCAL_PORT,            "500" },
-
 	{ NULL, NULL }
 };
 

Attachment: NetworkManager-vpnc-0.8.1-1.fc14.x86_64.rpm
Description: application/rpm

Attachment: NetworkManager-vpnc-0.8.1-1.fc14.src.rpm
Description: application/rpm

Attachment: NetworkManager-vpnc-debuginfo-0.8.1-1.fc14.x86_64.rpm
Description: application/rpm



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]