Ted Unangst wrote:
> On Wed, Oct 26, 2011, Han Boetes wrote:
> > I have this nice password generator which I use on my work, mostly
> > linux based:
> >
> > < /dev/urandom tr -dc "[:graph:]" | head -c 12; echo
> >
> > Of course this isn't portable so I rewrote it to:
> >
> > < /dev/arandom tr -dc "[:graph:]" | iconv -c -t ASCII | dd count=1 bs=12
> > 2> /dev/null; echo
> >
> > Now you may look at it and wonder what's the 'iconv -c -t ASCII |'
> > is doing in there. If you remove it you'll notice weird characters
> > slipping through.
>
> Actually, I don't.  Do you have an example of a weird character being
> let through?

Here it is:

I redirected the output -- without iconv -- to "file" a few times
and then ran:

  uuencode -o file2 file output

And added it here:

[demime removed a uuencoded section named output which was 5 lines]


# Han

Reply via email to