Commit Graph

1199 Commits

Author SHA1 Message Date
Arne Fitzenreiter
533c4312fa dhcpcd: create dhcpcd user and chroot folder
dhcpcd 9.x adds privelege seperation by creating a chroot
and running parts of the client not as root.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-04-19 17:27:23 +00:00
Arne Fitzenreiter
18136c5ce9 dhcpcd: new pid path for dhcpcd 9.x
dhcpcd 9.x move the path of the pids to an own folder.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-04-19 17:27:12 +00:00
Michael Tremer
5947f92a5a unbound: skip empty domains at local-data import
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-04-09 20:24:42 +00:00
Michael Tremer
1b6b8d97aa unbound: Set domains with local data into type transparent mode
Records which are from the same domain than the IPFire hostname
might not be returned by unbound. This change explicitely instructs
unbound to check local data before checking the global DNS.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-04-07 08:55:31 +00:00
Michael Tremer
0c466599d0 amazon-ssm-agent: Allow to overcommit memory
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-30 17:28:40 +00:00
Markus Untersee
d2738c4c3c vnstat: Add restart command.
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-26 17:51:28 +00:00
Peter Müller
5dba838282 avoid emitting VPN traffic to the internet if the IPS crashed
Due to strange NFQUEUE behaviour, traffic to remote VPN (IPsec or
OpenVPN) destinations was emitted to the internet (ppp0 or red0
interface) directly if the IPS was enabled but crashed during operation.

This patch places the IPSECBLOCK and OVPNBLOCK chains before the
ones responsible for forwarding traffic into the IPS.

Thanks to Michael for his debugging effort.

Partially fixes #12257

Cc: Michael Tremer <michael.tremer@ipfire.org>
Cc: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Peter Müller <peter.mueller@ipfire.org>
Acked-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-26 17:49:43 +00:00
Michael Tremer
07d9e1914a resolv.conf: Add "trust-ad" option
Since we are running unbound locally which always runs DNSSEC
validation, we can simply trust it and pass the ad flag on to
applications which make use of it.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-26 10:06:31 +00:00
Arne Fitzenreiter
a3b07005c1 collectd: run sensors-detect in background
on some machines the i2c sensor search take very long time
which cause hang at first boot.

Now the search is started in background and waited for max one
minute before continue load of collectd.
On such machines collectd will not get all sensors at first startup.

fixes #12329

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
Reviewed-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-26 09:43:10 +00:00
Arne Fitzenreiter
57fda8c8ad suricata: use KILL is suricata not shut down normal.
sometimes suricata hung and lock the pidfile at
suricata stop.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-09 06:41:32 +00:00
Michael Tremer
0f0f3ae7dc unbound: Only launch one process
When unbound is running multiple threads, we have observed
that queries where sent for each thread.

Since no user should have so much DNS traffic that more than
one processor core is being saturated, this is a safe change.

Signed-off-by: Peter Müller <peter.mueller@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne.fitzenreiter@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-04 21:47:23 +00:00
Arne Fitzenreiter
a344d3c902 unbound/red.up: run unbound update-forwarders after suricata init.
The old suricata instance blocks dns requests if the red ip has changed.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-04 08:52:56 +01:00
Arne Fitzenreiter
3b5131c1a3 unbound: drop remove-dns-fowarders at red.down
this functions has only reloaded unbound config
which is useless at shutting down the red interface.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-02 17:54:48 +00:00
Arne Fitzenreiter
770a1507dd unbound: speed-up remove forwarders
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-01 19:46:36 +00:00
Arne Fitzenreiter
47864e8f3d unbound: fix typo at safesearch for googe
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-01 19:46:31 +00:00
Arne Fitzenreiter
d98bbcc849 unbound: run "time-fix" before savesearch resolves
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-01 19:46:26 +00:00
Arne Fitzenreiter
605575033c unbound: update savesearch after reload configfiles
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-03-01 19:46:24 +00:00
Arne Fitzenreiter
8569b3e11b red.up: move update-dns-forwareders behind the firewall
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-19 14:51:48 +00:00
Michael Tremer
aef3c56c65 cyrus-imapd: Drop package
This package is outdated and unmaintained for many many years.
I am not sure if this even works and if there are any users.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-16 16:04:46 +00:00
Michael Tremer
88cb5eb187 cloud-init: Disable using ISP nameservers
This is mostly aesthetic because there are no ISP nameservers
anyways that we could use here.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-16 16:01:10 +00:00
Michael Tremer
a8df6e7807 aws-setup: Remove some excessive whitespace
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-16 16:00:43 +00:00
Michael Tremer
28db34f247 Drop rtpproxy
This probably has only been used by me and we do not need
it any more.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-15 16:56:26 +00:00
Stefan Schantl
1a65ea1b72 Suricata: Update to 5.0.1
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-12 13:28:02 +00:00
Arne Fitzenreiter
f23b046318 unbound: try resolve twice before time sync with ipfire server
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-03 17:40:55 +00:00
Arne Fitzenreiter
f5fe5f47a1 unbound: add returncode to resolve function
this is used for time fix check.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-02-02 13:40:32 +00:00
Michael Tremer
c3ae88cab9 PPP: Always fetch DNS servers from provider
We will later decide whether we want to use them or not

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-31 10:06:34 +00:00
Arne Fitzenreiter
a83bcf914c networking/red: wait only for carrier if device exists
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-25 22:22:26 +01:00
Stefan Schantl
ab4ef40f2b unbound: Use recursor mode if no nameservers are configured
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-21 19:32:34 +00:00
Michael Tremer
26eab1fe3e azure: Abort script when no instance ID can be retrieved
We cannot reliably determine if a system is running on Hyper-V
on a private server or on the Azure Cloud.

