Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Cisco VPN Client
View unanswered posts
View posts from last 24 hours

Goto page 1, 2, 3  Next  
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
jon.d@c2internet.net
n00b
n00b


Joined: 16 Feb 2004
Posts: 1
Location: Cheshire, England

PostPosted: Mon Feb 16, 2004 1:03 pm    Post subject: Cisco VPN Client Reply with quote

Hi

Has anyone managed to get the Cisco VPN Client 4.0.3.B-k9 working on kernel 2.6.1?

Kind Regards

Jonathan C2
Back to top
View user's profile Send private message
mikjik
n00b
n00b


Joined: 03 Aug 2003
Posts: 19
Location: Left Coast, USA

PostPosted: Mon Feb 16, 2004 5:39 pm    Post subject: Reply with quote

.
Yes, I got it working on kernel 2.6.0 and 2.6.1. But it broke when I went to 2.6.2. I dropped back to 2.6.1 and it works again.

When Googling the topic, I'm learned that it's not a Gentoo issue per se, but something in 2.6.2.

If someone knows how to make it work on 2.6.2+, let me know! :wink:

-MJ

.
Back to top
View user's profile Send private message
cpdsaorg
Guru
Guru


Joined: 16 Oct 2003
Posts: 359

PostPosted: Thu Feb 19, 2004 9:19 pm    Post subject: Reply with quote

is this working on 2.6.3??
Back to top
View user's profile Send private message
hanzotutu
Apprentice
Apprentice


Joined: 10 Apr 2003
Posts: 170

PostPosted: Thu Feb 19, 2004 11:45 pm    Post subject: Reply with quote

oops, my cisco-vpnclient-3des-4.0.3b-r2 works

Code:

scimd files # /etc/init.d/vpnclient start
 * Starting Cisco VPN Client...                                           [ ok ]
scimd files # lsmod
Module                  Size  Used by
cisco_ipsec           391884  -
fglrx                 197348  -
...
scimd files # vpnclient
Cisco Systems VPN Client Version 4.0.3 (B)
Copyright (C) 1998-2003 Cisco Systems, Inc. All Rights Reserved.
Client Type(s): Linux
Running on: Linux 2.6.2-gentoo #2 Sun Feb 8 13:18:58 PST 2004 i686
Back to top
View user's profile Send private message
sigSEGV2003
Tux's lil' helper
Tux's lil' helper


Joined: 11 Mar 2003
Posts: 81
Location: Kansas

PostPosted: Fri Feb 20, 2004 4:29 am    Post subject: Reply with quote

I had it working on 2.6.0-2.6.2, but for some reason DNS resolution wouldn't work. Might have been a UDP only problem. I can't get it do anything but lock up my box with 2.6.3. If I have time, I'll open a TAC case with Cisco tomorrow and see 1) are they going to support 2.6 anytime soon and 2) who should fix this, kernel team or Cisco.
Back to top
View user's profile Send private message
mikjik
n00b
n00b


Joined: 03 Aug 2003
Posts: 19
Location: Left Coast, USA

PostPosted: Sat Feb 21, 2004 10:46 pm    Post subject: Reply with quote

.
So what you doing in 2.6.2+ that I'm not doing? I had it working fine in 2.6.0/1, but it broke for me in 2.6.2/3. I used the same .config file across my kernel builds.

I can do a /etc/init.d/vpnclient start just fine and the module loads, but when I go to connect, it hangs. I'm never prompted for my username and password.

I've tweaked my kernel config to death trying to shake it loose.

-mikjik
.
Back to top
View user's profile Send private message
zeky
Guru
Guru


Joined: 24 Feb 2003
Posts: 470
Location: Vukojebina, Europe

PostPosted: Sun Feb 22, 2004 5:42 pm    Post subject: Reply with quote

cpdsaorg wrote:
is this working on 2.6.3??


