changelog shortlog tags branches files raw gz bz2 help

Mercurial > hg > plan9front / changeset: wifi: ignore truncated tlv in beacon/probes

changeset 4238: 45002ea48d38
parent 4237: 5a10c0a49233
child 4239: a2f421c84c3a
author: cinap_lenrek@felloff.net
date: Fri, 30 Jan 2015 02:00:07 +0100
files: sys/src/9/pc/wifi.c
description: wifi: ignore truncated tlv in beacon/probes
     1.1--- a/sys/src/9/pc/wifi.c
     1.2+++ b/sys/src/9/pc/wifi.c
     1.3@@ -388,6 +388,8 @@ recvbeacon(Wifi *wifi, Wnode *wn, uchar 
     1.4 	for(e = d + len; d+2 <= e; d = x){
     1.5 		d += 2;
     1.6 		x = d + d[-1];
     1.7+		if(x > e)
     1.8+			break;	/* truncated */
     1.9 		t = d[-2];
    1.10 
    1.11 		/* skip double entries */