summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAge
* control: Fix working with new eloopHEADmasterRoy Marples3 days
|
* src/privsep-linux.c: add support for m68k (#29)Fabrice Fontaine6 days
| | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* README.md: remove dead reference to phabricatorRoy Marples6 days
|
* control: Cannot write with hangupRoy Marples2021-02-20
|
* eloop: delete events from kqueue/epoll directlyRoy Marples2021-02-16
| | | | | | | Rather than relying on close(2) being called. Whilst a bit less performant with many open/close, there is also no guarantee that close(2) will actually be called as shutdown(2) could be used instead.
* log a diagnostic hereRoy Marples2021-02-16
|
* control: Don't log error deleting fds from eloop.Roy Marples2021-02-09
| | | | | They might not be added as they are inactive and its just noise as no operation is done anymore even for kqueue or epoll.
* BSD: Find the correct interface for tunneled routesRoy Marples2021-02-09
| | | | Should disard a harmless diagnostic.
* control: GC control deletionRoy Marples2021-02-08
| | | | Just free it entirely.
* src/privsep-linux.c: add support for arc (#28)Fabrice Fontaine2021-02-08
| | | | | | | | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_{ARCOMPACT,ARCV2} is only defined since kernel 5.2 and https://github.com/torvalds/linux/commit/67f2a8a29311841ba6ab9b0e2d1b8f1e9978cd84 Detection of arc compact and arc v2 have been "copy/pasted" from https://github.com/wbx-github/uclibc-ng/commit/afab56958f1cbb47b831ee3ebff231dfbae74af2 Fixes: - http://autobuild.buildroot.org/results/d29083700a80dd647621eed06faeeae03f0587d3 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* src/privsep-linux.c: add support for or1k (#27)Fabrice Fontaine2021-02-07
| | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_OPENRISC is defined since kernel 3.7: https://github.com/torvalds/linux/commit/e2bebb4ae6d9ac4ffc524db67f7ecb205a173f77 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* Force TOP as we know which directory we are in.Roy Marples2021-02-05
|
* control fd can be both read and write.Roy Marples2021-02-05
|
* src/privsep-linux: fix build on sparc (#26)Fabrice Fontaine2021-02-05
| | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:203: warning: "AUDIT_ARCH_SPARC64" redefined 203 | # define AUDIT_ARCH_SPARC64 | In file included from privsep-linux.c:35: /srv/storage/autobuild/run/instance-0/output-1/host/sparc64-buildroot-linux-gnu/sysroot/usr/include/linux/audit.h:392: note: this is the location of the previous definition 392 | #define AUDIT_ARCH_SPARC64 (EM_SPARCV9|__AUDIT_ARCH_64BIT) | In file included from privsep-linux.c:36: privsep-linux.c:215:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? 215 | BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), | ^~~~~~~~~~~~~~~~~~ Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* src/privsep-linux.c: add support for sh (#25)Fabrice Fontaine2021-02-05
| | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_{SH,SHEL,SH64,SHEL64} are defined at least since kernel 3.7 and https://github.com/torvalds/linux/commit/607ca46e97a1b6594b29647d98a32d545c24bdff Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* Fix testsRoy Marples2021-02-03
|
* Rename Privileged Actioneer to Privileged ProxyRoy Marples2021-02-02
| | | | Sadly actioneer is not a real word.
* Rename Master to ManagerRoy Marples2021-02-02
|
* Fix prior for epoll.Roy Marples2021-02-02
|
* eloop: Make the API more like native poll/kqueue/epollRoy Marples2021-02-02
| | | | | | | | | Just have the one callback, but return an abstracted event mask to work out if we can read/write have something else. Log diagnostics if the event mask is unexpected. While here add more logging if we fail to register an event to monitor.
* Add __NR_pselect6_time64 to prioryRoy Marples2021-01-31
|
* Linux: allow pselect(2) to work in SECCOMPRoy Marples2021-01-31
| | | | | | The default is ppoll(2), but we still allow epoll(7) so allowing pselect(2) makes perfect sense and allows the user to pick the polling mechanism they want.
* src/privsep-linux.c: add support for microblaze (#24)Fabrice Fontaine2021-01-31
| | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_MICROBLAZE is only defined since kernel 3.18 and https://github.com/torvalds/linux/commit/ce5d112827e5c2e9864323d0efd7ec2a62c6dce0 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* A belated welcome to 2021Roy Marples2021-01-31
|
* src/privsep-linux.c: add support for nios2 (#23)Fabrice Fontaine2021-01-31
| | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_NIOS2 is only defined since kernel 5.2 and https://github.com/torvalds/linux/commit/1660aac45e5b49a5ace29fb5b73254617533fcbd Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* Typo with priorRoy Marples2021-01-31
|
* Linux: Add support for NDS32BE SECCOMPRoy Marples2021-01-31
|
* src/privsep-linux.c: add support for xtensa (#22)Fabrice Fontaine2021-01-31
| | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_XTENSA is only defined since kernel 5.0 and https://github.com/torvalds/linux/commit/98c3115a4ec56f03056efd9295e0fcb4c5c57a85 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* import-src: Improve target so we don't create empty filesRoy Marples2021-01-30
|
* import-src: adjust build target so all .in files are pre-builtRoy Marples2021-01-30
| | | | | While here, if we cannot find ypbind to work out how the hook script should be configured, guess according to OS.
* src/privsep-linux.c: add support for nds32 (#21)Fabrice Fontaine2021-01-30
| | | | | | | | | | | | | | | | | | | | Fix the following build failure: privsep-linux.c:206:4: error: #error "Platform does not support seccomp filter yet" # error "Platform does not support seccomp filter yet" ^~~~~ In file included from privsep-linux.c:36: privsep-linux.c:213:38: error: 'SECCOMP_AUDIT_ARCH' undeclared here (not in a function); did you mean 'SECCOMP_ALLOW_ARG'? BPF_JUMP(BPF_JMP + BPF_JEQ + BPF_K, SECCOMP_AUDIT_ARCH, 1, 0), ^~~~~~~~~~~~~~~~~~ It should be noted that AUDIT_ARCH_NDS32 is only defined since kernel 5.2 and https://github.com/torvalds/linux/commit/fa562447e154334523daa44c0b60625d71a345f5 Fixes: - http://autobuild.buildroot.org/results/af8ba07ea0c12ab8cd24d528ef98db05521f3d36 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
* eloop: optimise the pselect code so it's not a wrapper for ppollRoy Marples2021-01-30
| | | | | | | | This makes the code smaller yet and also use less memory then ppoll! Still, the API blows chunks and we still have arbitary fd limits which we'll realistically never hit. Also, some BSD's note potential issues with select on the same fd across processes so ppoll is still the winner.
* eloop: Default to using ppoll(2) again.Roy Marples2021-01-30
| | | | | | | | | | Even though we now have fully working kqueue(2) and epoll(7) with our privsep code, ppoll(2) is faster and smaller for our workload. This time though, we will keep the code here as it's fully working and while fixing kqueue we also fixed other bugs in dhcpcd as a result so it's not time wasted at all.
* eloop: Fix logic error with epoll reading testRoy Marples2021-01-30
|
* eloop: Always free the pollfd buffer when clearing eventsRoy Marples2021-01-29
| | | | | | And set the flag to re-create it before the next run. This allows us to always ensure it's small if the prior run used more signals and fds.
* eloop: fix a memory leak when clearing eventsRoy Marples2021-01-29
|
* WhitespaceRoy Marples2021-01-29
|
* eloop: fixup a compile warningRoy Marples2021-01-28
|
* BSD: Plug a memory leakRoy Marples2021-01-28
|
* Linux: Implement epoll(7) for eloop (again)Roy Marples2021-01-28
| | | | | eloop allows for O(1) processing of active fd's. The problems with the prior implementation have now been fixed.
* control: Don't log the write db didn't exist when freeing it.Roy Marples2021-01-28
|
* privsep: Restore the poll maxfd + 1 for state engineRoy Marples2021-01-28
| | | | It wasn't fixed, it was using kqueue so avoided!
* DragonFly: cast away more kqueue compile warningsRoy Marples2021-01-28
|
* FreeBSD: cast away some kqueue warningsRoy Marples2021-01-28
| | | | NetBSD uses size_t, FreeBSD uses int for changelist length.
* privsep: Don't add 1 to max fd open when limiting resourcesRoy Marples2021-01-28
| | | | It shoud no longer be needed for OpenBSD, Linux and Solaris.
* OpenBSD: Fix kqueue detection and one error.Roy Marples2021-01-28
|
* BSD: Implement kqueue(2) for eloop (again)Roy Marples2021-01-28
| | | | | | | | kqueue allows for O(1) processing of active fd's an a more robust signal handling method without the need to use global variables to avoid calling functions during signal delivery. The problems with the prior implemenation have now been fixed.
* privsep: move setting signals to after clearing eloopRoy Marples2021-01-27
|
* WhitespaceRoy Marples2021-01-27
|
* privsep: Ensure BPF listener pid is logged in debugRoy Marples2021-01-27
| | | | This mirrors the inet listener.