From owner-freebsd-questions@freebsd.org Sat Aug 26 13:52:36 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F0352DF6DBE for ; Sat, 26 Aug 2017 13:52:36 +0000 (UTC) (envelope-from carlopmart@gmail.com) Received: from mail-lf0-x229.google.com (mail-lf0-x229.google.com [IPv6:2a00:1450:4010:c07::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 70DF16CA02 for ; Sat, 26 Aug 2017 13:52:36 +0000 (UTC) (envelope-from carlopmart@gmail.com) Received: by mail-lf0-x229.google.com with SMTP id z12so4869218lfd.3 for ; Sat, 26 Aug 2017 06:52:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:subject:message-id:mime-version:content-disposition :user-agent; bh=L+Jf4VdXS8A+eHlAn0ixcc7ejd+3YJnSge6J6wN5f0I=; b=oaMbhE+zoF2Q5wZXI//bCgf7natbfU3vrPLhCXuWM2Zdun1KKZriw1Ypd/vWwtKRgJ hvwmt/vBU3bk2jf+Z0rsKizdgjn9TEpIriYa8u3cep2OHjjh6hede76uyCtyrnY9D2X8 Qdg/kDmgAMPbc4hU+GYOfDEpPl3wdS59+hsnOQBFQtFqxmi49lm1m0pioelmAiPa/pz4 yGpBOp9Po+uQ4Xc4O1NUivT1YpCWNQlBTQaGWv6Ct6N7oeq1RLZY0nAEQPBCGrszbwcd nLCHeEBIomuGp5JUxUVyLef0jpgfubh4N7EkdndyEqb6DmHlk/aJtdpUGjKX74wL3zOD mnjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:subject:message-id:mime-version :content-disposition:user-agent; bh=L+Jf4VdXS8A+eHlAn0ixcc7ejd+3YJnSge6J6wN5f0I=; b=DVD44xw3GpMmU74RFN4jTHRDHnuSeFSzGzvbMaJVpVX0dFI12lqzUzTKfK4TxsMswO IFsAWbOK3MSUDU2juxvG55a9du0joTe7nj1b1A5geSaxbR35UDpzVO8vzSd4Oh7bhbZK WmD4dFWPaOZi3pxYfjfMDZaYMoNdugwsad4mrb4t8Qvf1liHFWe8x09LucgnBFrx3Tb6 8Wm1ZwuR5ttS5z7NpOuIHIOhb+MIiJVxcsASi413sWCviILwzPID2BNQNOmDhPsnGhTx U6SBZcGCdLwAkKqp2G0TVCej5+WOu9G5DLcO+gLiR4SwE5bWLBS4BqLY+CO08tmBLhZE 4R6g== X-Gm-Message-State: AHYfb5jaL58t2iwJCUVet/Wl+e/8DRuUtz8lZFIOv46/bBhbU9IkPNBp ewmtRCFO4EY3Zv5J/y4= X-Received: by 10.46.77.208 with SMTP id c77mr876557ljd.92.1503755554439; Sat, 26 Aug 2017 06:52:34 -0700 (PDT) Received: from localhost ([185.86.10.202]) by smtp.gmail.com with ESMTPSA id n127sm1525337lfn.10.2017.08.26.06.52.33 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 26 Aug 2017 06:52:33 -0700 (PDT) Date: Sat, 26 Aug 2017 13:24:04 +0000 From: "C. L. Martinez" To: freebsd-questions@freebsd.org Subject: Scripting wifi connections Message-ID: <20170826132404.mpvknkgxl26t5c43@tesla.lab.uxdom.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline User-Agent: NeoMutt/20170609 (1.8.3) X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Aug 2017 13:52:37 -0000 Hi all, Sometimes I need to use two wifi connections at the same time. Actually, my FreeBSD laptop is configured to use source routing (via setfib+pf rules) to accomplish this. But I need more flexibility: choose how many connections to use, setup a wpa_spplicant.conf's file "on the fly", etc. My current config in rc.conf is: dhclient_fib="1" wlans_ath0="wlan0" wlans_urtwn0="wlan1" ifconfig_wlan0="country ES WPA SYNCDHCP fib 1 group egress" As you can see, I can only have one wlan interface properly configured. And my idea is to build a script to setup configurations "on the fly". Any tip or idea? Thanks. -- Greetings, C. L. Martinez