use rc_random_vector() to generate the ID in a request

Also fixes in handling of /dev/urandom and added support for
getentropy().