Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Gert Doering
Hi, On Fri, Mar 05, 2010 at 10:52:53AM -0600, Karl O. Pinc wrote: > > open() first will exclusively lock it for you... > > From OpenBSD's tun(4) man page: > > Each device has the exclusive open property; it cannot be > opened if it is > already open and in use by another process.

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Karl O. Pinc
On 03/05/2010 10:39:26 AM, Gert Doering wrote: > Hi, > > On Fri, Mar 05, 2010 at 11:44:28AM +0100, Heiko Hund wrote: > > On Friday 05 March 2010 10:11:51 Gert Doering wrote: > > > What happened exactly? Could you ask your colleague for a log > file? > > > > Well, he couldn't ping any remote host

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Gert Doering
Hi, On Fri, Mar 05, 2010 at 11:44:28AM +0100, Heiko Hund wrote: > On Friday 05 March 2010 10:11:51 Gert Doering wrote: > > What happened exactly? Could you ask your colleague for a log file? > > Well, he couldn't ping any remote host. Nothing special in the log, really. > If > it isn't mislead

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Heiko Hund
Hi Gert, On Friday 05 March 2010 10:11:51 Gert Doering wrote: > What happened exactly? Could you ask your colleague for a log file? Well, he couldn't ping any remote host. Nothing special in the log, really. If it isn't misleading it's quite obvious that the ordering is wrong: TUN/TAP device

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Gert Doering
Hi, On Fri, Mar 05, 2010 at 09:42:23AM +0100, Heiko Hund wrote: > On Sunday 28 February 2010 15:50:01 Gert Doering wrote: > > Now, for all operatings systems *except* Win32 and OpenBSD, the sequence > > of execution is > > > > open_tun() > > do_ifconfig() > > That seems to make sense for OpenB

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-05 Thread Heiko Hund
Hi Gert, On Sunday 28 February 2010 15:50:01 Gert Doering wrote: > Now, for all operatings systems *except* Win32 and OpenBSD, the sequence > of execution is > > open_tun() > do_ifconfig() That seems to make sense for OpenBSD. I just had a colleague (kudos Moritz) try to connect with ifconfig

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-01 Thread Karl O. Pinc
On 03/01/2010 01:54:46 AM, Gert Doering wrote: > Hi, > > On Sun, Feb 28, 2010 at 10:13:10PM -0600, Karl O. Pinc wrote: > > So, you should not need to do the ifconfig at all unless you're > > interested in tap functionality or there's other odd > > frobbing going on. > > You need ifconfig to set a

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-01 Thread Gert Doering
Hi, On Sun, Feb 28, 2010 at 10:13:10PM -0600, Karl O. Pinc wrote: > So, you should not need to do the ifconfig at all unless you're > interested in tap functionality or there's other odd > frobbing going on. You need ifconfig to set an IP address :-) - which might be considered "odd frobbing", bu

Re: [Openvpn-devel] special-case code for OpenBSD - advice needed

2010-03-01 Thread Karl O. Pinc
On 02/28/2010 08:50:01 AM, Gert Doering wrote: > Hi, > > while working on "make IPv6 payload work on Win32", I found something > quite peculiar for OpenBSD in the OpenVPN code. > > Now, for all operatings systems *except* Win32 and OpenBSD, the > sequence > of execution is > > open_tun() > d

[Openvpn-devel] special-case code for OpenBSD - advice needed

2010-02-28 Thread Gert Doering
Hi, while working on "make IPv6 payload work on Win32", I found something quite peculiar for OpenBSD in the OpenVPN code. In "init.c", do_open_tun(), calls two other functions from tun.c for tunnel setup: open_tun() --> find free /dev/tun device, open() it, thereby activating a