History log of /src/sys/compat/netbsd32/netbsd32_compat_50.c |
Revision | | Date | Author | Comments |
1.56 |
| 29-Jul-2023 |
rin | COMPAT_NETBSD32: Reorganize the previous; Make compat_netbsd32_50 recursively depended on compat_netbsd32_100, rather than directly depended on it.
Thanks pgoyette@ again for useful comments!
|
1.55 |
| 29-Jul-2023 |
rin | Now, netbsd32_compat_50 module requires netbsd32_compat_100. Thanks pgoyette@ for hints.
|
1.54 |
| 29-Jul-2023 |
rin | COMPAT_NETBSD32: Catch up with sys___kevent100() addition.
XXX Add epoll_* and memfd_create.
|
1.53 |
| 26-Oct-2022 |
riastradh | sys: Put externs for time_adjtime and time_adjusted in .h files.
time_adjtime: sys/timex.h (defined in ntp code) time_adjusted: sys/timevar.h (defined in non-ntp code)
(Not really sure this is a valuable distinction to maintain; there's non-ntp code that uses time_adjtime too.)
|
1.52 |
| 07-Sep-2021 |
riastradh | sys/compat: Memset zero before copyout.
Just in case of uninitialized padding which would lead to kernel stack disclosure. If the compiler can prove the memset redundant then it can optimize it away; otherwise better safe than sorry.
|
1.51 |
| 18-Feb-2021 |
simonb | In the compat setitimer(2) calls, don't validate which timer is being used since dosetitimer() does this anyway. The compat functions hadn't been updated since ITIMER_MONOTONIC was introduced, so they reported that that ITIMER_MONOTONIC timer was invalid.
|
1.50 |
| 19-Jan-2021 |
simonb | KNF consistency: No parentheses are needed around the return value.
|
1.49 |
| 30-Apr-2020 |
riastradh | branches: 1.49.2; Omit needless #include <sys/rnd.h>.
|
1.48 |
| 15-Mar-2020 |
pgoyette | Now that we have split the quota code out of the compat_netbsd32_50 module, it no longer depends on compat_50_quota.
Should address PR kern/55073
|
1.47 |
| 12-Mar-2020 |
pgoyette | Split out the quota code from the rest of compat_netbsd32 module. This allows loading of compat_netbsd32 on kernels that don't have ``options QUOTA'' enabled.
|
1.46 |
| 27-Feb-2020 |
pgoyette | Module compat_netbsd32_50 requires module compat_50_quota
|
1.45 |
| 29-Jan-2020 |
ad | - Track LWPs in a per-process radixtree. It uses no extra memory in the single threaded case. Replace scans of p->p_lwps with lookups in the tree. Find free LIDs for new LWPs in the tree. Replace the hashed sleep queues for park/unpark with lookups in the tree under cover of a RW lock.
- lwp_wait(): if waiting on a specific LWP, find the LWP via tree lookup and return EINVAL if it's detached, not ESRCH.
- Group the locks in struct proc at the end of the struct in their own cache line.
- Add some comments.
|
1.44 |
| 01-Jan-2020 |
maxv | branches: 1.44.2; Fix three stack info leaks, found by kMSan when just invoking all syscalls with a zero page as argument.
MSan: Uninitialized Stack Memory In copyout() At Offset 0, Variable 'sb32' From compat_20_netbsd32_getfsstat() MSan: Uninitialized Stack Memory In copyout() At Offset 12, Variable 'oss' From compat_43_sys_sigstack() MSan: Uninitialized Stack Memory In copyout() At Offset 0, Variable 'sb' From compat_50_netbsd32___fhstat40()
|
1.43 |
| 15-Dec-2019 |
tsutsui | Remove clause 3 and 4 leftovers from TNF licenses in more sources.
Confirmed by martin@ in PR/54760.
|
1.42 |
| 12-Dec-2019 |
pgoyette | Rather than keeping a separate mutex, condvar, and pserialize for each module hook, we can share a common set of synchronization structures. This cuts the amount of cacheline_aligned data for these structures by 50%.
Note that we still have a per-hook localcount, since we need to count individual references.
As discussed with riastradh@
Welcome to 9.99.22 !
|
1.41 |
| 05-Oct-2019 |
kamil | Validate input before converting timeval::tv_usec in compat/netbsd32
|
1.40 |
| 20-Sep-2019 |
kamil | Validate usec ranges in compat_50_netbsd32_select()
Later in the code selcommon() checks for proper timespec, check only correct usec of timeval before type conversions.
|
1.39 |
| 27-Jun-2019 |
christos | branches: 1.39.2; Include the right stuff so compat_netbsd32_50 compiles.
|
1.38 |
| 18-Jun-2019 |
kamil | Drop unused retval pointer from do_sys_mknod{,at}()
No functional change intended.
|
1.37 |
| 18-Jun-2019 |
christos | regen
|
1.36 |
| 01-Mar-2019 |
pgoyette | Rename the MODULE_*_HOOK() macros to MODULE_HOOK_*() as briefly discussed on irc.
NFCI intended.
Ride the earlier kernel bump - it;s getting crowded.
|
1.35 |
| 29-Jan-2019 |
pgoyette | Normalize all the compat hooks' names to the form
<subsystem>_<function>_<version>_hook
NFCI
XXX Note that although this introduces a change in the kernel-to- XXX module interface, we are NOT bumping the kernel version number. XXX We will bump the version number once the interface stabilizes.
|
1.34 |
| 27-Jan-2019 |
pgoyette | Merge the [pgoyette-compat] branch
|
1.33 |
| 26-Dec-2018 |
mrg | remove duplicated prototypes and dated XXX comments.
|
1.32 |
| 03-Dec-2015 |
pgoyette | branches: 1.32.10; 1.32.16; 1.32.18; Split out the SYSV IPC stuff into its own compat_netbsd32_sysvipc module. Adjust dependencies as needed.
|
1.31 |
| 01-Dec-2015 |
pgoyette | Prepare for new compat_netbsd32_mqueue module to be split out of compat_netbsd32. Refactor the COMPAT_50 code related to mqueue, and update the syscall definitions. Remove dependency on mqueue from the compat_netbsd32 module (the new module will gain this dependency).
Continuation of work on PR kern/50489
|
1.30 |
| 24-Jul-2015 |
maxv | Unused inits (harmless).
Found by Brainy.
|
1.29 |
| 21-Jun-2015 |
martin | Move compat calls, requested by mrg@
|
1.28 |
| 27-Oct-2014 |
christos | branches: 1.28.2; fix multiple mistakes: - error from copyout was ignored - the wrong size was specified in copyin - missing locking.
|
1.27 |
| 05-Sep-2014 |
matt | Try not to use f_data, use f_{vnode,socket,pipe,mqueue,kqueue,ksem} to get a correctly typed pointer.
|
1.26 |
| 05-Sep-2014 |
matt | Don't use private as a variable name since it's reserved in C++
|
1.25 |
| 21-Aug-2014 |
maxv | Remove dead returns:
return VAR/func(XX); return VAR;
The latter is never reached. Sent on tech-kern@, no disagreement.
|
1.24 |
| 24-Jun-2014 |
maxv | branches: 1.24.2; Allocate directly KQ_NEVENTS bytes. Otherwise a user can panic the system.
ok christos@
|
1.23 |
| 29-Mar-2013 |
christos | branches: 1.23.8; compat glue for new lwp_park
|
1.22 |
| 03-Nov-2012 |
njoly | Move rusage computation to a new getrusage1() function. Adjust all compat/emulations to make use of it.
|
1.21 |
| 02-Oct-2012 |
christos | kernel portion of clock_nanosleep()
|
1.20 |
| 18-Nov-2011 |
christos | branches: 1.20.6; 1.20.10; 1.20.12; 1.20.14; add a copyin function for sigset so that we can use sigtimedwait1 from emulations.
|
1.19 |
| 23-May-2011 |
joerg | branches: 1.19.4; Update from GNU extension to C99 syntax for designated initializer
|
1.18 |
| 06-Mar-2011 |
bouyer | merge the bouyer-quota2 branch. This adds a new on-disk format to store disk quota usage and limits, integrated with ffs metadata. Usage is checked by fsck_ffs (no more quotacheck) and is covered by the WAPBL journal. Enabled with kernel option QUOTA2 (added where QUOTA was enabled in kernel config files), turned on with tunefs(8) on a per-filesystem basis. mount_mfs(8) can also turn quotas on.
See http://mail-index.netbsd.org/tech-kern/2011/02/19/msg010025.html for details.
|
1.17 |
| 30-May-2010 |
drochner | branches: 1.17.2; 1.17.4; -fix internal use of sigwaitinfo(2) by sigwait(3): The former returns the signal number now, as required by POSIX. The latter should just return 0 on success. Fixes a mysql problem reported by Kurt Schreiner. -document the new behavior of sigwaitinfo and sigtimedwait -retain non-POSIX behavior for NetBSD-5 binary compatibility -- the fix would likely not be polled into the .0-branches, and having 5.0.x and 5.x behave differently would be confusing. Besides that, it was documented in the manpage all the time.
|
1.16 |
| 23-Apr-2010 |
rmind | Replace M_IOV and some malloc(9)s with kmem(9), and while there: - Fix invalid free (M_TEMP vs M_IOV) in do_sys_recvmsg(), spotted by jakllsch@. Also, same fix in osf1_sys_sendmsg_xopen(). - Fix attempt to free non-allocated memory in error path in netbsd32___getfh30(). - Plug a memory leak in compat_43_netbsd32_orecvmsg().
|
1.15 |
| 08-Apr-2010 |
njoly | Add a new clock_gettime1() function that holds most of the clock_gettime syscall code (except for the copyout). Adjust all corresponding syscalls to make use of it.
|
1.14 |
| 03-Apr-2010 |
njoly | Move most clock_getres syscall code, except for coypout call, to a new clock_getres1() function which can be used by emulations. Adjust all clock_getres syscalls to now make of use it.
|
1.13 |
| 29-Mar-2010 |
njoly | Convert linux/linux32/netbsd32 clock_settime syscalls, to use the common clock_settime1() function.
|
1.12 |
| 29-Mar-2010 |
njoly | Make compat netbsd32 clock_getres copyout the netbsd32 timespec structure, not the native one.
|
1.11 |
| 28-Mar-2010 |
njoly | Cleanup compat netbsd32 nanosleep syscalls to use the common nanosleep1() call instead of their own stuff.
|
1.10 |
| 02-Mar-2010 |
pooka | branches: 1.10.2; regen for conditional lfs syscall removal
|
1.9 |
| 19-Jan-2010 |
pooka | branches: 1.9.2; A few more instances of __sigtimedwait1 -> sigtimedwait1
|
1.8 |
| 21-Dec-2009 |
njoly | Do not include fs_lfs.h unless _KERNEL_OPT is defined.
|
1.7 |
| 11-Nov-2009 |
rmind | - selcommon/pollcommon: drop redundant l argument. - Use cached curlwp->l_fd, instead of p->p_fd. - Inline selscan/pollscan.
|
1.6 |
| 04-Nov-2009 |
rmind | do_sys_wait(): fix previous by checking for ru != NULL. Noticed by Onno van der Linden. Also, remove redundant arguments (seems that was_zombie was not used since rev 1.177 ?).
|
1.5 |
| 09-Aug-2009 |
haad | Add enum uio_seg argument to do_sys_mknod and do_sys_mkdir so these functions can be called from kernel, too.
Change needed for zfs device node creation, until we have propoer devfs.
Oked by ad@.
|
1.4 |
| 29-Mar-2009 |
christos | branches: 1.4.2; Move the internal poll/select related API's to use timespec instead of timeval (rides the uvm bump).
|
1.3 |
| 26-Jan-2009 |
njoly | branches: 1.3.2; Make all fstat(2) compat syscalls consistently use do_sys_fstat(), instead of fd_getfile()/fd_putfile() dance.
ok by christos.
|
1.2 |
| 11-Jan-2009 |
christos | branches: 1.2.2; 1.2.4; merge christos-time_t
|
1.1 |
| 04-Jan-2009 |
christos | branches: 1.1.2; file netbsd32_compat_50.c was initially added on branch christos-time_t.
|
1.1.2.1 |
| 04-Jan-2009 |
christos | add new syscalls.
|
1.2.4.4 |
| 28-Apr-2009 |
skrll | Sync with HEAD.
|
1.2.4.3 |
| 03-Mar-2009 |
skrll | Sync with HEAD.
|
1.2.4.2 |
| 19-Jan-2009 |
skrll | Sync with HEAD.
|
1.2.4.1 |
| 11-Jan-2009 |
skrll | file netbsd32_compat_50.c was added on branch nick-hppapmap on 2009-01-19 13:17:36 +0000
|
1.2.2.2 |
| 17-Jan-2009 |
mjf | Sync with HEAD.
|
1.2.2.1 |
| 11-Jan-2009 |
mjf | file netbsd32_compat_50.c was added on branch mjf-devfs2 on 2009-01-17 13:28:46 +0000
|
1.3.2.1 |
| 13-May-2009 |
jym | Sync with HEAD.
Commit is split, to avoid a "too many arguments" protocol error.
|
1.4.2.5 |
| 11-Aug-2010 |
yamt | sync with head.
|
1.4.2.4 |
| 11-Mar-2010 |
yamt | sync with head
|
1.4.2.3 |
| 19-Aug-2009 |
yamt | sync with head.
|
1.4.2.2 |
| 04-May-2009 |
yamt | sync with head.
|
1.4.2.1 |
| 29-Mar-2009 |
yamt | file netbsd32_compat_50.c was added on branch yamt-nfs-mp on 2009-05-04 08:12:25 +0000
|
1.9.2.2 |
| 17-Aug-2010 |
uebayasi | Sync with HEAD.
|
1.9.2.1 |
| 30-Apr-2010 |
uebayasi | Sync with HEAD.
|
1.10.2.4 |
| 31-May-2011 |
rmind | sync with head
|
1.10.2.3 |
| 21-Apr-2011 |
rmind | sync with head
|
1.10.2.2 |
| 03-Jul-2010 |
rmind | sync with head
|
1.10.2.1 |
| 30-May-2010 |
rmind | sync with head
|
1.17.4.1 |
| 15-Feb-2011 |
bouyer | implement COMPAT_NETBSD32 quotactl syscalls (both new and COMPAT_50)
|
1.17.2.1 |
| 06-Jun-2011 |
jruoho | Sync with HEAD.
|
1.19.4.4 |
| 22-May-2014 |
yamt | sync with head.
for a reference, the tree before this commit was tagged as yamt-pagecache-tag8.
this commit was splitted into small chunks to avoid a limitation of cvs. ("Protocol error: too many arguments")
|
1.19.4.3 |
| 16-Jan-2013 |
yamt | sync with (a bit old) head
|
1.19.4.2 |
| 30-Oct-2012 |
yamt | sync with head
|
1.19.4.1 |
| 17-Apr-2012 |
yamt | sync with head
|
1.20.14.2 |
| 09-Nov-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1179): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.28 fix multiple mistakes: - error from copyout was ignored - the wrong size was specified in copyin - missing locking.
|
1.20.14.1 |
| 30-Jun-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1090): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.24 sys/compat/netbsd32/netbsd32_event.c: revision 1.11 Allocate directly KQ_NEVENTS bytes. Otherwise a user can panic the system. ok christos@
|
1.20.12.2 |
| 09-Nov-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1179): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.28 fix multiple mistakes: - error from copyout was ignored - the wrong size was specified in copyin - missing locking.
|
1.20.12.1 |
| 30-Jun-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1090): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.24 sys/compat/netbsd32/netbsd32_event.c: revision 1.11 Allocate directly KQ_NEVENTS bytes. Otherwise a user can panic the system. ok christos@
|
1.20.10.4 |
| 03-Dec-2017 |
jdolecek | update from HEAD
|
1.20.10.3 |
| 20-Aug-2014 |
tls | Rebase to HEAD as of a few days ago.
|
1.20.10.2 |
| 23-Jun-2013 |
tls | resync from head
|
1.20.10.1 |
| 20-Nov-2012 |
tls | Resync to 2012-11-19 00:00:00 UTC
|
1.20.6.2 |
| 09-Nov-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1179): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.28 fix multiple mistakes: - error from copyout was ignored - the wrong size was specified in copyin - missing locking.
|
1.20.6.1 |
| 30-Jun-2014 |
msaitoh | Pull up following revision(s) (requested by maxv in ticket #1090): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.24 sys/compat/netbsd32/netbsd32_event.c: revision 1.11 Allocate directly KQ_NEVENTS bytes. Otherwise a user can panic the system. ok christos@
|
1.23.8.1 |
| 10-Aug-2014 |
tls | Rebase.
|
1.24.2.2 |
| 21-Jan-2020 |
martin | Pull up the following, requested by christos in ticket #1720:
sys/compat/common/kern_sig_43.c 1.36 sys/compat/linux/arch/amd64/linux_machdep.c 1.59 sys/compat/linux/common/linux_fcntl.h 1.18 sys/compat/linux/common/linux_file64.c 1.62 sys/compat/linux/common/linux_ipc.c 1.57 sys/compat/linux/common/linux_misc.c 1.243 sys/compat/linux/common/linux_signal.c 1.81 sys/compat/linux/common/linux_socket.c 1.149 (patch) sys/compat/linux/common/linux_socket.h 1.24 sys/compat/linux/common/linux_statfs.h 1.7 sys/compat/linux/common/linux_termios.c 1.38 sys/compat/linux/common/linux_termios.h 1.22 sys/compat/linux32/common/linux32_dirent.c 1.20 sys/compat/linux32/common/linux32_ioctl.c 1.14 sys/compat/linux32/common/linux32_misc.c 1.27 sys/compat/linux32/common/linux32_signal.c 1.20 sys/compat/linux32/common/linux32_sysinfo.c 1.8 sys/compat/linux32/common/linux32_termios.c 1.15 sys/compat/linux32/common/linux32_utsname.c 1.10 sys/compat/netbsd32/netbsd32_compat_20.c 1.39 sys/compat/netbsd32/netbsd32_compat_43.c 1.59 sys/compat/netbsd32/netbsd32_compat_50.c 1.44 sys/compat/ossaudio/ossaudio.c 1.75 sys/kern/sysv_shm.c 1.138 sys/miscfs/procfs/procfs_linux.c 1.75 (patch) sys/sys/shm.h 1.54 (patch)
Fix various info leaks, out of bound access, usage of uninitialized values and direct access to userland variables from kernel space and memory leaks in system calls implemented for the compatibility subsystems.
|
1.24.2.1 |
| 30-Oct-2014 |
martin | branches: 1.24.2.1.6; Pull up following revision(s) (requested by maxv in ticket #166): sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.28 fix multiple mistakes: - error from copyout was ignored - the wrong size was specified in copyin - missing locking.
|
1.24.2.1.6.1 |
| 21-Jan-2020 |
martin | Pull up the following, requested by christos in ticket #1720:
sys/compat/common/kern_sig_43.c 1.36 sys/compat/linux/arch/amd64/linux_machdep.c 1.59 sys/compat/linux/common/linux_fcntl.h 1.18 sys/compat/linux/common/linux_file64.c 1.62 sys/compat/linux/common/linux_ipc.c 1.57 sys/compat/linux/common/linux_misc.c 1.243 sys/compat/linux/common/linux_signal.c 1.81 sys/compat/linux/common/linux_socket.c 1.149 (patch) sys/compat/linux/common/linux_socket.h 1.24 sys/compat/linux/common/linux_statfs.h 1.7 sys/compat/linux/common/linux_termios.c 1.38 sys/compat/linux/common/linux_termios.h 1.22 sys/compat/linux32/common/linux32_dirent.c 1.20 sys/compat/linux32/common/linux32_ioctl.c 1.14 sys/compat/linux32/common/linux32_misc.c 1.27 sys/compat/linux32/common/linux32_signal.c 1.20 sys/compat/linux32/common/linux32_sysinfo.c 1.8 sys/compat/linux32/common/linux32_termios.c 1.15 sys/compat/linux32/common/linux32_utsname.c 1.10 sys/compat/netbsd32/netbsd32_compat_20.c 1.39 sys/compat/netbsd32/netbsd32_compat_43.c 1.59 sys/compat/netbsd32/netbsd32_compat_50.c 1.44 sys/compat/ossaudio/ossaudio.c 1.75 sys/kern/sysv_shm.c 1.138 sys/miscfs/procfs/procfs_linux.c 1.75 (patch) sys/sys/shm.h 1.54 (patch)
Fix various info leaks, out of bound access, usage of uninitialized values and direct access to userland variables from kernel space and memory leaks in system calls implemented for the compatibility subsystems.
|
1.28.2.2 |
| 27-Dec-2015 |
skrll | Sync with HEAD (as of 26th Dec)
|
1.28.2.1 |
| 22-Sep-2015 |
skrll | Sync with HEAD
|
1.32.18.2 |
| 13-Apr-2020 |
martin | Mostly merge changes from HEAD upto 20200411
|
1.32.18.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|
1.32.16.16 |
| 23-Jan-2019 |
pgoyette | Convert the macros for setting and unsetting a hook to generate in-line code rather than using an intermediary hook##set routine. Hooks are set and unset only in one place, so the intermediary routine provides no benefit. IMHO using the macro at the point- of-call is more readable than using it elsewhere in the code and then calling the generated intermediary routine (for which you won't even find its declaration or definition unless you remember to search for the HOOK_SET macro instead).
NFC intended, will verify with a bulk build and an atf test run.
|
1.32.16.15 |
| 26-Dec-2018 |
pgoyette | Sync with HEAD, resolve a few conflicts
|
1.32.16.14 |
| 26-Nov-2018 |
pgoyette | Sync with HEAD, resolve a couple of conflicts
|
1.32.16.13 |
| 12-Oct-2018 |
pgoyette | Use a MP-safe hook for the rnd_ioctl compat_50 calls.
|
1.32.16.12 |
| 03-Oct-2018 |
pgoyette | Normalize the required lists. Each compat_netbsd32_xx needs the non-32bit module of the same version _and_ the 32-bit module for the next higher version.
|
1.32.16.11 |
| 03-Oct-2018 |
pgoyette | Make sure that each version-specific compat_netbsd32_xx module depends on all higher-version-specific modules, similar to the non-32bit compat_xx modules.
|
1.32.16.10 |
| 25-Sep-2018 |
pgoyette | Additional use of NTP function pointers, since the NTP code might not exist in the kernel. (NTP is not (yet) a module, so we don't need to use the MP-safe mechanism.)
|
1.32.16.9 |
| 23-Sep-2018 |
pgoyette | Be selective about including the NTP syscall ntp_gettime
|
1.32.16.8 |
| 11-Sep-2018 |
pgoyette | Move the NTP compat_30 and compat_50 routines into the version-specific modules.
|
1.32.16.7 |
| 11-Sep-2018 |
pgoyette | Move netbsd32_rndpseudo_50.c out of the main netbsd32 module and into the module that handles netbsd32_50 compatability.
|
1.32.16.6 |
| 11-Sep-2018 |
pgoyette | Put the ``extern struct emul'' into the netbsd32_netbsd.h header so it doesn't have to be separately declared in each source file.
Thanks mrg@
|
1.32.16.5 |
| 11-Sep-2018 |
pgoyette | Also need to declare the emul_netbsd32 !
|
1.32.16.4 |
| 11-Sep-2018 |
pgoyette | Install the syscalls into the netbsd32 table, not the default/native table.
|
1.32.16.3 |
| 11-Sep-2018 |
pgoyette | Use netbsd32 syscall names in the establish/disestablish tables
|
1.32.16.2 |
| 11-Sep-2018 |
pgoyette | Regen syscall files and fix includes for syscallvar.h
|
1.32.16.1 |
| 10-Sep-2018 |
pgoyette | More work on splitting the compat_netbsd32 module
|
1.32.10.2 |
| 21-Jun-2023 |
martin | Pull up following revision(s) (requested by riastradh in ticket #1836):
sys/compat/linux/arch/i386/linux_machdep.c: revision 1.168 sys/compat/sunos/sunos_misc.c: revision 1.177 sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.52 sys/compat/common/kern_resource_43.c: revision 1.23 sys/compat/netbsd32/netbsd32_conv.h: revision 1.46 sys/compat/linux/arch/i386/linux_ptrace.c: revision 1.35 sys/compat/common/vfs_syscalls_12.c: revision 1.38 sys/compat/ultrix/ultrix_misc.c: revision 1.126 sys/compat/common/kern_sig_43.c: revision 1.37 sys/compat/linux/common/linux_mtio.c: revision 1.8 sys/compat/freebsd/freebsd_misc.c: revision 1.34 sys/compat/linux/common/linux_olduname.c: revision 1.67 sys/compat/linux/arch/mips/linux_machdep.c: revision 1.44 sys/compat/freebsd/freebsd_sched.c: revision 1.23 sys/compat/ossaudio/ossaudio.c: revision 1.84 sys/compat/sys/time_types.h: revision 1.6 sys/compat/linux/arch/powerpc/linux_machdep.c: revision 1.51 sys/compat/linux/common/linux_file.c: revision 1.119 sys/compat/linux/arch/arm/linux_machdep.c: revision 1.34 sys/compat/netbsd32/netbsd32_wait.c: revision 1.25 sys/compat/linux32/common/linux32_time.c: revision 1.38 sys/compat/linux/arch/powerpc/linux_ptrace.c: revision 1.33 sys/compat/linux/arch/alpha/linux_machdep.c: revision 1.52 sys/compat/linux32/arch/amd64/linux32_machdep.c: revision 1.46 sys/compat/netbsd32/netbsd32_compat_12.c: revision 1.36 sys/compat/ultrix/ultrix_ioctl.c: revision 1.39 sys/compat/linux/common/linux_misc.c: revision 1.252 sys/compat/linux/common/linux_hdio.c: revision 1.19 sys/compat/sunos/sunos_ioctl.c: revision 1.71 sys/compat/linux/common/linux_sched.c: revision 1.79 sys/compat/common/kern_info_43.c: revision 1.40 sys/compat/linux32/common/linux32_exec_elf32.c: revision 1.20 sys/compat/linux/common/linux_socket.c: revision 1.153 sys/compat/linux/arch/amd64/linux_machdep.c: revision 1.60 sys/compat/common/vfs_syscalls_43.c: revision 1.68 sys/compat/linux/arch/powerpc/linux_exec_powerpc.c: revision 1.25 sys/compat/netbsd32/netbsd32_ptrace.c: revision 1.9 sys/compat/common/kern_time_50.c: revision 1.37 sys/compat/netbsd32/netbsd32_compat_20.c: revision 1.42 sys/compat/linux/common/linux_cdrom.c: revision 1.28 sys/compat/linux/arch/m68k/linux_machdep.c: revision 1.43 sys/compat/common/kern_info_09.c: revision 1.22 sys/compat/linux32/common/linux32_resource.c: revision 1.12 sys/compat/linux/common/linux_oldolduname.c: revision 1.67 sys/compat/netbsd32/netbsd32_nfssvc.c: revision 1.8 sys/compat/linux32/common/linux32_signal.c: revision 1.21 sys/compat/common/kern_sig_13.c: revision 1.22 sys/compat/sunos32/sunos32_ioctl.c: revision 1.36 sys/compat/netbsd32/netbsd32_compat_43.c: revision 1.62 sys/compat/linux/arch/arm/linux_ptrace.c: revision 1.23 sys/compat/netbsd32/netbsd32_time.c: revision 1.56 sys/compat/linux/common/linux_signal.c: revision 1.84 sys/compat/netbsd32/netbsd32_signal.c: revision 1.52 sys/compat/sunos32/sunos32_misc.c: revision 1.85 sys/compat/linux/common/linux_time.c: revision 1.40 sys/compat/linux/common/linux_fdio.c: revision 1.14 sys/compat/common/vfs_syscalls_30.c: revision 1.43
sys/compat: Memset zero before copyout.
Just in case of uninitialized padding which would lead to kernel stack disclosure. If the compiler can prove the memset redundant then it can optimize it away; otherwise better safe than sorry.
|
1.32.10.1 |
| 21-Jan-2020 |
martin | Pull up the following, requested by christos in ticket #1487:
sys/compat/common/kern_sig_43.c 1.36 sys/compat/linux/arch/amd64/linux_machdep.c 1.59 sys/compat/linux/common/linux_fcntl.h 1.18 sys/compat/linux/common/linux_file64.c 1.62 sys/compat/linux/common/linux_ipc.c 1.57 sys/compat/linux/common/linux_misc.c 1.243 sys/compat/linux/common/linux_signal.c 1.81 sys/compat/linux/common/linux_socket.c 1.149 sys/compat/linux/common/linux_socket.h 1.24 sys/compat/linux/common/linux_statfs.h 1.7 sys/compat/linux/common/linux_termios.c 1.38 sys/compat/linux/common/linux_termios.h 1.22 sys/compat/linux32/common/linux32_dirent.c 1.20 sys/compat/linux32/common/linux32_ioctl.c 1.14 sys/compat/linux32/common/linux32_misc.c 1.27 sys/compat/linux32/common/linux32_signal.c 1.20 sys/compat/linux32/common/linux32_sysinfo.c 1.8 sys/compat/linux32/common/linux32_termios.c 1.15 sys/compat/linux32/common/linux32_utsname.c 1.10 sys/compat/netbsd32/netbsd32_compat_20.c 1.39 sys/compat/netbsd32/netbsd32_compat_43.c 1.59 sys/compat/netbsd32/netbsd32_compat_50.c 1.44 sys/compat/ossaudio/ossaudio.c 1.75 sys/kern/sysv_shm.c 1.138 sys/miscfs/procfs/procfs_linux.c 1.75 (patch) sys/sys/shm.h 1.54
Fix various info leaks, out of bound access, usage of uninitialized values and direct access to userland variables from kernel space and memory leaks in system calls implemented for the compatibility subsystems.
|
1.39.2.3 |
| 03-Aug-2022 |
martin | Pull up following revision(s), all via patch (requested by riastradh in ticket #1487):
sys/compat/linux/arch/i386/linux_machdep.c: revision 1.168 sys/compat/sunos/sunos_misc.c: revision 1.177 sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.52 sys/compat/common/kern_resource_43.c: revision 1.23 sys/compat/netbsd32/netbsd32_conv.h: revision 1.46 sys/compat/linux/arch/i386/linux_ptrace.c: revision 1.35 sys/compat/common/vfs_syscalls_12.c: revision 1.38 sys/compat/ultrix/ultrix_misc.c: revision 1.126 sys/compat/common/kern_sig_43.c: revision 1.37 sys/compat/linux/common/linux_mtio.c: revision 1.8 sys/compat/freebsd/freebsd_misc.c: revision 1.34 sys/compat/freebsd/freebsd_machdep.c: revision 1.5 sys/compat/linux/common/linux_olduname.c: revision 1.67 sys/compat/linux/arch/mips/linux_machdep.c: revision 1.44 sys/compat/freebsd/freebsd_sched.c: revision 1.23 sys/compat/ossaudio/ossaudio.c: revision 1.84 sys/compat/sys/time_types.h: revision 1.6 sys/compat/linux/arch/powerpc/linux_machdep.c: revision 1.51 sys/compat/common/ieee80211_20.c: revision 1.7 sys/compat/linux/common/linux_file.c: revision 1.119 sys/compat/linux/arch/arm/linux_machdep.c: revision 1.34 sys/compat/netbsd32/netbsd32_wait.c: revision 1.25 sys/compat/linux32/common/linux32_time.c: revision 1.38 sys/compat/linux/arch/powerpc/linux_ptrace.c: revision 1.33 sys/compat/linux/arch/alpha/linux_machdep.c: revision 1.52 sys/compat/linux32/arch/amd64/linux32_machdep.c: revision 1.46 sys/compat/netbsd32/netbsd32_compat_12.c: revision 1.36 sys/compat/ultrix/ultrix_ioctl.c: revision 1.39 sys/compat/linux/common/linux_misc.c: revision 1.252 sys/compat/linux/common/linux_hdio.c: revision 1.19 sys/compat/sunos/sunos_ioctl.c: revision 1.71 sys/compat/linux/common/linux_sched.c: revision 1.79 sys/compat/common/kern_info_43.c: revision 1.40 sys/compat/linux32/common/linux32_exec_elf32.c: revision 1.20 sys/compat/linux/common/linux_socket.c: revision 1.153 sys/compat/linux/arch/amd64/linux_machdep.c: revision 1.60 sys/compat/common/vfs_syscalls_43.c: revision 1.68 sys/compat/linux/arch/powerpc/linux_exec_powerpc.c: revision 1.25 sys/compat/netbsd32/netbsd32_ptrace.c: revision 1.9 sys/compat/common/kern_time_50.c: revision 1.37 sys/compat/netbsd32/netbsd32_compat_20.c: revision 1.42 sys/compat/linux/common/linux_cdrom.c: revision 1.28 sys/compat/linux/arch/m68k/linux_machdep.c: revision 1.43 sys/compat/common/kern_info_09.c: revision 1.22 sys/compat/linux32/common/linux32_resource.c: revision 1.12 sys/compat/linux/common/linux_oldolduname.c: revision 1.67 sys/compat/common/if_media_80.c: revision 1.4 sys/compat/linux/arch/alpha/linux_osf1.c: revision 1.5 sys/compat/netbsd32/netbsd32_nfssvc.c: revision 1.8 sys/compat/linux32/common/linux32_signal.c: revision 1.21 sys/compat/common/kern_sig_13.c: revision 1.22 sys/compat/sunos32/sunos32_ioctl.c: revision 1.36 sys/compat/netbsd32/netbsd32_compat_43.c: revision 1.62 sys/compat/linux/arch/arm/linux_ptrace.c: revision 1.23 sys/compat/netbsd32/netbsd32_time.c: revision 1.56 sys/compat/linux/common/linux_signal.c: revision 1.84 sys/compat/netbsd32/netbsd32_signal.c: revision 1.52 sys/compat/sunos32/sunos32_misc.c: revision 1.85 sys/compat/linux/common/linux_time.c: revision 1.40 sys/compat/linux/common/linux_fdio.c: revision 1.14 sys/compat/common/vfs_syscalls_30.c: revision 1.43
sys/compat: Memset zero before copyout.
Just in case of uninitialized padding which would lead to kernel stack disclosure. If the compiler can prove the memset redundant then it can optimize it away; otherwise better safe than sorry.
|
1.39.2.2 |
| 02-Jan-2020 |
martin | Pull up following revision(s) (requested by maxv in ticket #597):
sys/compat/common/kern_sig_43.c: revision 1.36 sys/compat/netbsd32/netbsd32_compat_20.c: revision 1.39 sys/compat/netbsd32/netbsd32_compat_43.c: revision 1.59 sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.44
Fix sizeof mismatch in copyin. This leads to a user-triggerable stack overflow. On my test build at least, by luck, the compiler orders the variables in a way that the overflow hits only local structures which haven't yet been initialized and used, so the overflow is harmless.
Very easily seeable with kASan - just invoke the syscall from a 32bit binary.
Fix three stack info leaks, found by kMSan when just invoking all syscalls with a zero page as argument.
MSan: Uninitialized Stack Memory In copyout() At Offset 0, Variable 'sb32' From compat_20_netbsd32_getfsstat() MSan: Uninitialized Stack Memory In copyout() At Offset 12, Variable 'oss' From compat_43_sys_sigstack() MSan: Uninitialized Stack Memory In copyout() At Offset 0, Variable 'sb' From compat_50_netbsd32___fhstat40()
|
1.39.2.1 |
| 18-Dec-2019 |
martin | Pull up following revision(s) (requested by tsutsui in ticket #570):
sys/compat/netbsd32/netbsd32_compat_50_sysv.c: revision 1.3 sys/dev/raidframe/rf_compat50.h: revision 1.6 sys/arch/emips/emips/bus_space.c: revision 1.3 sys/compat/net/if.h: revision 1.5 sys/arch/emips/stand/common/bootinfo.c: revision 1.2 sys/compat/common/sysv_msg_50.c: revision 1.5 sys/compat/common/kern_time_30.c: revision 1.8 sys/arch/emips/stand/common/bootinfo.h: revision 1.2 sys/arch/ia64/include/bus.h: revision 1.4 sys/arch/ia64/ia64/bus_space.c: revision 1.2 sys/compat/common/sysv_shm_50.c: revision 1.5 sys/dev/ic/adw.h: revision 1.15 sys/compat/common/uipc_syscalls_50.c: revision 1.10 sys/arch/emips/ebus/flash_ebus.c: revision 1.22 sys/dev/ic/adv.h: revision 1.15 sys/dev/ic/adwmcode.c: revision 1.18 sys/dev/ic/advlib.c: revision 1.29 sys/arch/hpcarm/include/kloader.h: revision 1.3 sys/dev/usb/uberry.c: revision 1.16 sys/compat/common/sysv_sem_50.c: revision 1.5 sys/compat/netbsd32/netbsd32_compat_50.c: revision 1.43 sys/dev/ic/advlib.h: revision 1.21 sys/dev/ic/adv.c: revision 1.50 sys/compat/netinet6/in6_var.h: revision 1.5 sys/arch/hpc/stand/hpcboot/arm/arm_sa1100_asm.asm: revision 1.2 sys/arch/emips/include/loadfile_machdep.h: revision 1.3 sys/arch/emips/stand/common/prom_iface.c: revision 1.7 sys/dev/ic/adw.c: revision 1.56 sys/dev/ic/adwmcode.h: revision 1.12 sys/dev/ic/advmcode.c: revision 1.10 sys/arch/emips/ebus/ace_ebus.c: revision 1.22 sys/compat/netbsd32/netbsd32_compat_60.c: revision 1.5 sys/dev/raidframe/rf_compat50.c: revision 1.13 sys/arch/x68k/dev/intiovar.h: revision 1.15 sys/dev/usb/uipad.c: revision 1.8 sys/arch/zaurus/include/kloader.h: revision 1.3 sys/arch/emips/stand/common/bootxx.c: revision 1.2 sys/dev/ic/adwlib.h: revision 1.23 sys/dev/ic/adwlib.c: revision 1.44 sys/compat/netbsd32/netbsd32_compat_16.c: revision 1.3 sys/arch/amigappc/include/intr.h: revision 1.27 sys/arch/x68k/dev/mfp.c: revision 1.27 sys/arch/arm/at91/at91dbgu.c: revision 1.17 sys/dev/ic/advmcode.h: revision 1.7 sys/compat/ultrix/ultrix_exec.h: revision 1.7 sys/compat/common/vfs_syscalls_50.c: revision 1.24 sys/arch/mips/cavium/octeon_dma.c: revision 1.3 sys/arch/hpc/stand/hpcboot/arm/arm_pxa2x0_asm.asm: revision 1.2
Remove clause 3 and 4 from TNF licenses. Ok'ed by martin@ in PR/54760.
Remove clause 3 and 4 leftovers from TNF licenses in more sources. Confirmed by martin@ in PR/54760.
|
1.44.2.1 |
| 29-Feb-2020 |
ad | Sync with head.
|
1.49.2.1 |
| 03-Apr-2021 |
thorpej | Sync with HEAD.
|