make random_password securely random

This is https://github.com/crowbar/barclamp-crowbar/pull/935 with the fix that makes it work.