github.com/google/syzkaller@v0.0.0-20240517125934-c0f1611a36d6/sys/freebsd/pf.txt (about)

     1  # Copyright 2019 syzkaller project authors. All rights reserved.
     2  # Use of this source code is governed by Apache 2 LICENSE that can be found in the LICENSE file.
     3  
     4  include <sys/param.h>
     5  include <sys/socket.h>
     6  include <sys/counter.h>
     7  include <sys/cpuset.h>
     8  include <sys/lock.h>
     9  include <sys/rmlock.h>
    10  include <sys/mbuf.h>
    11  include <sys/ioccom.h>
    12  include <net/if.h>
    13  include <net/radix.h>
    14  include <net/vnet.h>
    15  include <netinet/in.h>
    16  include <netpfil/pf/pf.h>
    17  include <netpfil/pf/pf_mtag.h>
    18  
    19  include <net/pfvar.h>
    20  
    21  resource fd_pf[fd]
    22  
    23  openat$ptmx(fd const[AT_FDCWD], file ptr[in, string["/dev/pf"]], flags flags[open_flags], mode const[0]) fd_pf
    24  
    25  ioctl$DIOCADDRULE(fd fd_pf, cmd const[DIOCADDRULE], arg ptr[in, array[int8]])
    26  ioctl$DIOCGETRULES(fd fd_pf, cmd const[DIOCGETRULES], arg ptr[in, array[int8]])
    27  ioctl$DIOCGETSTATE(fd fd_pf, cmd const[DIOCGETSTATE], arg ptr[in, array[int8]])
    28  ioctl$DIOCSETSTATUSIF(fd fd_pf, cmd const[DIOCSETSTATUSIF], arg ptr[in, pfioc_if])
    29  ioctl$DIOCNATLOOK(fd fd_pf, cmd const[DIOCNATLOOK], arg ptr[in, array[int8]])
    30  ioctl$DIOCGETSTATES(fd fd_pf, cmd const[DIOCGETSTATES], arg ptr[in, array[int8]])
    31  ioctl$DIOCCHANGERULE(fd fd_pf, cmd const[DIOCCHANGERULE], arg ptr[in, array[int8]])
    32  ioctl$DIOCSETTIMEOUT(fd fd_pf, cmd const[DIOCSETTIMEOUT], arg ptr[in, pfioc_tm])
    33  ioctl$DIOCGETTIMEOUT(fd fd_pf, cmd const[DIOCGETTIMEOUT], arg ptr[in, pfioc_tm])
    34  ioctl$DIOCADDSTATE(fd fd_pf, cmd const[DIOCADDSTATE], arg ptr[in, array[int8]])
    35  ioctl$DIOCGETLIMIT(fd fd_pf, cmd const[DIOCGETLIMIT], arg ptr[in, pfioc_limit])
    36  ioctl$DIOCSETLIMIT(fd fd_pf, cmd const[DIOCSETLIMIT], arg ptr[in, pfioc_limit])
    37  ioctl$DIOCADDALTQV0(fd fd_pf, cmd const[DIOCADDALTQV0], arg ptr[in, array[int8]])
    38  ioctl$DIOCADDALTQV1(fd fd_pf, cmd const[DIOCADDALTQV1], arg ptr[in, array[int8]])
    39  ioctl$DIOCGETALTQSV0(fd fd_pf, cmd const[DIOCGETALTQSV0], arg ptr[in, array[int8]])
    40  ioctl$DIOCGETALTQSV1(fd fd_pf, cmd const[DIOCGETALTQSV1], arg ptr[in, array[int8]])
    41  ioctl$DIOCGETALTQV0(fd fd_pf, cmd const[DIOCGETALTQV0], arg ptr[in, array[int8]])
    42  ioctl$DIOCGETALTQV1(fd fd_pf, cmd const[DIOCGETALTQV1], arg ptr[in, array[int8]])
    43  ioctl$DIOCCHANGEALTQV0(fd fd_pf, cmd const[DIOCCHANGEALTQV0], arg ptr[in, array[int8]])
    44  ioctl$DIOCCHANGEALTQV1(fd fd_pf, cmd const[DIOCCHANGEALTQV1], arg ptr[in, array[int8]])
    45  ioctl$DIOCGETQSTATSV0(fd fd_pf, cmd const[DIOCGETQSTATSV0], arg ptr[in, array[int8]])
    46  ioctl$DIOCGETQSTATSV1(fd fd_pf, cmd const[DIOCGETQSTATSV1], arg ptr[in, array[int8]])
    47  ioctl$DIOCBEGINADDRS(fd fd_pf, cmd const[DIOCBEGINADDRS], arg ptr[in, array[int8]])
    48  ioctl$DIOCADDADDR(fd fd_pf, cmd const[DIOCADDADDR], arg ptr[in, array[int8]])
    49  ioctl$DIOCGETADDRS(fd fd_pf, cmd const[DIOCGETADDRS], arg ptr[in, array[int8]])
    50  ioctl$DIOCGETADDR(fd fd_pf, cmd const[DIOCGETADDR], arg ptr[in, array[int8]])
    51  ioctl$DIOCCHANGEADDR(fd fd_pf, cmd const[DIOCCHANGEADDR], arg ptr[in, array[int8]])
    52  ioctl$DIOCGETRULESETS(fd fd_pf, cmd const[DIOCGETRULESETS], arg ptr[in, array[int8]])
    53  ioctl$DIOCGETRULESET(fd fd_pf, cmd const[DIOCGETRULESET], arg ptr[in, array[int8]])
    54  ioctl$DIOCRCLRTABLES(fd fd_pf, cmd const[DIOCRCLRTABLES], arg ptr[in, pfioc_table])
    55  ioctl$DIOCRADDTABLES(fd fd_pf, cmd const[DIOCRADDTABLES], arg ptr[in, pfioc_table])
    56  ioctl$DIOCRDELTABLES(fd fd_pf, cmd const[DIOCRDELTABLES], arg ptr[in, pfioc_table])
    57  ioctl$DIOCRGETTABLES(fd fd_pf, cmd const[DIOCRGETTABLES], arg ptr[in, pfioc_table])
    58  ioctl$DIOCRGETTSTATS(fd fd_pf, cmd const[DIOCRGETTSTATS], arg ptr[in, pfioc_table])
    59  ioctl$DIOCRCLRTSTATS(fd fd_pf, cmd const[DIOCRCLRTSTATS], arg ptr[in, pfioc_table])
    60  ioctl$DIOCRSETTFLAGS(fd fd_pf, cmd const[DIOCRSETTFLAGS], arg ptr[in, pfioc_table])
    61  ioctl$DIOCRADDADDRS(fd fd_pf, cmd const[DIOCRADDADDRS], arg ptr[in, pfioc_table])
    62  ioctl$DIOCRDELADDRS(fd fd_pf, cmd const[DIOCRDELADDRS], arg ptr[in, pfioc_table])
    63  ioctl$DIOCRSETADDRS(fd fd_pf, cmd const[DIOCRSETADDRS], arg ptr[in, pfioc_table])
    64  ioctl$DIOCRGETADDRS(fd fd_pf, cmd const[DIOCRGETADDRS], arg ptr[in, pfioc_table])
    65  ioctl$DIOCRTSTADDRS(fd fd_pf, cmd const[DIOCRTSTADDRS], arg ptr[in, pfioc_table])
    66  ioctl$DIOCRGETASTATS(fd fd_pf, cmd const[DIOCRGETASTATS], arg ptr[in, pfioc_table])
    67  ioctl$DIOCRCLRASTATS(fd fd_pf, cmd const[DIOCRCLRASTATS], arg ptr[in, pfioc_table])
    68  ioctl$DIOCRINADEFINE(fd fd_pf, cmd const[DIOCRINADEFINE], arg ptr[in, pfioc_table])
    69  ioctl$DIOCOSFPADD(fd fd_pf, cmd const[DIOCOSFPADD], arg ptr[in, array[int8]])
    70  ioctl$DIOCOSFPGET(fd fd_pf, cmd const[DIOCOSFPGET], arg ptr[in, array[int8]])
    71  ioctl$DIOCXBEGIN(fd fd_pf, cmd const[DIOCXBEGIN], arg ptr[in, array[int8]])
    72  ioctl$DIOCXCOMMIT(fd fd_pf, cmd const[DIOCXCOMMIT], arg ptr[in, array[int8]])
    73  ioctl$DIOCXROLLBACK(fd fd_pf, cmd const[DIOCXROLLBACK], arg ptr[in, array[int8]])
    74  ioctl$DIOCGETSRCNODES(fd fd_pf, cmd const[DIOCGETSRCNODES], arg ptr[in, array[int8]])
    75  ioctl$DIOCIGETIFACES(fd fd_pf, cmd const[DIOCIGETIFACES], arg ptr[in, pfioc_iface])
    76  ioctl$DIOCSETIFFLAG(fd fd_pf, cmd const[DIOCSETIFFLAG], arg ptr[in, pfioc_iface])
    77  ioctl$DIOCCLRIFFLAG(fd fd_pf, cmd const[DIOCCLRIFFLAG], arg ptr[in, pfioc_iface])
    78  ioctl$DIOCKILLSRCNODES(fd fd_pf, cmd const[DIOCKILLSRCNODES], arg ptr[in, array[int8]])
    79  
    80  pfioc_if {
    81  	ifname	const[IFNAMSIZ, int8]
    82  }
    83  
    84  pfioc_tm {
    85  	timeout	int32
    86  	seconds	int32
    87  }
    88  
    89  pfioc_limit {
    90  	index	int32
    91  	limit	int32
    92  }
    93  
    94  pfr_table {
    95  	pfrt_anchor	array[int8, MAXPATHLEN]
    96  	pfrt_name	array[int8, PF_TABLE_NAME_SIZE]
    97  	pfrt_flags	int32
    98  	pfrt_fback	int8
    99  }
   100  
   101  pfioc_table {
   102  	pfrio_table	pfr_table
   103  	pfrio_buffer	ptr[in, array[int8]]
   104  	pfrio_esize	int64
   105  	pfrio_size	int64
   106  	pfrio_size2	int64
   107  	pfrio_nadd	int64
   108  	pfrio_ndel	int64
   109  	pfrio_nchange	int64
   110  	pfrio_flags	int64
   111  	pfrio_ticket	int32
   112  }
   113  
   114  pfioc_iface {
   115  	pfiio_name	const[IFNAMSIZ, int8]
   116  	pfiio_buffer	ptr[in, array[int8]]
   117  	pfiio_esize	int32
   118  	pfiio_size	int32
   119  	pfiio_flags	int32
   120  }