[PATCH 1/1] P2PS: Fix attribute addition in p2p_buf_add_service_instance()

Jouni Malinen j at w1.fi
Sat Jun 27 17:15:07 EDT 2015


On Tue, Jun 23, 2015 at 01:47:59PM +0000, Stepanov, Max wrote:
> Fix a condition when Advertised Service Info Attribute is added to
> a probe response in p2p_buf_add_service_instance(). The issue is
> that a 'found' value is increased even if 'test' and 'adv->hash' hashes
> are different. As result 'found' may have a non-zero value when an
> attribute data length is 0. In this cause an empty attribute is about to
> be added. Fixing it by eliminating 'found' and checking 'total_len'
> containing a real number of bytes added to Advertised Service Info
> Attribute.

Thanks, applied.
 
-- 
Jouni Malinen                                            PGP id EFC895FA


More information about the HostAP mailing list