qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] f0d3c3: qcrypto-luks: rename some fields in Q


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] f0d3c3: qcrypto-luks: rename some fields in QCryptoBlockLU...
Date: Mon, 30 Sep 2019 02:47:20 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: f0d3c3625c11443e87c19065859c0af645c2dec4
      
https://github.com/qemu/qemu/commit/f0d3c3625c11443e87c19065859c0af645c2dec4
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: rename some fields in QCryptoBlockLUKSHeader

* key_bytes -> master_key_len
* payload_offset = payload_offset_sector (to emphasise that this isn't byte 
offset)
* key_offset -> key_offset_sector - same as above for luks slots

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 70b2a1fed5d84c3a5f84432e4973568bff801d6c
      
https://github.com/qemu/qemu/commit/70b2a1fed5d84c3a5f84432e4973568bff801d6c
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: don't overwrite cipher_mode in header

This way we can store the header we loaded, which
will be used in key management code

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 1ddd52e4b52f383715255ec78104e71727f9b53e
      
https://github.com/qemu/qemu/commit/1ddd52e4b52f383715255ec78104e71727f9b53e
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: simplify masterkey and masterkey length

Let the caller allocate masterkey
Always use master key len from the header

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 7e60a6f53d8ec403e5493ba5858543a389f58aee
      
https://github.com/qemu/qemu/commit/7e60a6f53d8ec403e5493ba5858543a389f58aee
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: pass keyslot index rather that pointer to the keyslot

Another minor refactoring

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 9d80e59d50c2e17400954447d50a02c2c41aadac
      
https://github.com/qemu/qemu/commit/9d80e59d50c2e17400954447d50a02c2c41aadac
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: use the parsed encryption settings in QCryptoBlockLUKS

Prior to that patch, the parsed encryption settings
were already stored into the QCryptoBlockLUKS but not
used anywhere but in qcrypto_block_luks_get_info

Using them simplifies the code

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 61dd8a9a52b534cc74b88f316ebb4d56c28d9651
      
https://github.com/qemu/qemu/commit/61dd8a9a52b534cc74b88f316ebb4d56c28d9651
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: purge unused error codes from open callback

These values are not used by generic crypto code anyway

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: dde2c5afebd383b6a72dc5138a68250a81e3e1ad
      
https://github.com/qemu/qemu/commit/dde2c5afebd383b6a72dc5138a68250a81e3e1ad
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: extract store and load header

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 9fa9c1c28f349d0a9ffa6727c34e8cc06ad8049e
      
https://github.com/qemu/qemu/commit/9fa9c1c28f349d0a9ffa6727c34e8cc06ad8049e
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: extract check and parse header

This is just to make qcrypto_block_luks_open more
reasonable in size.

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 3994a7c909a4579bd0a4f2867a47ac4c1ab35a36
      
https://github.com/qemu/qemu/commit/3994a7c909a4579bd0a4f2867a47ac4c1ab35a36
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: extract store key function

This function will be used later to store
new keys to the luks metadata

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: bd56a55a94148423d37aceb057fa46031065b3da
      
https://github.com/qemu/qemu/commit/bd56a55a94148423d37aceb057fa46031065b3da
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: simplify the math used for keyslot locations

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: befdba9edd20a896f4082adf6dfb613939a24e0c
      
https://github.com/qemu/qemu/commit/befdba9edd20a896f4082adf6dfb613939a24e0c
  Author: Maxim Levitsky <address@hidden>
  Date:   2019-09-26 (Thu, 26 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  qcrypto-luks: more rigorous header checking

Check that keyslots don't overlap with the data,
and check that keyslots don't overlap with each other.
(this is done using naive O(n^2) nested loops,
but since there are just 8 keyslots, this doesn't really matter.

Signed-off-by: Maxim Levitsky <address@hidden>
Reviewed-by: Daniel P. Berrangé <address@hidden>
Signed-off-by: Daniel P. Berrangé <address@hidden>


  Commit: 1e396381939bb7e4e799d9bf2a2af693954b5613
      
https://github.com/qemu/qemu/commit/1e396381939bb7e4e799d9bf2a2af693954b5613
  Author: Peter Maydell <address@hidden>
  Date:   2019-09-27 (Fri, 27 Sep 2019)

  Changed paths:
    M crypto/block-luks.c

  Log Message:
  -----------
  Merge remote-tracking branch 
'remotes/berrange/tags/qcrypto-next-pull-request' into staging

Refactoring of LUKS support to facilitate keyslot updates

No current functional change is expected with this series.

# gpg: Signature made Fri 27 Sep 2019 10:58:54 BST
# gpg:                using RSA key DAF3A6FDB26B62912D0E8E3FBE86EBB415104FDF
# gpg: Good signature from "Daniel P. Berrange <address@hidden>" [full]
# gpg:                 aka "Daniel P. Berrange <address@hidden>" [full]
# Primary key fingerprint: DAF3 A6FD B26B 6291 2D0E  8E3F BE86 EBB4 1510 4FDF

* remotes/berrange/tags/qcrypto-next-pull-request:
  qcrypto-luks: more rigorous header checking
  qcrypto-luks: simplify the math used for keyslot locations
  qcrypto-luks: extract store key function
  qcrypto-luks: extract check and parse header
  qcrypto-luks: extract store and load header
  qcrypto-luks: purge unused error codes from open callback
  qcrypto-luks: use the parsed encryption settings in QCryptoBlockLUKS
  qcrypto-luks: pass keyslot index rather that pointer to the keyslot
  qcrypto-luks: simplify masterkey and masterkey length
  qcrypto-luks: don't overwrite cipher_mode in header
  qcrypto-luks: rename some fields in QCryptoBlockLUKSHeader

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/c6f5012ba5fa...1e396381939b



reply via email to

[Prev in Thread] Current Thread [Next in Thread]