+ if (!prot || (data_key == prot_key && data_va == prot_va && + data_len == prot_len)) {Worth explaining in a comment that this is either insert/strip or interleaved case..there is an explanation that you wrote (I think it's good enough): /** * Source domain doesn't contain signature information * or data and protection are interleaved in memory. * So need construct: * ------------------ * | data_klm | * ------------------ * | BSF | * ------------------ **/
Right :-)