mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-02-10 16:57:00 +08:00
receive SM_CMD_AUTH_BAN_IP_REPLY asynchronously to prevent race conditions
This commit is contained in:
@@ -317,6 +317,22 @@ int process_packet_from_main(void *pool, int cfd, sec_mod_st * sec, cmd_request_
|
||||
data.size = buffer_size;
|
||||
|
||||
switch (cmd) {
|
||||
case SM_CMD_AUTH_BAN_IP_REPLY:{
|
||||
BanIpReplyMsg *msg = NULL;
|
||||
|
||||
msg =
|
||||
ban_ip_reply_msg__unpack(&pa, data.size,
|
||||
data.data);
|
||||
if (msg == NULL) {
|
||||
seclog(sec, LOG_INFO, "error unpacking auth ban ip reply\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
handle_sec_auth_ban_ip_reply(cfd, sec, msg);
|
||||
ban_ip_reply_msg__free_unpacked(msg, &pa);
|
||||
|
||||
return 0;
|
||||
}
|
||||
case SM_CMD_AUTH_SESSION_OPEN:
|
||||
case SM_CMD_AUTH_SESSION_CLOSE:{
|
||||
SecAuthSessionMsg *msg;
|
||||
|
||||
Reference in New Issue
Block a user