Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f4ee2def authored by Heinrich Schuchardt's avatar Heinrich Schuchardt Committed by John Johansen
Browse files

apparmor: do not expose kernel stack



Do not copy uninitalized fields th.td_hilen, th.td_data.

Signed-off-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: default avatarJohn Johansen <john.johansen@canonical.com>
parent 58acf9d9
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -63,7 +63,9 @@ static struct table_header *unpack_table(char *blob, size_t bsize)

	table = kvzalloc(tsize);
	if (table) {
		*table = th;
		table->td_id = th.td_id;
		table->td_flags = th.td_flags;
		table->td_lolen = th.td_lolen;
		if (th.td_flags == YYTD_DATA8)
			UNPACK_ARRAY(table->td_data, blob, th.td_lolen,
				     u8, byte_to_byte);