code: public int read(byte[] buf, int off, int len) throws IOException {
          len = in.read(buf, off, len);
          if (len != -1) {
              cksum.update(buf, off, len);
          }
          return len;
      }
docs: Reads into an array of bytes. If <code>len</code> is not zero, the method
  blocks until some input is available; otherwise, no
  bytes are read and <code>0</code> is returned.
  @param buf the buffer into which the data is read
  @param off the start offset in the destination array <code>b</code>
  @param len the maximum number of bytes read
  @return    the actual number of bytes read, or -1 if the end
  of the stream is reached.
  @exception  NullPointerException If <code>buf</code> is <code>null</code>.
  @exception  IndexOutOfBoundsException If <code>off</code> is negative,
  <code>len</code> is negative, or <code>len</code> is greater than
  <code>buf.length - off</code>
  @exception IOException if an I/O error has occurred