[PATCH] P2P: Add IFNAME=iface command option for interface redirection

Dmitry Shmidt dimitrysh at google.com
Tue May 21 19:41:23 EDT 2013

On Tue, May 21, 2013 at 12:22 PM, Jouni Malinen <j at w1.fi> wrote:
> On Tue, May 21, 2013 at 11:48:16AM -0700, Dmitry Shmidt wrote:
>> You are right, raw command is working. I am going to prepare wpa_cli patch, if
>> you don't mind.
> Sure, go ahead.

Attached. However, commands are case-sensitive. We can probably force
argv[1] to be
upper case to make things easier.

>> It is possible that I am confused with control and monitor socket mix,
>> but it looks like in case of global we are using "same" socket. It will
>> be different socket descriptor, but it is literally connected to the same file.
>> wpa_ctrl_open() will connect control and monitor socket to same "named"
>> socket/file.
> On wpa_supplicant side, yes, it is the same socket. On the client side,
> it is not the same local end (e.g., see what wpa_ctrl_open() binds the
> socket to).
>> I see it is working, but isn't it a chance that we can mess control and event
>> messages?
> I don't see any issues with this.
>> Is there easy way to use different name sockets for global interface for
>> control and monitor?
> Why? Each connection to the global interface is uniquely identified by
> the server,client side ends of the connection. Having one of those
> (server) fixed does not make this any less unique pair. This is the
> design that has been used with the per-interface control interfaces for
> close to ten years now.. ;-) (Including what wifi.c does on Android
> today.)

I am sorry, it somehow reminds me days when ctrl_conn and mon_conn were
actually same socket. I don't know why I thought about it.

> --
> Jouni Malinen                                            PGP id EFC895FA
> _______________________________________________
> HostAP mailing list
> HostAP at lists.shmoo.com
> http://lists.shmoo.com/mailman/listinfo/hostap
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-wpa_cli-Add-ability-to-use-IFNAME-iface-prefix.patch
Type: application/octet-stream
Size: 811 bytes
Desc: not available
URL: <http://lists.shmoo.com/pipermail/hostap/attachments/20130521/8a389249/attachment.obj>

More information about the HostAP mailing list