diff options
author | Karel Zak | 2017-05-26 12:58:09 +0200 |
---|---|---|
committer | Karel Zak | 2017-06-28 10:28:41 +0200 |
commit | d2b0c6587d729a8e838821cb70d4de18c6969868 (patch) | |
tree | 834756ba5d56eb7ebbf02e661a7962ec7fbed297 /libblkid/src/libblkid.sym | |
parent | setpriv: add --ambient-caps to usage() (diff) | |
download | kernel-qcow2-util-linux-d2b0c6587d729a8e838821cb70d4de18c6969868.tar.gz kernel-qcow2-util-linux-d2b0c6587d729a8e838821cb70d4de18c6969868.tar.xz kernel-qcow2-util-linux-d2b0c6587d729a8e838821cb70d4de18c6969868.zip |
libblkid: allow to hide already detected signatures
The libblkid probing functions returns the first successful result of
the filesystem/RAID/PT. Unfortunately, some signatures is possible to
detect by more ways or device may contains more copies (e.g. GPT).
This is no problem when we wipe signatures from the device. In this
case we zeroize on-device signature and re-scan for the signature (by
blkid_probe_step_back()).
The problem is if we want to read all permutations without the device
modification (for example wipefs(8) dry run).
This patch add blkid_probe_hide_range(). The function remove (zeroize)
specified signature from in-memory cached buffers. If the buffer is
later re-used by probing functions then the signature is invisible and
we can try detect another variant of the magic string.
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'libblkid/src/libblkid.sym')
-rw-r--r-- | libblkid/src/libblkid.sym | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libblkid/src/libblkid.sym b/libblkid/src/libblkid.sym index 164e115b5..65e4e22b7 100644 --- a/libblkid/src/libblkid.sym +++ b/libblkid/src/libblkid.sym @@ -169,3 +169,8 @@ BLKID_2.30 { blkid_probe_set_sectorsize; blkid_partitions_get_name; } BLKID_2.25; + +BLKID_2_31 { + blkid_probe_reset_buffers; + blkid_probe_hide_range; +} BLKID_2.30; |