[lkml]   [2018]   [Sep]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC PATCH 01/10] fs-verity: add setup code, UAPI, and Kconfig
On Fri, Sep 14, 2018 at 09:21:43AM -0700, Eric Biggers wrote:
> >
> > Now AIUI, Zip files have an internal header that contains e.g. the size and
> > indexes into the internal files. So if someone added random data to the end
> > of a zip file, nothing is going to end up actually reading it.
> After the verity bit is enabled, the verity metadata is not visible to
> userspace. Yes, that means i_size is adjusted too. Also all contents
> modifications are denied, including appends.

One of this reasons why this is important is that ZIP files *also*
have an central directory at the end. And in the case of the APK
files, there is an in-band signature block which is located at at the
end of the last file and the central directory, which can be located
by starting at the end of the file, finding the length of the central
directory, and then backing up to find the signature block.

- Ted

 \ /
  Last update: 2018-09-15 17:28    [W:0.119 / U:1.296 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site