Not for me :(

Does anyone have a solution?
_________________
Beat your dick like it owes you money
Back to top
View user's profile Send private message
leszcz
n00b
n00b


Joined: 03 Feb 2004
Posts: 20

PostPosted: Mon Feb 23, 2004 9:40 am    Post subject: Reply with quote

Found on google :

http://tinyurl.com/2uaa8

I haven't tried it yet.
Back to top
View user's profile Send private message
Berni
n00b
n00b


Joined: 25 Aug 2003
Posts: 71

PostPosted: Mon Feb 23, 2004 4:54 pm    Post subject: Reply with quote

I have the exact same problem with "/etc/init.d/vpnclient start" working properly but "vpnclient connect" locking up the pc...I'm currently using gentoo-dev-sources 2.6.3_r1 and got everything else working fine on my notebook (stage1-install on a 450Mhz PIII rocks :lol:) .
Did anyone try the "solution" linked by leszcz? I didn't understand what to do exactly (I'm german and didn't really understand what Pa6trick Toal said in this mailing list...) but if someone could tell me what to do I could try it...
Back to top
View user's profile Send private message
leszcz
n00b
n00b


Joined: 03 Feb 2004
Posts: 20

PostPosted: Mon Feb 23, 2004 6:54 pm    Post subject: Reply with quote

OK, I can confirm that solution found on google actually works for me (kernel 2.6.3).
What you have to do is to _reverse_ patch attached by Patric Toal :

net/core/dev.c

@@ -946,11 +996,29 @@
* The notifier passed is linked into the kernel structures and must
* not be reused until it has been unregistered. A negative errno code
* is returned on a failure.
+ *
+ * When registered all registration and up events are replayed
+ * to the new notifier to allow device to have a race free
+ * view of the network device list.
*/

int register_netdevice_notifier(struct notifier_block *nb)
{
- return notifier_chain_register(&netdev_chain, nb);
+ struct net_device *dev;
+ int err;
+
+ rtnl_lock();
+ err = notifier_chain_register(&netdev_chain, nb);
+ if (!err) {
+ for (dev = dev_base; dev; dev = dev->next) {
+ nb->notifier_call(nb, NETDEV_REGISTER, dev);
+
+ if (dev->flags & IFF_UP)
+ nb->notifier_call(nb, NETDEV_UP, dev);
+ }
+ }
+ rtnl_unlock();
+ return err;
}

/**

so my dev.c now is :

* Register a notifier to be called when network device events occur.
* The notifier passed is linked into the kernel structures and must
* not be reused until it has been unregistered. A negative errno code
* is returned on a failure.
*/

int register_netdevice_notifier(struct notifier_block *nb)
{
return notifier_chain_register(&netdev_chain, nb);
}


WARNING : I am completly unaware how this change affects kernel functionality.
Back to top
View user's profile Send private message
Berni
n00b
n00b


Joined: 25 Aug 2003
Posts: 71

PostPosted: Mon Feb 23, 2004 8:41 pm    Post subject: Reply with quote

Thanks a lot! It works perfectly now and i didn't experience any drawbacks from this change yet.

I have a rather offtopic-question and would be glad if someone could help me:
The vpn-connection shall be started automatically by a shell script. However, this doesn't work fully automatically because of the following:
Code:
bash# vpnclient connect internet
Cisco Systems VPN Client Version 4.0.3 (B)
Copyright (C) 1998-2003 Cisco Systems, Inc. All Rights Reserved.
Client Type(s): Linux
Running on: Linux 2.6.3-gentoo-r1 #9 SMP Mon Feb 23 21:09:18 CET 2004 i686

Initializing the VPN connection.
Contacting the gateway at xxxxxxxxxx
Authenticating user.
Negotiating security policies.
Securing communication channel.
Internet connection ready to use.
Do you wish to continue? (y/n):

Isn't it possible to automatically answer this question with "y" or something like that? I did not find an option for that in the profile-file...
Back to top
View user's profile Send private message
joemc91
n00b
n00b


Joined: 04 Feb 2004
Posts: 38

PostPosted: Thu Feb 26, 2004 5:27 pm    Post subject: Reply with quote

Thanks so much for the post. This fix worked for the ck-2.6.1 source too.
Back to top
View user's profile Send private message
rcast
n00b
n00b


Joined: 22 Apr 2003
Posts: 39

PostPosted: Mon Mar 01, 2004 11:06 am    Post subject: Reply with quote

Hello,

Just read an article which had a patch to the cisco client instead of the linux kernel and thought it may be of some use:

http://marc.theaimsgroup.com/?l=linux-kernel&m=107765601402527&w=2

Rene
Back to top
View user's profile Send private message
wwc210
n00b
n00b


Joined: 06 Mar 2004
Posts: 5

PostPosted: Tue Mar 09, 2004 2:49 pm    Post subject: Applying Patches Reply with quote

What is the kernel or the cisco client supposed to look like at the end of the process? I have the 2.6.3 kernel. Can someone tell me how to apply the patch to either the kernel or the cisco client?
Back to top
View user's profile Send private message
Berni
n00b
n00b


Joined: 25 Aug 2003
Posts: 71

PostPosted: Tue Mar 09, 2004 3:28 pm    Post subject: Reply with quote

I have patched the kernel and I think that leszcz described it quite good. Open your net/core/dev.c file and search for "int register_netdevice_notifier(struct notifier_block *nb)". Then just delete these lines (alternatively you could also use a diff-file, but editing the file directly is better/easier/safer here I think...)
Code:
struct net_device *dev;
int err;
rtnl_lock();
err = notifier_chain_register(&netdev_chain, nb);
if (!err) {
for (dev = dev_base; dev; dev = dev->next) {
nb->notifier_call(nb, NETDEV_REGISTER, dev);
if (dev->flags & IFF_UP)
nb->notifier_call(nb, NETDEV_UP, dev);
}
}
rtnl_unlock();
return err;

and add this one instead
Code:
return notifier_chain_register(&netdev_chain, nb);

Rebuild your kernel and the Cisco Client works just fine :D

-------------------------------------------------------------------------

The other alternative is what is mentioned in rcasts post. Copy the code
Code:
diff -u --recursive vpnclient/interceptor.c vpnclient-new/interceptor.c
--- vpnclient/interceptor.c   2003-10-30 02:27:34.000000000 +0100
+++ vpnclient-new/interceptor.c   2004-02-24 21:26:36.000000000 +0100
@@ -364,11 +364,6 @@
         error = VPNIFUP_FAILURE;
         goto error_exit;
     }
