Skip to content
Commit b54aebd4 authored by Rae Moar's avatar Rae Moar Committed by John Johansen
Browse files

apparmor: fix use of strcpy in policy_unpack_test

Replace the use of strcpy() in build_aa_ext_struct() in
policy_unpack_test.c with strscpy().

strscpy() is the safer method to use to ensure the buffer does not
overflow. This was found by kernel test robot:
https://lore.kernel.org/all/202301040348.NbfVsXO0-lkp@intel.com/

.

Reported-by: default avatarkernel test robot <lkp@intel.com>

Signed-off-by: default avatarRae Moar <rmoar@google.com>
Signed-off-by: default avatarJohn Johansen <john.johansen@canonical.com>
parent 76862af5
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment