mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-02-20 02:53:03 -05:00
Fix segmentation fault on EAP-TTLS phase 2 EAP method init failure
This is based on a patch and report by Masashi Honma <honma@ictec.co.jp>. The issue is more generic than just TNC, though, since failure to initialize any phase 2 EAP method can result in NULL dereference.
This commit is contained in:
parent
0d308bc074
commit
99bff8430f
@ -954,7 +954,7 @@ static int eap_ttls_phase2_eap_init(struct eap_sm *sm,
|
||||
sm->init_phase2 = 1;
|
||||
data->phase2_priv = data->phase2_method->init(sm);
|
||||
sm->init_phase2 = 0;
|
||||
return 0;
|
||||
return data->phase2_priv == NULL ? -1 : 0;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user