Partial implementation of Random#bytes