Received: from eggs.gnu.org ([2001:4830:134:3::10]:38842) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xbq86-0007Oz-2z for qemu-devel@nongnu.org; Wed, 08 Oct 2014 08:14:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xbq80-0005Jn-IH for qemu-devel@nongnu.org; Wed, 08 Oct 2014 08:14:05 -0400 Received: from mail-la0-x233.google.com ([2a00:1450:4010:c03::233]:56352) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xbq80-0005JY-42 for qemu-devel@nongnu.org; Wed, 08 Oct 2014 08:14:00 -0400 Received: by mail-la0-f51.google.com with SMTP id ge10so8214789lab.38 for ; Wed, 08 Oct 2014 05:13:58 -0700 (PDT) Received: from reftel-build.spotify.net ([80.239.169.202]) by mx.google.com with ESMTPSA id or5sm7634592lbb.42.2014.10.08.05.13.57 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 08 Oct 2014 05:13:57 -0700 (PDT) From: Magnus Reftel Date: Wed, 8 Oct 2014 14:13:53 +0200 Message-Id: <1412770434-6290-1-git-send-email-reftel@spotify.com> Subject: [Qemu-devel] [PATCH] Let user specify random seed for linux-user List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org linux-user uses the rand function for generating the value of the AT_RANDOM elf aux vector entry, and explicitly seeds the random number generator with the current time. This makes it impossible to reproduce runs that use the AT_RANDOM bytes. This patch adds a command line option and a matching environment variable for setting the random seed, so that the AT_RANDOM values can be predictable when the user chooses. The default is still to seed the random number generator with the current time.