Package: macchanger
Version: 1.5.0-3
Severity: normal

In main.c:177 I can see:

        srandom(time(NULL));

I have a script that calls macchanger on multiple interfaces with the
-A option. Whenever macchanger is called more than once in the same
second, the interfaces will have the same mac address, which is
extremely annoying.
  
Should be trivial to change, something like:

struct timeval tv;
gettimeofday(tv);

srandom(tv.tv_sec * tv.tv_usec * getpid());
   
should do the trick (+ corresponding changes in configure.ac).

Carlo


-- System Information:
Debian Release: squeeze/sid
  APT prefers testing
  APT policy: (1100, 'testing'), (500, 'unstable'), (500, 'stable')
Architecture: i386 (i686)

Kernel: Linux 2.6.30-1-686 (SMP w/2 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash

Versions of packages macchanger depends on:
ii  libc6                         2.9-25     GNU C Library: Shared libraries

macchanger recommends no packages.

macchanger suggests no packages.

-- no debconf information



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to