Skip to content
Snippets Groups Projects
Commit 3c776c9c authored by Sébastien Le Stum's avatar Sébastien Le Stum Committed by Adrien Béraud
Browse files

ice_transport: add sscanf safeguards on string parsing

Ensure that there won't be buffer overflows by enforcing the maximum
size for each string read.

Change-Id: I662d46c4c22ca2784a5518fb46a1023cad09256e
parent 8b381d89
Branches
No related tags found
No related merge requests found
......@@ -1308,7 +1308,7 @@ IceTransport::getCandidateFromSDP(const std::string& line, IceCandidate& cand) c
pj_bool_t is_tcp = PJ_FALSE;
cnt = sscanf(line.c_str(),
"%s %d %s %d %s %d typ %s tcptype %s\n",
"%31s %d %11s %d %79s %d typ %31s tcptype %31s\n",
foundation,
&comp_id,
transport,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment