Accouting-Stop Packet sends MAC instead of User-Name in 0.2.0
gbur at local-web.net
gbur
Sat Jan 17 00:00:49 PST 2004
Hello,
I'm using hostap with 802.1x enabled and a freeradius server.
Everything works fine. But the freeradius server doesn't accept the
accouting requests (stop packets) when a client goes offline (for
example idle timeout). The problem is that hostap sends accouting stop
packets with the mac-address instead of the user-name in the
radius-attribute user-name.
I think i found the bug in hostapd. The function ieee802_1x_free_sta()
is called a bit to often. This function frees all internal structures -
the user name to (sta->identity). As a fallback the mac-address will be
send.
I think the calls of ieee802_1x_free_sta() in handle_disassoc() and
handle_deauth() are to much. ieee802_1x_free_sta() is called in
ap_free_sta() after accouting-stop is send. Next problem: Radius is udp
- if the radius-server didn't ack the packet hostap will retransmit the
packet. But in this case ieee802_1x_free_sta() is called and
sta->identity is freed.
In older versions of hostap (eg. 0.0.4) ieee802_1x_free_sta() isn't
called in handle_disassoc() and handle_deauth().
regards
Gunter Burchardt
More information about the Hostap
mailing list