Refactor prevention of sidechannel timing attack

In ruby `all?` is lazy and will return false as soon as it
encouters a false value, same as the original sidechannel attack
on `String#==`, this prevents that by injecting over all.