linux/arch/h8300
Vincent Bernat d59577b6ff sk-filter: Add ability to lock a socket filter program
While a privileged program can open a raw socket, attach some
restrictive filter and drop its privileges (or send the socket to an
unprivileged program through some Unix socket), the filter can still
be removed or modified by the unprivileged program. This commit adds a
socket option to lock the filter (SO_LOCK_FILTER) preventing any
modification of a socket filter program.

This is similar to OpenBSD BIOCLOCK ioctl on bpf sockets, except even
root is not allowed change/drop the filter.

The state of the lock can be read with getsockopt(). No error is
triggered if the state is not changed. -EPERM is returned when a user
tries to remove the lock or to change/remove the filter while the lock
is active. The check is done directly in sk_attach_filter() and
sk_detach_filter() and does not affect only setsockopt() syscall.

Signed-off-by: Vincent Bernat <bernat@luffy.cx>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-01-17 03:21:25 -05:00
..
boot h8300: change to new flag variable 2011-03-17 14:02:55 +01:00
include sk-filter: Add ability to lock a socket filter program 2013-01-17 03:21:25 -05:00
kernel flagday: don't pass regs to copy_thread() 2012-11-28 23:43:42 -05:00
lib
mm h8300: use the declarations provided by <asm/sections.h> 2012-06-20 14:39:35 -07:00
platform sections: fix section conflicts in arch/h8300 2012-10-06 03:04:38 +09:00
Kconfig Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal 2012-12-20 18:05:28 -08:00
Kconfig.cpu timers: Fixup the Kconfig consolidation fallout 2012-05-21 23:43:46 +02:00
Kconfig.debug
Kconfig.ide
Makefile
README
defconfig kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT 2011-01-20 17:02:05 -08:00

README

linux-2.6 for H8/300 README
Yoshinori Sato <ysato@users.sourceforge.jp>

* Supported CPU
H8/300H and H8S

* Supported Target
1.simulator of GDB
  require patches.

2.AE 3068/AE 3069
  more information 
  MICROTRONIQUE <http://www.microtronique.com/>
  Akizuki Denshi Tsusho Ltd. <http://www.akizuki.ne.jp> (Japanese Only)

3.H8MAX 
  see http://ip-sol.jp/h8max/ (Japanese Only)

4.EDOSK2674
  see http://www.eu.renesas.com/products/mpumcu/tool/edk/support/edosk2674.html
      http://www.uclinux.org/pub/uClinux/ports/h8/HITACHI-EDOSK2674-HOWTO
      http://www.azpower.com/H8-uClinux/

* Toolchain Version
gcc-3.1 or higher and patch
see arch/h8300/tools_patch/README
binutils-2.12 or higher
gdb-5.2 or higher
The environment that can compile a h8300-elf binary is necessary.

* Userland Develop environment
used h8300-elf toolchains.
see http://www.uclinux.org/pub/uClinux/ports/h8/

* A few words of thanks
Porting to H8/300 serieses is support of Information-technology Promotion Agency, Japan.
I thank support.
and All developer/user.