correct group cipher setting

Jouni Malinen j
Mon Jan 12 10:58:57 PST 2009


On Mon, Jan 12, 2009 at 08:40:33PM +0200, Chuck Tuffli wrote:
> #3 fails with a parse error because my patch sets group_cipher to WPA_CIPHER_NONE which write_group() prints out as NONE. The trick here I guess is to set group_cipher to DEFAULT_GROUP in the case of an open network so that write_group() will skip printing out the group entry entirely.

The recommended practice for that is _not_ to set group_cipher yourself
and just rely on wpa_config_set_network_defaults() doing the correct
thing. I don't think you were calling that function in your code, but it
might be best to start with that and then update just the fields you
need to change. Not that this makes much difference for 0.5.x branch,
but in general, that would be the safest way to avoid hitting similar
issues with whatever new parameters are added in the future.

-- 
Jouni Malinen                                            PGP id EFC895FA



More information about the Hostap mailing list