[pkg-wpa-devel] Bug#471858: Bug#471858: wpasupplicant: option "wpa_iface" half works - but does IP config on the wpa_iface not the actual interface (normally a bridge)

Paul Hedderly paul at mjr.org
Fri Mar 21 13:08:13 UTC 2008


Kel Modderman wrote:
>> I'm sure it is possible :O)
>>     
>
> Yes i think its a bit crazy, and yes everything is possible ;-)
>
> Whether or not its worth too much hassle I dunno.
>   
>   
Actually it looks very easy... this works :O)

Seems IFACE is set to the right interface. This would need to be changed
in ifdown and ifcheckstate too.

Would be better to put in a check that IFACE was set and use WPA_IFACE
if not.


--- /etc/wpa_supplicant/functions.sh.orig       2008-03-21
13:04:52.000000000 +0000
+++ /etc/wpa_supplicant/functions.sh    2008-03-21 13:05:16.000000000 +0000
@@ -967,13 +967,13 @@
        if [ -n "$WPA_LOGICAL_IFACE" ]; then
                if egrep --quiet
"^iface[[:space:]]+${WPA_LOGICAL_IFACE}[[:space:]]+inet"
"$INTERFACES_FILE"; then

-                       echo "ifup $WPA_IFACE=$WPA_LOGICAL_IFACE"
+                       echo "ifup $IFACE=$WPA_LOGICAL_IFACE"

-                       if grep --quiet "^$WPA_IFACE=$WPA_IFACE"
"$IFSTATE_FILE"; then
+                       if grep --quiet "^$IFACE=$IFACE"
"$IFSTATE_FILE"; then
                                # Force settings over the unconfigured
"master" IFACE
-                               /sbin/ifup --force
"$WPA_IFACE=$WPA_LOGICAL_IFACE"
+                               /sbin/ifup --force
"$IFACE=$WPA_LOGICAL_IFACE"
                        else
-                               /sbin/ifup "$WPA_IFACE=$WPA_LOGICAL_IFACE"
+                               /sbin/ifup "$IFACE=$WPA_LOGICAL_IFACE"
                        fi
                else
                        echo "No network defined for
\"$WPA_LOGICAL_IFACE\" in \"$INTERFACES_FILE\""



Any thoughts?
It works just as I wanted, but am I barking up the wrong tree?

--
Paul




More information about the Pkg-wpa-devel mailing list