Rather than creating random strings using rand over an array of chars, we should make use of UUIDs and/or hash algorithm over the object.