method

random_bytes

random_bytes(p1)
public

Generates string with length number of cryptographically strong pseudo-random bytes.

Example:

  OpenSSL::Random.random_bytes(12)
  => "..."