From cf6d78208fa9bff3fb2714f20baf164bfe639e4b Mon Sep 17 00:00:00 2001 From: boris Date: Fri, 29 Aug 2014 08:27:30 +0000 Subject: [PATCH] Appends a representation of the system time to the generated ufrag-s, in order to decrease the chance of local collisions. --- src/org/ice4j/ice/Agent.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/org/ice4j/ice/Agent.java b/src/org/ice4j/ice/Agent.java index 990a668..009628c 100644 --- a/src/org/ice4j/ice/Agent.java +++ b/src/org/ice4j/ice/Agent.java @@ -273,7 +273,9 @@ public class Agent ufrag = ensureIceAttributeLength( - new BigInteger(24, random).toString(32), + new BigInteger(24, random).toString(32) + + BigInteger.valueOf( + System.currentTimeMillis()).toString(32), /* min */ 4, /* max */ 256); password = ensureIceAttributeLength(