4757b0 Choosing the most memory-consuming key slot when estimating the memory requirement for LUKS-encrypted target

1 file Authored by Coiby Xu 2 years ago, Committed by liutgnu 2 years ago,
1 file changed. 2 lines added. 2 lines removed.
    Choosing the most memory-consuming key slot when estimating the memory requirement for LUKS-encrypted target
    
    Related: bz2076206
    Upstream: Fedora
    Conflict: None
    
    commit 50a8461fc7cc70b57387baa58ff4db864ba36632
    Author: Coiby Xu <coxu@redhat.com>
    Date:   Mon Sep 5 17:49:18 2022 +0800
    
        Choosing the most memory-consuming key slot when estimating the
        memory requirement for LUKS-encrypted target
    
        When there are multiple key slots, "kdumpctl estimate" uses the least
        memory-consuming key slot. For example, when there are two memory slots
        created with --pbkdf-memory=1048576 (1G) and --pbkdf-memory=524288 (512M),
        "kdumpctl estimate" thinks the extra memory requirement is only 512M.
        This will of course lead to OOM if the user uses the more
        memory-consuming key slot. Fix it by sorting in reverse order.
    
        Fixes: e9e6a2c ("kdumpctl: Add kdumpctl estimate")
        Signed-off-by: Coiby Xu <coxu@redhat.com>
    
        Reviewed-by: Lichen Liu <lichliu@redhat.com>
        Signed-off-by: Coiby Xu <coxu@redhat.com>
    
    Signed-off-by: Coiby Xu <coxu@redhat.com>
    
        
file modified
+2 -2