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]
Date:	Thu, 04 Feb 2010 13:56:39 -0800 (PST)
From:	David Miller <davem@...emloft.net>
To:	penguin-kernel@...ove.SAKURA.ne.jp
Cc:	opurdila@...acom.com, amwang@...hat.com,
	linux-kernel@...r.kernel.org, eric.dumazet@...il.com,
	linux-rdma@...r.kernel.org, netdev@...r.kernel.org,
	nhorman@...driver.com, linux-sctp@...r.kernel.org
Subject: Re: [RFC Patch] net: reserve ports for applications using fixed
 port numbers

From: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
Date: Fri, 5 Feb 2010 06:45:28 +0900

> Octavian Purdila wrote:
>> 
>> int inet_is_reserved_local_port(int port)
>> {
>> 	if (test_bit(port, reserved_ports))
>> 		return 1;
>> 	return 0;
>> }
>> 
> Above check is exactly what I'm doing in the LSM hook.

But his version can be done inline in 2 or 3 instructions.

An LSM hook will result in an indirect function call,
all live registers spilled to the stack, then all of
those reloaded when the function returns.

It will be much more expensive.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists