[V6] Adds Redmine::Utils.random_hex for generating a random hex string

rebased #640.