Commit Graph

118 Commits (6cf3241749ccf9fdd100802c70a6411ce7133ee4)

Author SHA1 Message Date
refi64 dbac0dc530
hostsfile: Copy the SELinux context to the temp file before overwrite (#273)
* hostsfile: Copy the SELinux context to the temp file before overwrite

On SELinux-enabled systems, /etc/hosts has a different type `net_conf_t`
than the other files in /etc, so the temporary file that overwrites it
ends up with the wrong context, resulting in many system services
becoming unable to access the file. To fix this, manually look up the
context /etc/hosts has and copy it to the temporary file before
the rename.

In order to avoid depending on libselinux on systems that don't use it,
this support is gated behind the new "selinux" feature. It *is*
installed and enabled in the Dockerfile, however, in order to ensure
that it still builds.

* Appease clippy

* Add info about selinux feature to README.md

* Remove unused ClientError struct

* Reformatted & repositioned and improved doc about selinux

---------

Co-authored-by: Brian Schwind <brianmschwind@gmail.com>
Co-authored-by: Jürgen Botz <jurgen@botz.org>
2024-07-01 10:16:43 +09:00
Saber Haj Rabiee 15602388f6
fix nightly build (#304)
* fix nightly build

* update toml dep in server for consistency

* cargo update

* fix clippy errors
2024-04-19 00:09:23 +09:00
Brian Schwind 489f505f67
meta: release v1.6.1 (#295)
Co-authored-by: straylight-annex-portal <tonari@straylight-annex-portal>
2023-12-27 12:42:31 +09:00
Matěj Laitl b90024d3d3
Update netlink ecosystem packages (#281)
Should fix https://github.com/tonarino/innernet/issues/280

Co-authored-by: Jake McGinty <me@jakebot.org>
2023-08-19 11:00:02 +00:00
John Whittington dc7ae0e15c
x25519-dalek rc.2 no longer exists, bump to rc.3 (#274) 2023-07-07 12:02:21 +02:00
Matěj Laitl 8d058c8d87
meta: release v1.6.0 (ran on Linux) (#270)
* meta: release v1.6.0

* README: update release steps
2023-06-14 10:49:16 +02:00
Jake McGinty 33cee129d1
Various dependency updates (#265)
* update netlink-*, toml, clap, other small dependencies
* switch back to x25519-dalek from curve25519-dalek
2023-06-01 01:25:46 -05:00
Jake McGinty ebeac3db76 migrate from lazy_static to once_cell across project 2023-05-30 11:24:40 +02:00
Ryan Gonzalez f67457e0a4 Use the proper netlink buffer size with large kernel pages
The recommended netlink buffer size is based on the system's page size,
which means that the current size is far too small for systems with 16k
or 64k pages, such as Asahi Linux or RHEL's kernel-64k for ARM64. On
these systems, the server fails to start with errors like this:

Error: Decode error occurred: invalid netlink buffer: length field says 1444 the buffer is 1260 bytes long

Instead, follow the kernel's own netlink docs to compute the buffer
size. The approach here matches the approach merged into Chromium
recently:

https://chromium-review.googlesource.com/c/chromium/src/+/4312885
2023-05-30 09:24:07 +02:00
Matěj Laitl 103896dd88 Fix rand_core dependency, cargo update
Should fix #242.

We depend on `getrandom` feature of `rand_core`, but we weren't specifying that.

It worked because `curve25519-dalek 4.0.0-pre.2` was pulling the `getrandom` feature of `rand_core`, but after updating it to `4.0.0-pre.5` it stopped pulling `rand_core` altogether.

After the cargo-update, all out dependencies are on their newest version, sans clap 3.2, which could be updated to 4.0. It has quite some breaking API changes, so I'll leave that for a separate PR.
2023-01-13 14:31:45 +09:00
Jake McGinty eac6071d7a meta: release v1.5.5 2022-09-23 23:16:35 -05:00
Jake McGinty eb5b5370df meta: cargo update 2022-09-23 23:38:23 -04:00
Jake McGinty c9dbeefaaa shared: update nix to 0.24 2022-08-10 16:30:45 -06:00
Jake McGinty 55671ec80a meta: cargo update 2022-08-10 15:58:46 -06:00
Jake McGinty 047660733b server: add link in comment for rusqlite musl workaround 2022-08-10 14:21:11 -06:00
Matěj Laitl 986a47fab3 Update sqlite dependencies + cargo update
Let's see if that helps with #228.
2022-08-01 10:57:11 +02:00
Jake McGinty 50a4360746 meta: cargo update 2022-05-05 07:52:40 -05:00
Jake McGinty 0e75704538 meta: cargo update 2022-04-17 12:27:27 +09:00
Jake McGinty a6c918a581 meta: release v1.5.4 2022-03-16 18:17:37 +09:00
Jake McGinty be8786a11c meta: release v1.5.4-beta.5 2022-03-15 11:15:56 +09:00
Jake McGinty e544391303 meta: update dependencies 2022-03-15 10:47:52 +09:00
Jake McGinty 3bfd81d8ed meta: release v1.5.4-beta.4 2022-02-18 10:57:22 +09:00
Jake McGinty 65e556b517 wireguard-control: use latest curve25519-dalek 2022-02-18 10:56:53 +09:00
Jake McGinty 123977be34 meta: cargo update 2022-02-17 09:53:59 +09:00
Jake McGinty ed4c6ea495 wireguard-control: use netlink-packet-wireguard 0.2 2022-02-15 02:34:21 +09:00
Jake McGinty 80a070baae meta: release v1.5.4-beta.3 2022-02-05 04:18:39 +09:00
Jake McGinty 9270b9662a meta: cargo update 2022-02-05 04:16:50 +09:00
Jake McGinty a7f7204bd7 meta: cargo update 2022-02-03 01:55:34 +09:00
Jake McGinty c7a2f7391c meta: release v1.5.4-beta.2 2022-02-03 01:50:39 +09:00
Jake McGinty f7df6bab01 meta: release v1.5.4-beta.1 2022-02-01 14:04:11 +09:00
Jake McGinty a77cbb4f49
meta: switch from ipnetwork to ipnet (#193) 2022-02-01 14:01:21 +09:00
Jake McGinty 3055eb7a78 netlink-request: remove unused dependency 2022-02-01 06:34:29 +09:00
Jake McGinty 2cb530762c wireguard-control: go back to using upstream netlink 2022-02-01 05:40:49 +09:00
Jake McGinty 4715cd0c87 meta: release v1.5.3 2022-02-01 04:56:11 +09:00
Jake McGinty 49aaa3907a meta: cargo update 2022-02-01 04:27:24 +09:00
Jake McGinty 4000d84648 meta: release v1.5.3-beta.5 2022-01-22 18:08:31 +00:00
Jake McGinty 9585289344 meta: cargo update 2022-01-22 18:07:12 +00:00
Jake McGinty d796cb54bf
hostsfile: safely overwrite hosts file instead of clobbering (#186)
fixes #183
2022-01-22 16:24:44 +09:00
Jake McGinty d8cda216c8 meta: cargo update 2022-01-21 17:26:24 -05:00
Jake McGinty f7e19e686c shared: remove structopt dependency 2022-01-18 12:42:09 -06:00
Jake McGinty 16ac280807 meta: release v1.5.3-beta.4 2022-01-18 15:56:36 +09:00
Jake McGinty b53376b9c8 meta: release v1.5.3-beta.3 2022-01-18 15:19:53 +09:00
Jake McGinty c80fe23e1c meta: cargo update 2022-01-18 15:19:16 +09:00
Jake McGinty ce23bbdf63 meta: release v1.5.3-beta.2 2022-01-12 16:31:31 -06:00
Jake McGinty cf72456484 meta: cargo update 2022-01-12 16:31:03 -06:00
Jake McGinty 6541605319 wireguard-control: add log crate dependency to allow debug output 2022-01-12 16:15:05 -06:00
Jake McGinty b15b541669 meta: release v1.5.3-beta.1 2022-01-11 14:18:19 -06:00
Jake McGinty 160451c8e5 meta: cargo update 2022-01-11 02:02:05 -06:00
Jake McGinty 8dd11977af meta: structopt 0.3 -> clap 3 2022-01-11 01:51:32 -06:00
Jake McGinty 97a49c5c0e netlink-request: match semver with rest of the project 2022-01-11 01:17:24 -06:00