summaryrefslogtreecommitdiff
path: root/src/core
AgeCommit message (Collapse)Author
2013-12-30core: Forgot to dereference pointer when checking for NULLStefan Beller
Actually we already checked for !rt before, now we'd like to examine the return value of the memory allocation.
2013-12-28bus: fix a couple of format string mistakesLennart Poettering
2013-12-27selinux: Check access vector for enable/disable perm for each unit fileLubomir Rintel
SELinux check will be done using the context of the unit file as as a target instead of the default init_t context, allowing selinux control on the level of individual units. https://bugzilla.redhat.com/show_bug.cgi?id=1022762
2013-12-26Use enums to make it obvious what boolean params meanZbigniew Jędrzejewski-Szmek
Suggested-by: Russ Allbery <rra@debian.org>
2013-12-26systemctl: allow globbing in commands which take multiple unit namesZbigniew Jędrzejewski-Szmek
2013-12-26bus: make system bus kdbus node world-accessibleLennart Poettering
2013-12-25build-sys: minor fixes found with cppcheckLennart Poettering
2013-12-25unit: include peer identity in description of per-connection ↵Lennart Poettering
socket-activated services
2013-12-24util: unify SO_PEERCRED/SO_PEERSEC invocationsLennart Poettering
Introduce new call getpeercred() which internally just uses SO_PEERCRED but checks if the returned data is actually useful due to namespace quirks.
2013-12-23core: when we close the notify fd, we also need to free its event sourceLennart Poettering
2013-12-23log: als turn on debug logging in non-PID1 if /proc/cmdline contains "debug"Lennart Poettering
2013-12-22sd-daemon: introduce sd_watchdog_enabled() for parsing $WATCHDOG_USECLennart Poettering
Also, introduce a new environment variable named $WATCHDOG_PID which cotnains the PID of the process that is supposed to send the keep-alive events. This is similar how $LISTEN_FDS and $LISTEN_PID work together, and protects against confusing processes further down the process tree due to inherited environment.
2013-12-22shared: switch our hash table implementation over to SipHashLennart Poettering
SipHash appears to be the new gold standard for hashing smaller strings for hashtables these days, so let's make use of it.
2013-12-22core: the cgroup properties are not actually constLennart Poettering
2013-12-22core: no need to list properties for PropertiesChanged messages anymoreLennart Poettering
Since the vtable includes this information anyway, let's just use that
2013-12-22bus: decorate the various object vtables with SD_BUS_VTABLE_PROPERTY_CONST ↵Lennart Poettering
where appropriate
2013-12-21core: replace readdir_r with readdirFlorian Weimer
2013-12-21core: make check for Disconnected message more preciseLennart Poettering
2013-12-21core: pass notify fd across reexecsLennart Poettering
That way we the random socket name stays stable across reexec and we won't lose client messages.
2013-12-19service: don't send out PropertiesChanged message for each watchdog notificationLennart Poettering
2013-12-19loopback-setup: correctly set flags and scope for ipv6 addressTom Gundersen
2013-12-19do not run kmod-setup in a containerKay Sievers
2013-12-18temporarily support "kdbus" keyword on the kernel commandline to load the moduleKay Sievers
2013-12-18execute: set TERM even if we don't open the tty on our ownLennart Poettering
This way, when a tty path is configured TERM is set, which is nice to set a useful term for gettys.
2013-12-18core,logind: libudev usage modernizationsLennart Poettering
Always use cleanup logic and don't eat up errors returned by libudev
2013-12-18core,logind,networkd: check for udev device initialization via enumeration ↵Lennart Poettering
matches Instead of checking each device after we got it, check wuth an enumeration filter instead, to make it more efficient.
2013-12-18core: priorize notification fd processing over notification fd process via ↵Lennart Poettering
sd-event's logic
2013-12-18core: in a container log to /dev/console if "debug" is specifiedLennart Poettering
2013-12-18log: don't reopen /dev/console each time we call log_open()Lennart Poettering
Instead, force reopen it only if we really really have to.
2013-12-18service: watch main pid even in final statesLennart Poettering
In some circumstances, for example when start-up times out we immediately jump into the final state, at which point we still should try to watch the main pid so that the SIGCHLD allows us to quickly move into dead state.
2013-12-18comment out udev's is_initialized call until the problem is sorted outKay Sievers
2013-12-18core,logind,networkd: don't pick up devices from udev before they finished ↵Lennart Poettering
udev initialization Managers shouldn't pick up the devices the manage before udev finished initialization, hence check explicitly for that.
2013-12-17_noreturn_ --> noreturn for C11 compatShawn Landden
also define noreturn w/o <stdnoreturn.h>
2013-12-17core: always create /dev/kdbus/ns (and make it private 0700) after setting ↵Lennart Poettering
up the kdbus system bus
2013-12-16bus: when a busname unit refuses to activate a service it should flush the queueLennart Poettering
2013-12-16systemctl: properly initialize and free sd_bus_error in "systemctl cat"Lennart Poettering
We need to properly initialize all error structs before use and free them after use. Also, there's no point in flushing stdout if we output a \n anyway...
2013-12-16execute: also set SO_SNDBUF when spawning a service with stdout/stderr ↵Lennart Poettering
connected to journald
2013-12-16loopback-setup: remove stray hunkTom Gundersen
2013-12-16network: use SETLINK to bring up interfacesTom Gundersen
2013-12-16rtnl: replace message_append by typesafe versionsTom Gundersen
2013-12-16rtnl: simplify link_new()Tom Gundersen
Drop most of the arguments and instead introduce link_set_{flags,type}.
2013-12-16core: refuse doing %h, %s, %U specifier resolving in PID 1Lennart Poettering
These specifiers require NSS lookups to work, and we really shouldn't do them from PID 1 hence. With this change they are now only supported for user systemd instance, or when the configured user for a unit is root.
2013-12-14Add more _printf_'s for format-nonliteralsThomas Hindoe Paaboel Andersen
Clang is a bit more strict wrt format-nonliterals: http://clang.llvm.org/docs/LanguageExtensions.html#format-string-checking Adding these extra printf attributes also makes gcc able to find more problems. E.g. this patch uncovers a format issue in udev-builtin-path_id.c Some parts looked intetional about breaking the format-nonliteral check. I added some supression for warnings there.
2013-12-14bus: when connecting to a container's kdbus instance, enter namespace firstLennart Poettering
Previously we'd open the connection in the originating namespace, which meant most peers of the bus would not be able to make sense of the PID/UID/... identity of us since we didn't exist in the namespace they run in. However they require this identity for privilege decisions, hence disallowing access to anything from the host. Instead, when connecting to a container, create a temporary subprocess, make it join the container's namespace and then connect from there to the kdbus instance. This is similar to how we do it for socket conections already. THis also unifies the namespacing code used by machinectl and the bus APIs.
2013-12-13event: be more conservative when returning errors from event handler callbacksLennart Poettering
We really should return errors from event handlers if we have a continous problem and don't know any other solution.
2013-12-13namespace: include boot id in private tmp directoriesLennart Poettering
This way it is easy to only exclude directories from the current boot from automatic clean up in /var/tmp. Also, pick a longer name for the directories so that are globs in tmp.conf can be simpler yet equally accurate.
2013-12-12service: process watchdog timeouts with lowest priorityLennart Poettering
2013-12-12core: suppress gcc warnings on selinux-less systemsLennart Poettering
2013-12-12bus: instead of exposing the dbus1 flags when acquiring a name use our own ↵Lennart Poettering
that are closer to kdbus This turns around DO_NOT_QUEUE into QUEUE which implies a more useful default. (And negative options are awful anyway.)
2013-12-12core: fix bus registration on daemon reexecLennart Poettering