• J
    tls: rx: support optimistic decrypt to user buffer with TLS 1.3 · ce61327c
    Jakub Kicinski 提交于
    We currently don't support decrypt to user buffer with TLS 1.3
    because we don't know the record type and how much padding
    record contains before decryption. In practice data records
    are by far most common and padding gets used rarely so
    we can assume data record, no padding, and if we find out
    that wasn't the case - retry the crypto in place (decrypt
    to skb).
    
    To safeguard from user overwriting content type and padding
    before we can check it attach a 1B sg entry where last byte
    of the record will land.
    Signed-off-by: NJakub Kicinski <kuba@kernel.org>
    Signed-off-by: NDavid S. Miller <davem@davemloft.net>
    ce61327c
tls_sw.c 64.0 KB