aboutgitcodelistschat:MatrixIRC
path: root/cooker/calls
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2023-06-04 08:13:23 +0200
committerStefano Brivio <sbrivio@redhat.com>2023-06-04 08:29:05 +0200
commit37e94bd191701a08e0081b2027cfbede6d76a21c (patch)
tree873e2646f52d901c057d40c47499a3f80ba2d23f /cooker/calls
parent6a8f05f9f0d10b257edce878381bf22b1249537e (diff)
downloadseitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar.gz
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar.bz2
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar.lz
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar.xz
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.tar.zst
seitan-37e94bd191701a08e0081b2027cfbede6d76a21c.zip
treewide: Change to GPLv2, add LICENSES, missing headers
As discussed with Alice -- 'reuse lint' passes now. Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'cooker/calls')
-rw-r--r--cooker/calls/fs.c2
-rw-r--r--cooker/calls/fs.h2
-rw-r--r--cooker/calls/ioctl.c310
-rw-r--r--cooker/calls/ioctl.h2
-rw-r--r--cooker/calls/net.c4
-rw-r--r--cooker/calls/net.h2
-rw-r--r--cooker/calls/process.c2
-rw-r--r--cooker/calls/process.h2
8 files changed, 163 insertions, 163 deletions
diff --git a/cooker/calls/fs.c b/cooker/calls/fs.c
index 924907d..013dacf 100644
--- a/cooker/calls/fs.c
+++ b/cooker/calls/fs.c
@@ -1,4 +1,4 @@
-// SPDX-License-Identifier: GPL-3.0-or-later
+// SPDX-License-Identifier: GPL-2.0-or-later
/* seitan - Syscall Expressive Interpreter, Transformer and Notifier
*
diff --git a/cooker/calls/fs.h b/cooker/calls/fs.h
index 2e3c06b..ad2f218 100644
--- a/cooker/calls/fs.h
+++ b/cooker/calls/fs.h
@@ -1,4 +1,4 @@
-/* SPDX-License-Identifier: GPL-3.0-or-later
+/* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright 2023 Red Hat GmbH
* Author: Stefano Brivio <sbrivio@redhat.com>
*/
diff --git a/cooker/calls/ioctl.c b/cooker/calls/ioctl.c
index a60b834..c9f01d0 100644
--- a/cooker/calls/ioctl.c
+++ b/cooker/calls/ioctl.c
@@ -1,155 +1,155 @@
-// SPDX-License-Identifier: GPL-3.0-or-later
-
-/* seitan - Syscall Expressive Interpreter, Transformer and Notifier
- *
- * cooker/calls/ioctl.c - Description of known ioctl(2) requests
- *
- * Copyright 2023 Red Hat GmbH
- * Authors: Alice Frosi <afrosi@redhat.com>
- * Stefano Brivio <sbrivio@redhat.com>
- */
-
-/*
-fd = ioctl_ns(fd, request)
-n = ioctl_tty(fd, cmd, argp)
-e = ioctl_iflags(fd, cmd, attr)
-*/
-
-#include <asm-generic/unistd.h>
-#include <sys/syscall.h>
-
-#include <sys/ioctl.h>
-#include <termios.h>
-#include <linux/fs.h>
-#include <linux/nsfs.h>
-
-#include <net/if.h>
-#include <linux/if.h>
-#include <linux/if_tun.h>
-
-#include "../cooker.h"
-#include "../calls.h"
-
-static struct num request[] = {
- { "FS_IOC_GETFLAGS", FS_IOC_GETFLAGS }, /* ioctl_iflags */
- { "FS_IOC_SETFLAGS", FS_IOC_SETFLAGS },
-
- { "NS_GET_USERNS", NS_GET_USERNS }, /* ioctl_ns*/
- { "NS_GET_PARENT", NS_GET_PARENT },
-
- { "TCGETS", TCGETS }, /* ioctl_tty */
- { "TCSETS", TCSETS },
- { "TCSETSW", TCSETSW },
- { "TCSETSF", TCSETSF },
-
- { "TUNSETIFF", TUNSETIFF }, /* no man page? */
-
- { 0 },
-};
-
-static struct num attr[] = {
- { "FS_APPEND_FL", FS_APPEND_FL },
- { "FS_COMPR_FL", FS_COMPR_FL },
- { "FS_DIRSYNC_FL", FS_DIRSYNC_FL },
- { "FS_IMMUTABLE_FL", FS_IMMUTABLE_FL },
- { "FS_JOURNAL_DATA_FL", FS_JOURNAL_DATA_FL },
- { "FS_NOATIME_FL", FS_NOATIME_FL },
- { "FS_NOCOW_FL", FS_NOCOW_FL },
- { "FS_NODUMP_FL", FS_NODUMP_FL },
- { "FS_NOTAIL_FL", FS_NOTAIL_FL },
- { "FS_PROJINHERIT_FL", FS_PROJINHERIT_FL },
- { "FS_SECRM_FL", FS_SECRM_FL },
- { "FS_SYNC_FL", FS_SYNC_FL },
- { "FS_TOPDIR_FL", FS_TOPDIR_FL },
- { "FS_UNRM_FL", FS_UNRM_FL },
-};
-
-static struct num tun_ifr_flags[] = {
- { "IFF_TUN", IFF_TUN },
- { 0 },
-};
-
-static struct field tun_ifr[] = { /* netdevice(7) */
- {
- "name", STRING, 0,
- offsetof(struct ifreq, ifr_name),
- IFNAMSIZ, { 0 },
- },
- {
- "flags", INT, /* One allowed at a time? */ 0,
- offsetof(struct ifreq, ifr_flags),
- 0, { .d_num = tun_ifr_flags },
- },
-};
-
-static struct select_num ioctl_request_arg[] = {
- { FS_IOC_GETFLAGS,
- { 2,
- {
- "argp", INT, FLAGS,
- sizeof(int), 0,
- { .d_num = attr }
- }
- }
- },
- { FS_IOC_SETFLAGS,
- { 2,
- {
- "argp", INT, FLAGS,
- sizeof(int), 0,
- { .d_num = attr }
- }
- }
- },
- { TUNSETIFF,
- { 2,
- {
- "ifr", STRUCT, 0,
- sizeof(struct ifreq), 0,
- { .d_struct = tun_ifr }
- }
- }
- },
- { 0 },
-};
-
-static struct field ioctl_request = {
- "request", INT, 0, 0, 0, { .d_num = request },
-};
-
-static struct select ioctl_request_select = {
- &ioctl_request, { .d_num = ioctl_request_arg }
-};
-
-static struct arg ioctl_args[] = {
- { 0,
- {
- "path", FDPATH, 0, 0, 0,
- { 0 }
- }
- },
- { 0,
- {
- "fd", INT, 0, 0, 0,
- { 0 }
- }
- },
- { 1,
- {
- "request", SELECT, 0, 0, 0,
- { .d_select = &ioctl_request_select }
- }
- },
- { 2,
- {
- "arg", SELECTED, 0, -1, 0,
- { 0 }
- }
- },
- { 0 },
-};
-
-struct call syscalls_ioctl[] = {
- { __NR_ioctl, "ioctl", ioctl_args },
- { 0 },
-};
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+/* seitan - Syscall Expressive Interpreter, Transformer and Notifier
+ *
+ * cooker/calls/ioctl.c - Description of known ioctl(2) requests
+ *
+ * Copyright 2023 Red Hat GmbH
+ * Authors: Alice Frosi <afrosi@redhat.com>
+ * Stefano Brivio <sbrivio@redhat.com>
+ */
+
+/*
+fd = ioctl_ns(fd, request)
+n = ioctl_tty(fd, cmd, argp)
+e = ioctl_iflags(fd, cmd, attr)
+*/
+
+#include <asm-generic/unistd.h>
+#include <sys/syscall.h>
+
+#include <sys/ioctl.h>
+#include <termios.h>
+#include <linux/fs.h>
+#include <linux/nsfs.h>
+
+#include <net/if.h>
+#include <linux/if.h>
+#include <linux/if_tun.h>
+
+#include "../cooker.h"
+#include "../calls.h"
+
+static struct num request[] = {
+ { "FS_IOC_GETFLAGS", FS_IOC_GETFLAGS }, /* ioctl_iflags */
+ { "FS_IOC_SETFLAGS", FS_IOC_SETFLAGS },
+
+ { "NS_GET_USERNS", NS_GET_USERNS }, /* ioctl_ns*/
+ { "NS_GET_PARENT", NS_GET_PARENT },
+
+ { "TCGETS", TCGETS }, /* ioctl_tty */
+ { "TCSETS", TCSETS },
+ { "TCSETSW", TCSETSW },
+ { "TCSETSF", TCSETSF },
+
+ { "TUNSETIFF", TUNSETIFF }, /* no man page? */
+
+ { 0 },
+};
+
+static struct num attr[] = {
+ { "FS_APPEND_FL", FS_APPEND_FL },
+ { "FS_COMPR_FL", FS_COMPR_FL },
+ { "FS_DIRSYNC_FL", FS_DIRSYNC_FL },
+ { "FS_IMMUTABLE_FL", FS_IMMUTABLE_FL },
+ { "FS_JOURNAL_DATA_FL", FS_JOURNAL_DATA_FL },
+ { "FS_NOATIME_FL", FS_NOATIME_FL },
+ { "FS_NOCOW_FL", FS_NOCOW_FL },
+ { "FS_NODUMP_FL", FS_NODUMP_FL },
+ { "FS_NOTAIL_FL", FS_NOTAIL_FL },
+ { "FS_PROJINHERIT_FL", FS_PROJINHERIT_FL },
+ { "FS_SECRM_FL", FS_SECRM_FL },
+ { "FS_SYNC_FL", FS_SYNC_FL },
+ { "FS_TOPDIR_FL", FS_TOPDIR_FL },
+ { "FS_UNRM_FL", FS_UNRM_FL },
+};
+
+static struct num tun_ifr_flags[] = {
+ { "IFF_TUN", IFF_TUN },
+ { 0 },
+};
+
+static struct field tun_ifr[] = { /* netdevice(7) */
+ {
+ "name", STRING, 0,
+ offsetof(struct ifreq, ifr_name),
+ IFNAMSIZ, { 0 },
+ },
+ {
+ "flags", INT, /* One allowed at a time? */ 0,
+ offsetof(struct ifreq, ifr_flags),
+ 0, { .d_num = tun_ifr_flags },
+ },
+};
+
+static struct select_num ioctl_request_arg[] = {
+ { FS_IOC_GETFLAGS,
+ { 2,
+ {
+ "argp", INT, FLAGS,
+ sizeof(int), 0,
+ { .d_num = attr }
+ }
+ }
+ },
+ { FS_IOC_SETFLAGS,
+ { 2,
+ {
+ "argp", INT, FLAGS,
+ sizeof(int), 0,
+ { .d_num = attr }
+ }
+ }
+ },
+ { TUNSETIFF,
+ { 2,
+ {
+ "ifr", STRUCT, 0,
+ sizeof(struct ifreq), 0,
+ { .d_struct = tun_ifr }
+ }
+ }
+ },
+ { 0 },
+};
+
+static struct field ioctl_request = {
+ "request", INT, 0, 0, 0, { .d_num = request },
+};
+
+static struct select ioctl_request_select = {
+ &ioctl_request, { .d_num = ioctl_request_arg }
+};
+
+static struct arg ioctl_args[] = {
+ { 0,
+ {
+ "path", FDPATH, 0, 0, 0,
+ { 0 }
+ }
+ },
+ { 0,
+ {
+ "fd", INT, 0, 0, 0,
+ { 0 }
+ }
+ },
+ { 1,
+ {
+ "request", SELECT, 0, 0, 0,
+ { .d_select = &ioctl_request_select }
+ }
+ },
+ { 2,
+ {
+ "arg", SELECTED, 0, -1, 0,
+ { 0 }
+ }
+ },
+ { 0 },
+};
+
+struct call syscalls_ioctl[] = {
+ { __NR_ioctl, "ioctl", ioctl_args },
+ { 0 },
+};
diff --git a/cooker/calls/ioctl.h b/cooker/calls/ioctl.h
index a06a9bc..7072111 100644
--- a/cooker/calls/ioctl.h
+++ b/cooker/calls/ioctl.h
@@ -1,4 +1,4 @@
-/* SPDX-License-Identifier: GPL-3.0-or-later
+/* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright 2023 Red Hat GmbH
* Author: Stefano Brivio <sbrivio@redhat.com>
*/
diff --git a/cooker/calls/net.c b/cooker/calls/net.c
index 52ebc1e..746a08e 100644
--- a/cooker/calls/net.c
+++ b/cooker/calls/net.c
@@ -1,4 +1,4 @@
-// SPDX-License-Identifier: GPL-3.0-or-later
+// SPDX-License-Identifier: GPL-2.0-or-later
/* seitan - Syscall Expressive Interpreter, Transformer and Notifier
*
@@ -228,7 +228,7 @@ static struct arg connect_args[] = {
{
"addr", SELECT, 0,
0,
- sizeof(struct sockaddr_storage),
+ sizeof(struct sockaddr_un),
{ .d_select = &connect_addr_select },
},
},
diff --git a/cooker/calls/net.h b/cooker/calls/net.h
index 105bf4a..7eb852d 100644
--- a/cooker/calls/net.h
+++ b/cooker/calls/net.h
@@ -1,4 +1,4 @@
-/* SPDX-License-Identifier: GPL-3.0-or-later
+/* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright 2023 Red Hat GmbH
* Author: Stefano Brivio <sbrivio@redhat.com>
*/
diff --git a/cooker/calls/process.c b/cooker/calls/process.c
index b133629..b7a92f0 100644
--- a/cooker/calls/process.c
+++ b/cooker/calls/process.c
@@ -1,4 +1,4 @@
-// SPDX-License-Identifier: GPL-3.0-or-later
+// SPDX-License-Identifier: GPL-2.0-or-later
/* seitan - Syscall Expressive Interpreter, Transformer and Notifier
*
diff --git a/cooker/calls/process.h b/cooker/calls/process.h
index 5e214ef..c7d81bb 100644
--- a/cooker/calls/process.h
+++ b/cooker/calls/process.h
@@ -1,4 +1,4 @@
-/* SPDX-License-Identifier: GPL-3.0-or-later
+/* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright 2023 Red Hat GmbH
* Author: Stefano Brivio <sbrivio@redhat.com>
*/