fa8fbeaaf4
necessary because CLOOP format lacks explicit EOF or length, so that in the presence of padding or when the CLOOP is put onto a larger partition upper level provider size may be larger. Bound amount of extra data that we might touch to the max length of the compressed block and detect zero-padding in the last cluster, which when sector is all-zero might cause us to emit bogus I/O error after decompression of that fails. To not make code any more complicated that it needs to be deal with it in lazy-manner, i.e. when we first access that specific cluster. This change also fixes stupid mistake in the LZMA code, inherited from geom_lzma, which does not share length of the output buffer buffer with the decompression routine, so that in the presence of corrupted or purposedly tailored data may easily cause heap overflow and kernel memory corruption. Beef up validation of the CLOOP TOC by checking that lengths of all but the last compressed clusters match upper limit set by the decompressor and improve some error diagnostic output while I am here. 2.Add kern.geom.uzip.attach_to tunable to artifically limit attaching uzip to certain devices in the dev tree only. For example the following only makes us attaching to the GPT labels: kern.geom.uzip.attach_to="gpt/*" 3.Add kern.geom.uzip.noattach_to, which does opposite to the (2) above, i.e. prevents geom_uzip from tasting / attaching to providers matching some pattern. By default we don't attach to our own kind, i.e. kern.geom.uzip.noattach_to="*.uzip". It saves us quite some CPU cycles, esp on low-end embedded systems. Approved by: re (gjb) Differential Revision: https://reviews.freebsd.org/D7013 |
||
---|---|---|
.. | ||
bde | ||
cache | ||
concat | ||
eli | ||
gate | ||
journal | ||
label | ||
linux_lvm | ||
mirror | ||
mountver | ||
multipath | ||
nop | ||
part | ||
raid | ||
raid3 | ||
sched | ||
shsec | ||
stripe | ||
uzip | ||
vinum | ||
virstor | ||
zero | ||
geom_aes.c | ||
geom_bsd_enc.c | ||
geom_bsd.c | ||
geom_ccd.c | ||
geom_ctl.c | ||
geom_ctl.h | ||
geom_dev.c | ||
geom_disk.c | ||
geom_disk.h | ||
geom_dump.c | ||
geom_event.c | ||
geom_flashmap.c | ||
geom_fox.c | ||
geom_int.h | ||
geom_io.c | ||
geom_kern.c | ||
geom_map.c | ||
geom_mbr_enc.c | ||
geom_mbr.c | ||
geom_pc98_enc.c | ||
geom_pc98.c | ||
geom_redboot.c | ||
geom_slice.c | ||
geom_slice.h | ||
geom_subr.c | ||
geom_sunlabel_enc.c | ||
geom_sunlabel.c | ||
geom_vfs.c | ||
geom_vfs.h | ||
geom_vol_ffs.c | ||
geom.h | ||
notes |