diff options
author | Tom Caputi <[email protected]> | 2018-03-31 14:12:51 -0400 |
---|---|---|
committer | Brian Behlendorf <[email protected]> | 2018-03-31 11:12:51 -0700 |
commit | a2c2ed1bd4c3dc6d52b6058b9c74245cad2ae331 (patch) | |
tree | de5ad1fd1bc04f0ee496316305871d0b0e26d74e /include/sys/arc.h | |
parent | 4515b1d01c936b8cf156e20ba42cdb8916bca80b (diff) |
Decryption error handling improvements
Currently, the decryption and block authentication code in
the ZIO / ARC layers is a bit inconsistent with regards to
the ereports that are produces and the error codes that are
passed to calling functions. This patch ensures that all of
these errors (which begin as ECKSUM) are converted to EIO
before they leave the ZIO or ARC layer and that ereports
are correctly generated on each decryption / authentication
failure.
In addition, this patch fixes a bug in zio_decrypt() where
ECKSUM never gets written to zio->io_error.
Reviewed by: Matt Ahrens <[email protected]>
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Tom Caputi <[email protected]>
Closes #7372
Diffstat (limited to 'include/sys/arc.h')
-rw-r--r-- | include/sys/arc.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sys/arc.h b/include/sys/arc.h index de280362d..9d6bab505 100644 --- a/include/sys/arc.h +++ b/include/sys/arc.h @@ -237,7 +237,7 @@ boolean_t arc_is_unauthenticated(arc_buf_t *buf); enum zio_compress arc_get_compression(arc_buf_t *buf); void arc_get_raw_params(arc_buf_t *buf, boolean_t *byteorder, uint8_t *salt, uint8_t *iv, uint8_t *mac); -int arc_untransform(arc_buf_t *buf, spa_t *spa, uint64_t dsobj, +int arc_untransform(arc_buf_t *buf, spa_t *spa, const zbookmark_phys_t *zb, boolean_t in_place); void arc_convert_to_raw(arc_buf_t *buf, uint64_t dsobj, boolean_t byteorder, dmu_object_type_t ot, const uint8_t *salt, const uint8_t *iv, |