Therefore, we will have to try to retrieve an IP address
with DHCP and try to connect to the metadata service. If either
of those things is not successful, we will just continue with
the setup process as usual.

So cloud instances should be automatically configured now and
all other systems will continue to boot and call the setup
wizard as usual.

Fixes: #12272
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-21 19:32:07 +00:00
Michael Tremer
f770492902 cloud-init: Remove importing DNS settings
Those scripts used to import settings from the meta-data services
and wrote them to the local configuration files.

For the DNS settings and Amazon, this is no longer possible because
their DNS servers do not support DNSSEC at all. Therefore we default
to recursor mode.

To be consistent across cloud providers, we are doing the same for
Azure.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-19 16:37:03 +00:00
Michael Tremer
c07c3e47f1 modules: Cleanup file
This file has an unsed line for the "fusion" module which
is no longer needed.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-19 16:36:59 +00:00
Michael Tremer
a8d1621299 modules: No longer load parallel port modules
These modules are loaded by default on all systems.

They are simply a waste of space since not many systems
have parallel ports any more.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-19 16:36:54 +00:00
Arne Fitzenreiter
97f4b51474 partresize: NanoPi R1: copy also a0 config of Ampac AP6212
there is a second hardware version of the AP6212 in some NanoPi R1
boards.

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-17 11:26:10 +01:00
Michael Tremer
8893881160 lvm2: Add initscript for lvmetad
This daemon needs to be launched in order to use LVM
devices in IPFire.

It will run on all installations after this patch has been
merged but only consumes very little memory.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-16 18:23:30 +00:00
Arne Fitzenreiter
61cc563558 Merge remote-tracking branch 'ms/next-dns-ng' into next 2020-01-13 21:42:49 +00:00
Michael Tremer
04b7a78140 unbound: Do not reset safe search again
This is now done in the reload stage and we do not need to
take care about it again.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 21:25:10 +01:00
Michael Tremer
ebc14e8db2 unbound: Drop some unused variables
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 21:20:32 +01:00
Michael Tremer
24a694d425 unbound: Drop function to reload forwarders on the fly
This is now being done by updating and re-reading forward.conf.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 21:19:22 +01:00
Michael Tremer
6137797cb3 unbound: Write hosts to unbound configuration file
This will allow us to read more hosts in a shorter time.

Fixes: #11743
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 21:10:18 +01:00
Michael Tremer
903247fef8 unbound: There is no need to rewrite tuning.conf
The number of CPU cores and memory normally does not change

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 20:55:59 +01:00
Michael Tremer
f59bc0c55d unbound: Reload own hostname, too
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-13 20:55:32 +01:00
Michael Tremer
44cc9a3d57 amazon-ssm-agent: New package
AWS Systems Manager Agent (SSM Agent) is Amazon software that can be
installed and configured on an Amazon EC2 instance, an on-premises
server, or a virtual machine (VM). SSM Agent makes it possible for
Systems Manager to update, manage, and configure these resources. The
agent processes requests from the Systems Manager service in the AWS
Cloud, and then runs them as specified in the request. SSM Agent then
sends status and execution information back to the Systems Manager
service by using the Amazon Message Delivery Service.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
2020-01-11 20:33:36 +00:00
Stefan Schantl
0c1094770a initscripts/unbound: Add support for reload the service
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
2020-01-11 19:36:29 +01:00
Michael Tremer
beebf925c3 unbound: Implement setting qname minimisation into strict mode
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 16:32:35 +00:00
Michael Tremer
a33489a7aa unbound: Try to set time when DNS is not working
Since DNSSEC relies on time to validate its signatures,
a common problem is that some systems (usually those without
a working RTC) are not being able to reach their time server.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 16:24:35 +00:00
Michael Tremer
a32fd634ce unbound: Do not update the forwarders when we are running in TLS mode
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 16:02:14 +00:00
Michael Tremer
4b26aac625 unbound: Read configuration globally
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 15:28:21 +00:00
Michael Tremer
2654c66945 unbound: Update forwarders when system connects/disconnects
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 15:21:59 +00:00
Michael Tremer
54898bc6c1 unbound: Update setting Safe Search redirects
When the system comes online, we must update entries
in the unbound cache to point to the "safe" IP addresses.

Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 15:03:56 +00:00
Michael Tremer
1434fa0df5 DNS: Write name servers received from ISP to /var/run/dns{1,2}
Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org>
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
2020-01-07 13:35:45 +00:00