syzkaller/sys/linux/socket_ipx.txt
Michael Tüxen 6ad0ae6171 sys: remove socketpair for AF_INET and AF_INET6
* OpebBSD: remove socketpair() for AF_INET and AF_INET6.

socketpair() is only supported on AF_UNIX.

* NetBSD: remove socketpair() for AF_INET and AF_INET6.

socketpair() is only supported for AF_UNIX.

* FreeBSD: remove socketpair() for AF_INET and AF_INET6.

socketpair() only supports AF_UNIX.

* Linux: remove socketpair for AF_INET and AF_INET6.

socketpair only supports AF_UNIX.

* Autogenerated files.

These are manually generated for all platforms you are not
running on. FreeBSD in this case.

* executor: rebase.

* sys/freebsd: rebase.

* sys/linux: use AF_UNIX based socketpair for nbd.

This was suggested by Dmitry.

Fixes #845
2018-12-04 08:58:22 +00:00

54 lines
2.4 KiB
Plaintext

# Copyright 2017 syzkaller project authors. All rights reserved.
# Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
# AF_IPX support.
include <linux/socket.h>
include <linux/net.h>
include <linux/if_ether.h>
include <linux/if_arp.h>
include <linux/ipx.h>
resource sock_ipx[sock]
socket$ipx(domain const[AF_IPX], type const[SOCK_DGRAM], proto const[0]) sock_ipx
bind$ipx(fd sock_ipx, addr ptr[in, sockaddr_ipx], addrlen len[addr])
connect$ipx(fd sock_ipx, addr ptr[in, sockaddr_ipx], addrlen len[addr])
accept$ipx(fd sock_ipx, peer ptr[out, sockaddr_ipx, opt], peerlen ptr[inout, len[peer, int32]]) sock_ipx
accept4$ipx(fd sock_ipx, peer ptr[out, sockaddr_ipx, opt], peerlen ptr[inout, len[peer, int32]], flags flags[accept_flags]) sock_ipx
sendto$ipx(fd sock_ipx, buf buffer[in], len len[buf], f flags[send_flags], addr ptr[in, sockaddr_ipx, opt], addrlen len[addr])
recvfrom$ipx(fd sock_ipx, buf buffer[out], len len[buf], f flags[recv_flags], addr ptr[in, sockaddr_ipx, opt], addrlen len[addr])
getsockname$ipx(fd sock_ipx, addr ptr[out, sockaddr_ipx], addrlen ptr[inout, len[addr, int32]])
getpeername$ipx(fd sock_ipx, peer ptr[out, sockaddr_ipx], peerlen ptr[inout, len[peer, int32]])
sockaddr_ipx {
sipx_family const[AF_IPX, int16]
sipx_port int16be
sipx_network int32be
sipx_node array[int8, 6]
sipx_type int8
pad const[0, int8]
}
# Specific options
getsockopt$ipx_IPX_TYPE(fd sock_ipx, level const[SOL_IPX], optname const[IPX_TYPE], optval ptr[out, int32], optlen ptr[inout, len[optval, int32]])
setsockopt$ipx_IPX_TYPE(fd sock_ipx, level const[SOL_IPX], optname const[IPX_TYPE], optval ptr[in, int32], optlen len[optval])
# ioctls
# TODO: SIOCDELRT & SIOCADDRT (net/ipx/ipx_route.c)
ioctl$sock_ipx_SIOCSIFADDR(fd sock_ipx, cmd const[SIOCSIFADDR], arg ptr[in, ifreq_t[sockaddr_ipx]])
ioctl$sock_ipx_SIOCGIFADDR(fd sock_ipx, cmd const[SIOCGIFADDR], arg ptr[inout, ifreq_t[sockaddr_ipx]])
ioctl$sock_ipx_SIOCAIPXITFCRT(fd sock_ipx, cmd const[SIOCAIPXITFCRT], arg ptr[in, int32])
ioctl$sock_ipx_SIOCAIPXPRISLT(fd sock_ipx, cmd const[SIOCAIPXPRISLT], arg ptr[in, int32])
ioctl$sock_ipx_SIOCIPXCFGDATA(fd sock_ipx, cmd const[SIOCIPXCFGDATA], arg ptr[out, ipx_config_data])
ioctl$sock_ipx_SIOCIPXNCPCONN(fd sock_ipx, cmd const[SIOCIPXNCPCONN], arg ptr[in, int16])
ipx_config_data {
ipxcfg_auto_select_primary int16
ipxcfg_auto_create_interfaces int16
}