<p>Holger Freyther <strong>uploaded patch set #3</strong> to this change.</p><p><a href="https://gerrit.osmocom.org/10098">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">Move from libc random() to osmo_get_rand_id (2nd attempt)<br><br>When starting multiple mobile in the same second, the libc random number<br>generator will be seeded to exactly the same value.<br><br>The random bits inside the RACH request(s) will be exactly the same<br>across multiple mobile and when the channel fails they all pick the same<br>randomized back-off timing.<br><br>Use stronger random numbers and replace all calls to random(2) with<br>osmo_get_rand_id. Add a fallback to try random().<br><br>[v2: Add helper to make sure the result is int and between 0 and<br>RAND_MAX]<br><br>Change-Id: Icdd4be88c62bba1e9d954568e48f0c12a67ac182<br>---<br>M src/host/layer23/include/osmocom/bb/common/Makefile.am<br>A src/host/layer23/include/osmocom/bb/common/utils.h<br>M src/host/layer23/src/common/Makefile.am<br>A src/host/layer23/src/common/utils.c<br>M src/host/layer23/src/mobile/gsm322.c<br>M src/host/layer23/src/mobile/gsm48_mm.c<br>M src/host/layer23/src/mobile/gsm48_rr.c<br>M src/host/layer23/src/mobile/settings.c<br>8 files changed, 64 insertions(+), 7 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/98/10098/3</pre><p>To view, visit <a href="https://gerrit.osmocom.org/10098">change 10098</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/10098"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmocom-bb </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newpatchset </div>
<div style="display:none"> Gerrit-Change-Id: Icdd4be88c62bba1e9d954568e48f0c12a67ac182 </div>
<div style="display:none"> Gerrit-Change-Number: 10098 </div>
<div style="display:none"> Gerrit-PatchSet: 3 </div>
<div style="display:none"> Gerrit-Owner: Holger Freyther <holger@freyther.de> </div>
<div style="display:none"> Gerrit-Reviewer: Harald Welte <laforge@gnumonks.org> </div>
<div style="display:none"> Gerrit-Reviewer: Holger Freyther <holger@freyther.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-CC: Vadim Yanitskiy <axilirator@gmail.com> </div>