lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <19332.1249599272@alphaville.usa.hp.com>
Date:	Thu, 06 Aug 2009 18:54:32 -0400
From:	Nick Dokos <nicholas.dokos@...com>
To:	Andreas Dilger <adilger@....com>
Cc:	nicholas.dokos@...com
Subject: Re: ll_ver_fs data verification failure - 96TB fs 

> ... 
> The code should  perhaps read something like this:
> 
>  		if ((nread = read(fd, chunk_buf, chunksize)) < 0) {
>  			fprintf(stderr, "\n%s: read %s+%llu failed: %s\n",
>  				progname, file, offset, strerror(errno));
>  			return 1;
>  		}
>                 if (nread < chunksize) {
>                         fprintf(stderr, "short read etc");
>                         /* or force the next read() to check for errors? */
>                         return 1;
>                 }
>  		if (verify_chunk(chunk_buf, chunksize, offset, time_st,
>  				 inode_st, file) != 0)
>  			return 1;
> 

... except that the write() side also does not deal with short writes,
and for a full run, the last file of the last directory will probably be
short even if no errors occur. In that case, the short read is not an
error.

Thanks,
Nick
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