code: public static boolean equal(byte[] a, byte[] b) {
         if (a == b)
            return (true);
         if ((a == null) || (b == null))
            return (false);
         if (a.length != b.length)
            return (false);
         for (int i = 0; i < a.length; i++)
            if (a[i] != b[i])
               return (false);
         return (true);
      }
docs: Returns true if the byte arrays are identical; false
  otherwise.