-    error = register_netdevice_notifier(&interceptor_notifier);
-    if (error)
-    {
-        goto error_exit;
-    }
 
     vpn_is_up = TRUE;
     return error;
@@ -388,8 +383,6 @@
 {
     int i;
 
-    unregister_netdevice_notifier(&interceptor_notifier);
-
     cleanup_frag_queue();
     /*restore IP packet handler */
     if (original_ip_handler.pt != NULL)
@@ -436,6 +429,9 @@
 {
     struct net_device *dev = (struct net_device *) val;
 
+    if (!vpn_is_up)
+   return 1;
+
     switch (event)
     {
     case NETDEV_REGISTER:
@@ -853,6 +849,8 @@
         CNICallbackTable = *PCNICallbackTable;
         CniPluginDeviceCreated();
 
+        register_netdevice_notifier(&interceptor_notifier);
+
         if ((status = register_netdev(&interceptor_dev)) != 0)
         {
             printk(KERN_INFO "%s: error %d registering device \"%s\".\n",
@@ -876,6 +874,9 @@
     CniPluginUnload();
 
     unregister_netdev(&interceptor_dev);
+
+    unregister_netdevice_notifier(&interceptor_notifier);
+
     return;
 }

into a diff-file and apply the diff to your CISCO-VPN-Client-Sources (note: for changes to take effect, you have to copy the newly created file vpnclient-new/interceptor.c to vpnclient/interceptor.c and you should backup your old vpnclient/interceptor.c!). After recompiling the Cisco VPN Client, this should also work, but i didn't try this on my own as the first patch worked just fine.
There's also a already patched version available here http://www.anomalistic.org/vpnclient/vpnclient-linux-4.0.3.B-k9.tar.gz which includes also some other cleanups for Debian installation but it should also work with gentoo I think!
However, patches to kernel files should be avoided whenever it is possible and so technically, the second solution is a lot better and I would recommend to try patching the CISCO-Client first and only patch the kernel if it didn't work!
Back to top
View user's profile Send private message
ponds
n00b
n00b


Joined: 06 Oct 2003
Posts: 69
Location: MSU, Starkville, MS

PostPosted: Tue Mar 09, 2004 5:44 pm    Post subject: Reply with quote

Does anyone know if there is a way to get the new version other than through your VPN provider? I know that portage used make you fetch it manually from their site, and I assume it still does (I am computerless at the moment, waiting for ibm to ship my new laptop).

My university requires VPN client, and has some old version (like 3.2 or something), which definately does not work with 2.6, and getting them to get the new version for us is going to be an uphill battle.
Back to top
View user's profile Send private message
denniruz
n00b
n00b


Joined: 04 Mar 2004
Posts: 7
Location: Buffalo, NY

PostPosted: Tue Mar 09, 2004 5:52 pm    Post subject: Damn interactive startups-- Reply with quote

When I have something interactive that I need to start, I use a perl script and the expect perl module to do it-- It's not an elegant solution, but it works.
--Dennis

Berni wrote:

I have a rather offtopic-question and would be glad if someone could help me:
The vpn-connection shall be started automatically by a shell script. However, this doesn't work fully automatically because of the following:
Code:
bash# vpnclient connect internet
Cisco Systems VPN Client Version 4.0.3 (B)
Copyright (C) 1998-2003 Cisco Systems, Inc. All Rights Reserved.
Client Type(s): Linux
Running on: Linux 2.6.3-gentoo-r1 #9 SMP Mon Feb 23 21:09:18 CET 2004 i686

Initializing the VPN connection.
Contacting the gateway at xxxxxxxxxx
Authenticating user.
Negotiating security policies.
Securing communication channel.
Internet connection ready to use.
Do you wish to continue? (y/n):

Isn't it possible to automatically answer this question with "y" or something like that? I did not find an option for that in the profile-file...
Back to top
View user's profile Send private message
Berni
n00b
n00b


Joined: 25 Aug 2003
Posts: 71

PostPosted: Tue Mar 09, 2004 6:58 pm    Post subject: Reply with quote

Yeah thanks. I already figured that out (but I'm just using "normal" expect and not the perl expect). My script to answer looks like that
Code:
#!/usr/bin/expect
# \
timeout -1
spawn vpnclient connect wlan
expect "(y/n):"
send "y\n"
wait
expect "Your VPN connection has been terminated."
exit 0
Back to top
View user's profile Send private message
denniruz
n00b
n00b


Joined: 04 Mar 2004
Posts: 7
Location: Buffalo, NY

PostPosted: Tue Mar 09, 2004 7:56 pm    Post subject: Reply with quote

hehe-- Slick. Thanks for the info.

Berni wrote:
Yeah thanks. I already figured that out (but I'm just using "normal" expect and not the perl expect). My script to answer looks like that
Code:
#!/usr/bin/expect
# \
timeout -1
spawn vpnclient connect wlan
expect "(y/n):"
send "y\n"
wait
expect "Your VPN connection has been terminated."
exit 0
Back to top
View user's profile Send private message
tbender
n00b
n00b


Joined: 10 Mar 2004
Posts: 11

PostPosted: Wed Mar 10, 2004 6:37 pm    Post subject: Reply with quote

Hi

I downloaded and compiled ( on my linux2.6.3-system) the modiefied vpn-client( which was linked above). This new client, now does not lock my comp and i can connect normally to the vpn-gateway... It seems, that i can do everything normal, EXCEPT of dns-resolution!

The second solution posted, has the same problems....

Has anybody made similar experiences?

Thanx in advance,
Tobias.
Back to top
View user's profile Send private message
joyman
n00b
n00b


Joined: 24 Jan 2004
Posts: 1

PostPosted: Sun Mar 14, 2004 1:51 pm    Post subject: Patch works Reply with quote

I can confirm that the patch-version mentioned as second solution from Berni works for me (I didn't download the patched vpn-client-file, but ran the patch myself). I used a kernel 2.6.4-rc1.

I didn't have any problems with DNS-Resolution so far.

Try it again with that one. If you need more details please ask.
Back to top
View user's profile Send private message
synack1337
n00b
n00b


Joined: 17 Mar 2004
Posts: 5

PostPosted: Wed Mar 17, 2004 6:53 am    Post subject: re: vpnclient + patch +2.6.4 +dns Reply with quote

I emerged the -r3 ebuild for the cisco vpn client and it works great w/ gentoo-dev sources for 2.6.4....except for dns resolution.

i am able to ping/ssh/http to devices across the tunnel, but dns does not work. This includes direct dig/nslookup against the servers. The correct servers are listed in resolv.conf.

other udp traffic doesnt appear to work either (snmp queries)

i've verified that my traffic is reaching the other side, but its not coming back to me. I will do more reserach on this. my windows client works fine.

if anyone has any info, please contribute.
Back to top
View user's profile Send private message
synack1337
n00b
n00b


Joined: 17 Mar 2004
Posts: 5

PostPosted: Wed Mar 17, 2004 10:49 pm    Post subject: more broken dns Reply with quote

so check this out;

I was doing some snoops on the destination dns server. As I was looking through the packet details of my captured dns query, I see that the UDP checksum was incorrect.

I stepped back to the egress port of the last firewall the packets cross before hitting the dns server and did a capture, and again, incorrect udp checksum.

I took another step back and captured on the ingress port of this firewall, and again, incorrect udp checksum.

To eliminate the vpn tunnel, i did a local dns query w/ my local dns server and guess what...incorrect udp checksum. But I at least got a response from my query. (local dns server is a windows box, dns server across vpn is solaris/bind)

Is it a dns thing? I did a snmpwalk...and again incorrect udp checksum.

so either ethereal/libpcap has problems capturing udp packets, or something is broke elsewhere.

2.6.4-gentoo
libpcap 0.8
ethereal 10.2
3c59x.0

I'm not sure where I'm going to head next. I did some captures of a dnsquery on my windows box w/ winpcap 3.0 and ethereal 10.2 and the udp checksum is valid. Is this a known bug? maybe its cosmetic and there is something else wrong. not sure, but i'll poke around the libpcap/ethereal site.

if you have any suggestions, lets hear'em
Back to top
View user's profile Send private message
synack1337
n00b
n00b


Joined: 17 Mar 2004
Posts: 5

PostPosted: Thu Mar 18, 2004 2:39 am    Post subject: i just can't leave this alone Reply with quote

the goal is to keep finding stuff out till someone just posts and tells me what the specific problem is :) (and how to fix it)

so, 2.4.22-r7's udp packets pass checksum. same ver of all other utils.
this also means that dns worked for me across the tunnel (read as: the dns server accepted the packets becuase the had a correct checksum)

2.6.5-rc1 does not. (i thoguht it was worth a shot with all those network driver udpates )

so, something broke in 2.6.4+ w/ the net drivers/stack it seems. I'm guessing here, but what else is there?
Back to top
View user's profile Send private message
d33k
n00b
n00b


Joined: 11 Aug 2003
Posts: 13
Location: Jersey

PostPosted: Tue Mar 30, 2004 2:27 am    Post subject: Reply with quote

Any update snizack?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum