Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755712AbYGCS3Y (ORCPT ); Thu, 3 Jul 2008 14:29:24 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753293AbYGCS3O (ORCPT ); Thu, 3 Jul 2008 14:29:14 -0400 Received: from terminus.zytor.com ([198.137.202.10]:40559 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755258AbYGCS3N (ORCPT ); Thu, 3 Jul 2008 14:29:13 -0400 Message-ID: <486D1A66.6010006@zytor.com> Date: Thu, 03 Jul 2008 11:28:54 -0700 From: "H. Peter Anvin" User-Agent: Thunderbird 2.0.0.14 (X11/20080501) MIME-Version: 1.0 To: Jens-Michael Hoffmann CC: linux-kernel@vger.kernel.org Subject: Re: tcp/ip connect on demand References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 867 Lines: 23 Jens-Michael Hoffmann wrote: > hi, > > what is the right way to implement a "connect on demand" feature? > Example: user types url in firefox and presses return. Then > the system should set up network devices and proceed as usual. > > Is there a hook in the kernel we can use? In the kernel, no. Nor do you need one; the best place to hook into this is probably the name service system (so you catch it on trying to look up hostnames.) Alternatively, you can set up a bridge device which you can listen to via a tap device; when you see traffic, you bring up the real network and attach it to the bridge. -hpa -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/