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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 16 May 2023 05:43:21 +0000
From: FUJITA Tomonori <tomo@...bit.dev>
To: andrew@...n.ch
Cc: tomo@...bit.dev, rust-for-linux@...r.kernel.org,
 netdev@...r.kernel.org, linux-crypto@...r.kernel.org,
 fujita.tomonori@...il.com
Subject: Re: [PATCH 2/2] rust: add socket support

On Mon, 15 May 2023 16:14:56 +0200
Andrew Lunn <andrew@...n.ch> wrote:

> On Mon, May 15, 2023 at 04:34:28AM +0000, FUJITA Tomonori wrote:
>> From: FUJITA Tomonori <fujita.tomonori@...il.com>
>> 
>> minimum abstraction for networking.
> 
>> Signed-off-by: FUJITA Tomonori <fujita.tomonori@...il.com>
>> ---
>>  rust/bindings/bindings_helper.h |   3 +
>>  rust/kernel/lib.rs              |   2 +
>>  rust/kernel/net.rs              | 174 ++++++++++++++++++++++++++++++++
> 
> The full networking API is huge. So trying to put it all into net.rs
> is unlikely to work in the long run. Maybe it would be better to name
> this file based on the tiny little bit of the network API you are
> writing an abstraction for?

Yeah, in the long run. I tried the simplest but if the maintainers
prefer that approach as the first step, I'll update the patch. how
about rust/net/socket.rs ?


> If i'm reading the code correctly, you are abstracting the in kernel
> socket API for only TCP over IPv4. Probably with time that will get
> extended to IPv6, and then UDP. So maybe call this net-kern-socket.rs?

Yes. It's thin abstraction, just wrapping socket APIs. So it's easy to
extend it for IPv6, non IP protocols, etc.

Thanks,

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