Lennart Poettering
6d439321e8
filesystems: add internal APIs to convert fs magic to name
...
We previously had tooling for the opposite direction, let's complete the
work.
2021-11-15 22:43:03 +01:00
Lennart Poettering
3818d6a3a5
mountpoint-util: sort list of read-only fs again
2021-11-15 22:43:03 +01:00
Lennart Poettering
5feeb2584f
filesystems: add group for "application" file system
...
This group shall cover file systems whose job is to make stuff that
isn't actually storing anything in itself, and isn't just an API file
system, but allows exposing stuff with special semantics in the VFS.
2021-11-15 22:43:03 +01:00
Lennart Poettering
9c8214d559
filesystems: add binfmt_misc to auxiliary API VFS group
2021-11-15 22:43:03 +01:00
Lennart Poettering
333a2ad649
filesystems: add ceph to network file systems group
2021-11-15 22:43:03 +01:00
Lennart Poettering
2867cb392a
filesystems: slightly update common block device groups
2021-11-15 22:43:03 +01:00
Lennart Poettering
73e7576e3b
filesystems: add two new filesystem groups
...
1. @anonymous → for file systems that aren't real file systems but
simply the backing for sockets, pipes and other "anonymous" fds.
2. @security → for the various MAC security file systems.
2021-11-15 22:43:03 +01:00
Lennart Poettering
c79aaff9d5
test-json: add test that makes sure floats are somewhat reasonably implemented
...
Test that we don't loose accuracy without bounds for extreme values, and
validate that nan/inf/-inf actually get converted to null properly.
2021-11-15 22:24:49 +01:00
Yu Watanabe
6706ce2fd2
network: make IgnoreCarrierLoss= also take timespan
...
Fixes #18738 and #20887 .
Replaces #18746 .
2021-11-16 02:04:59 +09:00
Lennart Poettering
a71a0693cd
homework: rework how we disassemble a home dir in home_deactivate()
...
Let's first move the home dir to a new mount point that is only visible
in our own private namespace. Then, do FITRIM and stuff there, so that
we know the regular userspace can't interfere with that, and we know
that the home fs is not used anymore.
(This will become even more important once we add auto-grow/auto-shrink
for home dirs)
2021-11-15 17:56:35 +01:00
Slava Bacherikov
af493fb742
network: Add SuppressInterfaceGroup= into routing policy
...
This adds SuppressInterfaceGroup= option in the [RoutingPolicyRule] section
which has the same semantics as suppress_ifgroup in `ip rule` command.
2021-11-16 01:54:07 +09:00
Slava Bacherikov
10af8bb24b
network: change link group type to int32
...
Both linux kernel kernel and iproute2 uses int32 type for a link group
attribute and -1 has a special meaning, so setting it to 4294967295
would make it -1 in the linux kernel (and ip link cmd).
2021-11-16 01:53:46 +09:00
Luca Boccassi
e2f8c1124d
Merge pull request #21277 from yuwata/permanent-hw-addr
...
network, udev: several improvement of permanent hardware address handling
2021-11-15 10:57:30 +00:00
Yu Watanabe
26591ffffd
resolve: do not clear DNS servers or friends on link which is not managed by networkd
...
When networkd detects an unmanaged link, then the state is changed in
the following order:
pending -> initialized -> unmanaged
The "initialized" state was added by bd08ce5615 .
2021-11-15 08:17:34 +09:00
Yu Watanabe
51f6c93d21
Merge pull request #21359 from yuwata/network-split-route
...
network: log route or nexthop flags
2021-11-15 08:17:07 +09:00
Yu Watanabe
bae62bee43
Merge pull request #21346 from yuwata/network-token-prefixstable
...
network: extend Token=prefixstable setting
2021-11-15 08:16:48 +09:00
Yu Watanabe
b07d8145e1
network: include route or nexthop flags in the debug logs
2021-11-14 14:41:37 +09:00
Yu Watanabe
18b23bd493
network: introduce route_flags_to_string_alloc()
2021-11-14 14:41:37 +09:00
Yu Watanabe
344b3cff36
network: split networkd-route.[ch]
2021-11-14 14:41:37 +09:00
Yu Watanabe
10b1c3cd24
Merge pull request #21355 from bluca/coverity
...
Coverity and CodeQL fixes
2021-11-14 14:18:08 +09:00
Zbigniew Jędrzejewski-Szmek
b1bcda702c
meson: drop mode setting on systemd-update-helper
...
With a6d1760024 , this shouldn't be
necessary anymore.
2021-11-14 13:54:47 +09:00
Jan Janssen
4cf8a6092e
meson: Use fs module
...
Turns out that meson provides a fs module since 0.53.0, making it unnecessary
to call out to test.
2021-11-14 13:54:27 +09:00
Zbigniew Jędrzejewski-Szmek
4728625490
seccomp: move mprotect to @default
...
With glibc-2.34.9000-17.fc36.x86_64, dynamically programs newly fail in early
init with a restrictive syscall filter that does not include @system-service.
I think this is caused by 2dd87703d4386f2776c5b5f375a494c91d7f9fe4:
Author: Florian Weimer <fweimer@redhat.com >
Date: Mon May 10 10:31:41 2021 +0200
nptl: Move changing of stack permissions into ld.so
All the stack lists are now in _rtld_global, so it is possible
to change stack permissions directly from there, instead of
calling into libpthread to do the change.
It seems that this call will now be very widely used, so let's just move it to
default to avoid too many failures.
2021-11-14 13:53:50 +09:00
Yu Watanabe
f2a3a133ec
network: make Token=prefixstable optionally take secret key
...
Closes #21345 .
2021-11-14 13:29:40 +09:00
Yu Watanabe
b7ac128430
network: do not recall link_handle_bound_by_list() or so when the interface is reconfigured
2021-11-14 11:52:49 +09:00
Yu Watanabe
52c3bc708f
event-util: introduce event_reset_time_relative()
2021-11-14 10:32:06 +09:00
Luca Boccassi
b798490f77
test-strxcpyx: check result of snprintf
2021-11-14 01:28:42 +00:00
Luca Boccassi
0a040e6419
sd-event: one more assert when turning off an event source
...
CID#1465866
2021-11-13 19:12:11 +00:00
Luca Boccassi
25bb459e39
journal-remote: more handling of sd_event_source_set_enabled failures
...
But avoid clobbering the return value if it works
CID#1465793
CID#1465794
2021-11-13 19:11:55 +00:00
Luca Boccassi
76a7c636a9
Merge pull request #21341 from yuwata/network-route-flags
...
network: manage route and nexthop flags
2021-11-13 18:43:50 +00:00
Lennart Poettering
b4d4596ffb
test: rename test-user-record → test-uid-alloc-range
...
It doesn't actually test any of the JSON stuff, hence name it
test-uid-alloc-range, since it tests the stuff from uid-alloc-range.
2021-11-13 08:10:13 +01:00
Lennart Poettering
0fa90f7e04
uid-alloc-range: maintain only a single default alloc range structure
...
Either way we need these four values, let's simplify the code by keeping
only one const struct of this around.
2021-11-13 08:10:13 +01:00
Lennart Poettering
b085d22406
shared: split out UID allocation range stuff from user-record.h
...
user-record.[ch] are about the UserRecord JSON stuff, and the UID
allocation range stuff (i.e. login.defs handling) is a very different
thing, and complex enough on its own, let's give it its own c/h files.
No code changes, just some splitting out of code.
2021-11-13 08:10:11 +01:00
Lennart Poettering
bb562024a5
homework: sync dir after moving file in, not before
2021-11-13 08:05:02 +01:00
Lennart Poettering
1ca5a6c76e
Merge pull request #21333 from poettering/homed-report-fs-and-access-mode
...
homed: report actual home dir access mode and fs type in effect
2021-11-13 08:04:33 +01:00
Lennart Poettering
b1beb00406
Merge pull request #21331 from poettering/luks-extra-mount-options
...
homed: allow per-user additional LUKS mount options
2021-11-13 08:03:55 +01:00
Jan Janssen
9cc6154608
test: Create convenience macros to declare tests
2021-11-13 09:20:24 +09:00
Yu Watanabe
1de88f3048
udev/net: read hardware address from netlink message
2021-11-13 08:53:33 +09:00
Yu Watanabe
49c351a8ac
networkctl: read permanent hardware address from netlink message
2021-11-13 08:53:33 +09:00
Yu Watanabe
8a77e245df
network: also logs iftype, kind, and permanent hardware address
2021-11-13 08:53:33 +09:00
Yu Watanabe
4fea97a61d
network: read permanent hardware address from netlink message
...
The attribute was introduced by f74877a5457d34d604dba6dbbb13c4c05bac8b93 (v5.6),
so, fallback to ethtool if failed.
2021-11-13 08:53:33 +09:00
Yu Watanabe
ed9fa69f1c
ethtool-util: introduce ethtool_get_permanent_hw_addr()
...
And replaces all ethtool_get_permanent_macaddr() with it.
2021-11-13 08:53:33 +09:00
Yu Watanabe
57ae8cd812
networkctl: introduce dump_hw_address()
2021-11-13 08:53:33 +09:00
Lennart Poettering
6b945d7031
homework: split out password cache logic into its own .c/.h file
...
Preparation for extending it further down the line.
2021-11-13 00:22:16 +01:00
Yu Watanabe
17f8d8f9b4
network: manage route and nexthop flags
2021-11-13 08:16:06 +09:00
Yu Watanabe
f505de80d2
network: mention that errors will be ignored
2021-11-13 08:16:06 +09:00
Yu Watanabe
5bfee718d2
sd-netlink: introduce sd_rtnl_message_nexthop_get_flags()
2021-11-13 08:16:06 +09:00
Yu Watanabe
45b1299a1e
sd-netlink: clear previous flags or state by _set_flags() or _set_state()
...
Otherwise, there is no way to reset the previous value.
2021-11-13 08:16:06 +09:00
Lennart Poettering
0881991c32
Merge pull request #21329 from poettering/homed-compress-default
...
homed: default to btrfs compression
2021-11-12 22:55:14 +01:00
Lennart Poettering
b0a7fb152a
homed: include actual fs type + access mode as part of "status" section of user record
...
So far we have two properties for the intended fstype + access mode of
home dirs, but they might differ from what is actually used (because the
user record changed from the home dir, after it was created, or vice
versa). Let's hence add these props also to the "status" section of user
record, which report the status quo. That way we can always show the
correct, current settings.
2021-11-12 22:44:54 +01:00