lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <acd844ba-07b2-8a14-0089-77b3c4dcb68b@digikod.net>
Date:   Tue, 22 Nov 2022 18:17:10 +0100
From:   Mickaël Salaün <mic@...ikod.net>
To:     Konstantin Meskhidze <konstantin.meskhidze@...wei.com>
Cc:     willemdebruijn.kernel@...il.com, gnoack3000@...il.com,
        linux-security-module@...r.kernel.org, netdev@...r.kernel.org,
        netfilter-devel@...r.kernel.org, artem.kuzin@...wei.com
Subject: Re: [PATCH v8 02/12] landlock: Refactor
 landlock_find_rule/insert_rule


On 17/11/2022 19:41, Mickaël Salaün wrote:
> 
> On 21/10/2022 17:26, Konstantin Meskhidze wrote:

[...]

>> diff --git a/security/landlock/ruleset.h b/security/landlock/ruleset.h
>> index f2ad932d396c..608ab356bc3e 100644
>> --- a/security/landlock/ruleset.h
>> +++ b/security/landlock/ruleset.h
>> @@ -49,6 +49,46 @@ struct landlock_layer {
>>    	access_mask_t access;
>>    };
>>
>> +/**
>> + * union landlock_key - Key of a ruleset's red-black tree
>> + */
>> +union landlock_key {
>> +	/**
>> +	 * @object: Pointer to identify a kernel object (e.g. an inode).
>> +	 */
>> +	struct landlock_object *object;
>> +	/**
>> +	 * @data: A raw data value to identify a network socket port.
> 
> "Raw data to identify an arbitrary 32-bit value (e.g. a TCP port)."
> 
> 
>> +	 */
>> +	uintptr_t data;
>> +};
>> +
>> +/**
>> + * enum landlock_key_type - Type of &union landlock_key
>> + */
>> +enum landlock_key_type {
>> +	/**
>> +	 * @LANDLOCK_KEY_INODE: Type of &landlock_ruleset.root_inode's node
>> +	 * keys.
>> +	 */
>> +	LANDLOCK_KEY_INODE = 1,
>> +};
>> +
>> +/**
>> + * struct landlock_id - Unique rule identifier for a ruleset
>> + */
>> +struct landlock_id {
>> +	/**
>> +	 * @key: A union to identify either a kernel object (e.g. an inode) or
>> +	 * a raw data value (e.g. a network socket port).
> 
> "a 32-bit value (e.g. a TCP port)."

Instead:
@key: Identifies either a kernel object (e.g. an inode) or a raw value 
(e.g. a TCP port).

> 
> 
>> +	 */
>> +	union landlock_key key;
>> +	/**
>> +	 * @type: A enumerator to identify the type of landlock_ruleset's root tree.

@type: Type of a landlock_ruleset's root tree.


>> +	 */
>> +	const enum landlock_key_type type;
>> +};

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