summaryrefslogtreecommitdiff
path: root/src/systemd
Commit message (Collapse)AuthorAgeFilesLines
* sd-login: minor header commenting improvementsLennart Poettering2015-09-051-14/+14
|
* sd-login: add new sd_pid_get_cgroup() APILennart Poettering2015-09-051-0/+8
| | | | | | | | | | This adds a new sd_pid_get_cgroup() call to sd-login which may be used to query the control path of a process. This is useful for programs when making use of delegation units, in order to figure out which subtree has been delegated. In light of the unified control group hierarchy this is finally safe to do, hence let's add a proper API for it, to make it easier to use this.
* sd-dhcp-server: simplify pool creationTom Gundersen2015-08-311-2/+1
| | | | | | | Merge sd_dhcp_server_set_address() and sd_dhcp_server_set_lease_pool() into sd_dhcp_server_configure_pool() as the behavior of the two former depends on the order they are called in. The flexibility is not needed, so let's just do this in one call.
* Merge pull request #1057 from poettering/resolve-drop-res-queryTom Gundersen2015-08-271-13/+0
|\ | | | | sd-resolve: drop res_query() API
| * sd-resolve: drop res_query() APILennart Poettering2015-08-271-13/+0
| | | | | | | | | | | | Querying low-level DNS RRs should be done via resolved now, not via glibc's awful res_query() API anymore. Let's not introduce an async wrapper for it hence.
* | Merge pull request #1055 from poettering/dhcp-updatesTom Gundersen2015-08-273-10/+20
|\ \ | |/ |/| Various networkd and dhcp updates
| * dhcp,network: support emitting DNS/NTP server information from DHCP serverLennart Poettering2015-08-271-2/+5
| | | | | | | | | | For now, this is very simple and IP addresses have to be configured manually.
| * networkd: make DHCP lease timeouts configurableLennart Poettering2015-08-271-0/+3
| |
| * dhcp: clean up dhcp4 lease objectLennart Poettering2015-08-271-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a) drop handling of obsolete or unused DHCP options time_offset, mtu_aging_timeout, policy filter, mdr, ttl, ip forwarding settings. Should this become useful one day we can readd support for this. b) For subnet mask and broadcast it is not always clear whether 0 or 255.255.255.255 might be valid, hence maintain a boolean indicating validity next to it. c) serialize/deserialize broadcast address, lifetime, T1 and T2 together with the rest of the fields in dhcp_lease_save() and dhcp_lease_load(). d) consistently return ENODATA from getter functions for data that is missing in the lease. e) add missing getter calls for broadcast, lifetime, T1, T2. f) when decoding DHCP options, generate debug messages on parse failures, but try to proceed if possible. g) Similar, when deserializing a lease in dhcp_lease_load(), make sure we deal nicely with unparsable fields, to provide upgrade compat. h) fix some memory allocations
| * dhcp: generic data should be void*, not uint8_t*Lennart Poettering2015-08-261-3/+3
| | | | | | | | | | If we handly arbitrary data we should use "void*" pointers, not "uint8_t*", how go intended C to be used.
| * dhcp: keep lease save/load functions privateLennart Poettering2015-08-261-3/+0
| | | | | | | | | | | | When we make sd-dhcp public one day we really should not make sd_dhcp_lease_save() and sd_dhcp_lease_load() public, since it's pretty much only useful as internal utility for networkd itself.
| * dhcp,network: implement RFC 4833 (DHCP Timezone option)Lennart Poettering2015-08-263-0/+6
| | | | | | | | | | This one is simply to add: encode the tzdata timezone in the DHCP options and optionally make use of it.
* | sd-bus: introduce new SD_BUS_VTABLE_PROPERTY_EXPLICIT flagLennart Poettering2015-08-251-0/+1
|/ | | | | | | | | | | | | | | | | | | This allows marking properties as "explicit". Properties marked like this are included in the introspection, but are avoided in GetAll() property queries, PropertiesChanged() signals and in in GetManaged() object manager calls and InterfacesAdded() signals. Expensive properties may be marked that way, and they will be retrievable when explicitly being requested, but never in "blanket" all-property queries and signals. This flag may be combined with the flags for "const" and "emit-validation" properties, but not with "emit-validation", as that is only useful for properties whose value shall be sent in "blanket" all-property signals. The "explicit" flag is also exposed in the introspection data via a new annotation.
* sd-dhcp6: Add support for DHCPv6 NTP Server OptionPatrik Flykt2015-08-211-0/+3
| | | | | Support NTP server and multicast addresses and NTP server domain names as specified in RFC 5908.
* sd-dhcp6: Add support for DHCPv6 DNS Domain Search List optionPatrik Flykt2015-08-211-0/+1
| | | | | | Support DHCPv6 DNS search list option as specified in RFC 3646. This option contains a list of DNS search domains encoded without compression as specified in Section 8. of RFC 3315.
* sd-dhcp6: Add support for DHCPv6 DNS Recursive Name Server optionPatrik Flykt2015-08-211-1/+3
| | | | | Support DHCPv6 DNS server option as specified in RFC 3646. This option contains a list of IPv6 DNS server addresses.
* sd-netlink: introduce api for new NL type NLA_FLAGSusant Sahani2015-07-291-0/+1
|
* sd-bus: remove _VTABLE from new method vtable initialiserdaurnimator2015-07-241-2/+2
|
* sd-bus: add 'offset' member for vtable methodsdaurnimator2015-07-241-1/+5
| | | | | Defaults to zero, which retains the current behaviour. Fixes #577
* dhcp: add support for vendor specific DHCP optionBeniamino Galvani2015-07-121-0/+2
| | | | | | | | | This adds support for option 43 (Vendor Specific Information) to libsystemd-network DHCP code. The option carries an opaque object of n octets, interpreted by vendor-specific code on the clients and servers. [@zonque: adopted to new unhexmem() API]
* sd-bus: sd_bus_slot_get_description() should return const stringsDavid Herrmann2015-07-091-1/+1
| | | | | | | | | | All other *_get_description() functions use 'const char**', so make sure sd_bus_slot_get_description() does the same. This changes API, but ABI stays stable. I think this is fine, but I wouldn't mind bumping SONAME. Reported in #528.
* sd-bus: introduce new sd_bus_flush_close_unref() callLennart Poettering2015-07-031-0/+1
| | | | | | | | | | | | | | | | sd_bus_flush_close_unref() is a call that simply combines sd_bus_flush() (which writes all unwritten messages out) + sd_bus_close() (which terminates the connection, releasing all unread messages) + sd_bus_unref() (which frees the connection). The combination of this call is used pretty frequently in systemd tools right before exiting, and should also be relevant for most external clients, and is hence useful to cover in a call of its own. Previously the combination of the three calls was already done in the _cleanup_bus_close_unref_ macro, but this was only available internally. Also see #327
* sd-netlink: message - split up source fileTom Gundersen2015-06-131-1/+1
| | | | Split netlink-socket.c and rtnl-message.c from netlink-message.c.
* sd-netlink: drop the write-queueTom Gundersen2015-06-131-1/+0
| | | | AF_NETLINK is not write-buffered, so this was actually never used.
* sd-netlink: rename from sd-rtnlTom Gundersen2015-06-132-152/+151
|
* sd-rtnl: make joining broadcast groups implicitTom Gundersen2015-06-111-3/+2
|
* sd-bus: add async convenience method call APIUmut Tezduyar Lindskog2015-06-091-0/+1
|
* sd-bus,sd-event: make public APIsLennart Poettering2015-05-221-3/+3
| | | | | | With the v221 release these APIs should be public, stable APIs, hence let's install their headers by default now, and add their symbols to the .sym file.
* sd-bus,sd-login: add api for querying the slice within the the user systemd ↵Lennart Poettering2015-04-302-26/+35
| | | | | | | instance of a process units are organized in slice trees, not only for the system instance, but also for user systemd instances, expose this properly.
* sd-bus: drop bus parameter from message callback prototypeLennart Poettering2015-04-291-2/+2
| | | | | | This should simplify the prototype a bit. The bus parameter is redundant in most cases, and in the few where it matters it can be derived from the message via sd_bus_message_get_bus().
* shutdownd: kill the old implementationDaniel Mack2015-04-241-119/+0
| | | | | | Not that all functionality has been ported over to logind, the old implementation can be removed. There goes one of the oldest parts of the systemd code base.
* sd-bus: add controlling tty field to sd_creds objectLennart Poettering2015-04-231-4/+6
| | | | | This is useful to print wall messages from logind with the right client tty. (to be added in a later patch)
* sd-bus: expose ppid fieldLennart Poettering2015-04-211-29/+31
| | | | | kdbus has been passing us the ppid file for a while, actually make use of it.
* log: move log_syntax() into src/shared/log.c, and make it more similar to ↵Lennart Poettering2015-04-211-1/+1
| | | | the other log functions
* sd-bus: when augmenting creds, remember which ones were augmentedLennart Poettering2015-04-211-0/+1
| | | | | Also, when we do permissions checks using creds, verify that we don't do so based on augmented creds, as extra safety check.
* sd-device: enumerator - match only on initialized devices by defaultTom Gundersen2015-04-171-1/+1
| | | | | | | | It is still possible to include uninitialized ones, but now that is opt-in. In most cases people only want initialized devices. Exception is if you want to work without udev running. Suggested by David Herrmann.
* sd-device: enumerator - don't expose add_device()Tom Gundersen2015-04-171-2/+0
| | | | | | | This is rarely, if ever, used. Drop it from the new public API and only keep it for the legacy API. Suggested by David Herrmann.
* sd-device: add device-enumerator libraryTom Gundersen2015-04-161-1/+25
|
* libsystemd: add sd-device libraryTom Gundersen2015-04-021-0/+77
| | | | | | | | | | | | This provides equivalent functionality to libudev-device, but in the systemd style. The public API only caters to creating sd_device objects from for devices that already exist in /sys, there is no support for listening for monitoring events or creating devices received over the udev netlink protocol. The private API contains the necessary functionality to make sd-device a drop-in replacement for libudev-device, but which we would not otherwise want to export.
* sd-event: rename PASSIVE/PREPARED to INITIAL/ARMEDTom Gundersen2015-03-141-2/+2
|
* Fix typosTorstein Husebø2015-03-091-1/+1
|
* networkd: add support for Uplink Failure DetectionAlin Rauta2015-02-271-0/+6
| | | | | | | Introduce BindCarrier= to indicate the set of links that determine if the current link should be brought UP or DOWN. [tomegun: add a bit to commit message]
* id128: add new sd_id128_is_null() callLennart Poettering2015-02-241-0/+4
|
* sd-bus: allow setting a per-connection default value for the ↵Lennart Poettering2015-02-181-0/+2
| | | | | | | | | "allow-interactive-authentication" message flag Most of our client tools want to set this bit for all their method calls, even though it defaults to off in sd-bus, and rightfully so. Hence, to simplify thing, introduce a per sd_bus-object flag that sets the default value for all messages created on the connection.
* sd-bus: add missing format attributeCristian Rodríguez2015-02-161-1/+1
|
* sd-bus: export sd_bus_error_set_errnofv()Lennart Poettering2015-02-131-0/+2
|
* sd-rtnl: extend type system to allow address-family to decide the union membersTom Gundersen2015-02-081-0/+2
| | | | | | So far we only supported selecting them by sibling attributes. (This stuff is all a bit crazy, but there seems to be no other way...)
* sd-rtnl: introduce sd_rtnl_new_from_netlinkTom Gundersen2015-02-021-0/+1
|
* sd-icmp6-nd: Add support for fetching the latest expired prefixPatrik Flykt2015-01-271-0/+2
| | | | | Keep the expired prefix for the duration of the prefix expiration event and remove it afterwards.
* sd-icmp6-nd: Parse ICMPv6 prefix informationPatrik Flykt2015-01-271-4/+22
| | | | | | | | | | | | Save each new onlink IPv6 prefix and attach an expiry timer to it. If the prefixes overlap, take the shorter prefix and write a debug message about the event. Once the prefix is resent in a Router Advertisement, update the timer. Add a new event for the expiring prefix. Add two helper functions, one for returning a prefix length given a Router Advertisement and the other for generic prefix matching given an IPv6 prefix and address.