15159 Commits

Author SHA1 Message Date
Ad Schellevis
0a6a3a7715 Services/Unbound - choose a delimiter (|) and translate empty values to empty strings. should fix https://github.com/opnsense/core/issues/6456
Although I couldn't reproduce the exact same issue, if some values are empty ('') and some are null (None), weird things might happen. This commit makes sure there is a field delimiter, which logically shouldn't exist in the datastream itself and prevent null values being presented as "None".
2023-03-30 15:16:26 +02:00
Franco Fichtner
a0c8016b2f openvpn: typo
PR: https://forum.opnsense.org/index.php?topic=33314.0
2023-03-30 15:15:24 +02:00
Ad Schellevis
3586e701f2 Firewall/Alias - list_table add a comment for previous change 2023-03-29 20:27:47 +02:00
Ad Schellevis
e2dada5783 Firewall/Alias - list_table returning empty ('') addresses. reintroduced https://github.com/opnsense/core/issues/5788 accidentally 2023-03-29 20:22:43 +02:00
Franco Fichtner
4bc36a4860 ntpd: make a note 2023-03-29 20:00:50 +02:00
Franco Fichtner
637bc31161 Revert "network time: migrate to PID file"
This reverts commit fa955f66bc5f70b61eb0864d0340966e2a554435.
2023-03-29 19:49:47 +02:00
Ad Schellevis
f384afa8f9 VPN: IPsec: Security Policy Database - Manual assignments linking to connection children (https://github.com/opnsense/core/issues/6451)
Add connection child as option for manual SPDs, to make sure these are easily selectable we'll extend ModelRelationField to include a method to return it's value (so we can combine parent descriptions)
2023-03-29 16:18:10 +02:00
Franco Fichtner
1f4afe7433 system: for clarity rename 'ports' to 'dns_ports' 2023-03-29 09:16:10 +02:00
Stephan de Wit
4108fdb3fe unbound: dnsbl_module: last bit, change type to CNAME and extra sanity check 2023-03-28 15:19:18 +02:00
Stephan de Wit
02ed20e7d3 unbound: dnsbl_module: retain original query question when responding and logging 2023-03-28 13:58:11 +02:00
Stephan de Wit
01ffca9d6a unbound: dnsbl_module: typo 2023-03-28 11:55:54 +02:00
Stephan de Wit
dd2fd6b0cb unbound: dnsbl_module: prevent logging SERVFAIL twice
in cases where e.g. an internet connection is down, a reply will not be present should unbounds' iterator module return.
normally we marked this as a SERVFAIL, but Unbound already does this for us in the servfail callback.
This means entries were logged twice, once with a "Pass, Recursion, servfail", another one with "Drop, Local, servfail".
This is ambiguous and would skew the relevant statistics.
2023-03-28 11:44:16 +02:00
Stephan de Wit
875d85e990 unbound: dnsbl_module: some optimizations and trim code 2023-03-28 09:24:48 +02:00
Ad Schellevis
28c7942830 unbound: dnsbl_module: account for CNAMEs [2]
minor modifications for e08a96c6cd

[*] separate logger.stats_enabled and rrset handling so cnames are also resolved when logging is disabled
[*] set MODULE_FINISHED as default exit state, toggle to MODULE_ERROR when needed
[*] simplify logic a bit in operate()
2023-03-27 20:59:51 +02:00
Franco Fichtner
e1da915ed1 dhcp: fix too many addresses in radvd RDNSS #6448
Keep the log message as vague as the radvd error string.  It's a hardcoded
magic limit without a descriptive define being reached.
2023-03-27 20:39:47 +02:00
Stephan de Wit
e08a96c6cd unbound: dnsbl_module: account for CNAMEs
There can be multiple CNAMEs in a RRset, so iterate the chain and check every fqdn. If one is encountered in any iteration that matches one in the blocklists, unconditionally block it.
2023-03-27 17:09:23 +02:00
Sami Olmari
7343254f55 Fix typo: "second-level subdir" in helptext 2023-03-27 07:47:45 +02:00
Ad Schellevis
cb57e593a0 Firewall: Settings: Schedules - hopefully final attempt to fix the description escape issue for https://github.com/opnsense/core/issues/6348
This code unfortunately is utterly broken, the plain Javascript code is lenghty and buggy, this only tries to solve the escape issue, but it would be much better if all of this would be replaced with some simple jQuery constructtions.
2023-03-26 19:26:59 +02:00
Ad Schellevis
5dd83dd56a Firewall: Settings: Schedules - undo rawurldecode()/rawurlencode() magic, bringing back https://github.com/opnsense/core/issues/6348 2023-03-26 15:06:44 +02:00
kuya1284
29f1fadf80
Firewall: Settings: Schedules - usability improvements.
closes https://github.com/opnsense/core/issues/6348 , https://github.com/opnsense/core/issues/6349
2023-03-26 11:31:13 +02:00
Franco Fichtner
28fa6a6868 system: simplify previous
We can add multiple ports (like GUI 80, 443) and still look up only one
of them.
2023-03-24 14:37:04 +01:00
Franco Fichtner
4cd1b72d4d dnsmasq: look up port conflict via service framework 2023-03-24 13:32:43 +01:00
Franco Fichtner
68f781f430 system/dhcp: simply look for a DNS service (port 53)
Two things here:

1. I think historically the port was always missing since it must
   be 53 somewhere to work correctly.  This actually fixed that.
2. Bind could be integrated more tightly into this when both Unbound
   and Dnsmasq are not used.
3. We assume that port 53 is actually a DNS service and not some
   other misconfiguration, but it seems from previous code that
   this is more than acceptable in the situation we are in.

Ok, that's three things then.  ;)
2023-03-24 11:02:58 +01:00
Franco Fichtner
b0fde313c0 system: allow service lookup for a specific port
service_by_name('*', ['ports' => ['53']]);

The filter has drawbacks with structured data, but this is good enough
for now and easy to change with only two consumers using it.
2023-03-24 10:56:04 +01:00
Franco Fichtner
69b7f9d532 system: step 1: expose DNS ports to service data as discussed 2023-03-24 10:47:51 +01:00
Stephan de Wit
e4cfc252cd unbound: advanced ACL 2023-03-24 10:42:32 +01:00
Franco Fichtner
23dc326bb3 src: whitespace vs. stable 2023-03-24 10:22:36 +01:00
Franco Fichtner
f6bf94c8c9 ui: whitespace 2023-03-24 09:59:52 +01:00
Ad Schellevis
4082fb4283 System/Logging - timezone parsing issue for zones west of UTC [-]. closes https://github.com/opnsense/core/pull/6443 2023-03-24 09:27:42 +01:00
Franco Fichtner
dfa4bbdfd3 unbound: avoid trailing URL slashes, restrict ACL to single page
Looks like advanced page doesn't have its own ACL entry since 33a253a7487f592
but it probably should still have it?
2023-03-24 09:05:27 +01:00
Ad Schellevis
fa30a8c1e4 Lobby: Dashboard - fix openvpn status reference 2023-03-23 19:46:00 +01:00
kulikov-a
9473b40e9a
Dashboard / widgets / OpenVPN - typo (#6438) 2023-03-23 19:01:06 +01:00
Franco Fichtner
019ea52790 system: do not detach on defer ##6351
Same as filter_configure() now.
2023-03-23 15:59:57 +01:00
Franco Fichtner
ea10c72f7d system: looks like we mask "loss" when "delay" is also reported
Add a new status although we didn't want to extend the functionality,
but this does look like a bug when loss indicator is used but not
properly reported.

PR: https://github.com/opnsense/core/issues/6231
2023-03-23 09:09:32 +01:00
NOYB
e790c17786
Firewall/Alias - replace 'T' with space for timestamp display 2023-03-23 08:52:30 +01:00
Franco Fichtner
c9e78e2cd1 plugins: trailing whitespace 2023-03-22 21:41:32 +01:00
Franco Fichtner
589d57028b ipsec: switcheroo for #6372 2023-03-22 20:55:45 +01:00
Ad Schellevis
9f2ad523b5 Reporting/Health - sort interfaces by description. closes https://github.com/opnsense/core/issues/6434
As we rather don't want to change the api dataformat too much at the moment, we could sort by description in the controller for packets and traffic and move the interface mapping into the getRRDlistAction() response. This should keep all backwards compatible and offers improved sorting with limited impact.
2023-03-22 14:42:46 +01:00
Franco Fichtner
16492ceddd src: whitespace cleanups 2023-03-22 09:14:05 +01:00
Ad Schellevis
38dfe47258 Firewall: Aliases - leave out fractional seconds from timestamps. closes https://github.com/opnsense/core/pull/6432 2023-03-22 08:59:04 +01:00
Franco Fichtner
33ad50456a system: defer start of lighttpd on newwanip event #6351
Looks like improvements in 23.1.4 made the problem worse, indicating
that the direction this is going is a bit doubtful.  Instead, funnel
the restart through configd to reach some state of serialization
similar to what filter_configure() is doing.

While here move the service definition to the correct file.
2023-03-22 08:00:57 +01:00
Franco Fichtner
bbbed94a93 Revert "dhcp: radvd HUP brings back the infamous "can't join ipv6-allrouters" error"
This reverts commit 38049e4ea8b342b6c5f7705e69c2e0034dc67914.
This can be fixed in radvd.
2023-03-21 21:18:53 +01:00
Franco Fichtner
b50e529511 openvpn: style sweep 2023-03-21 19:50:50 +01:00
Franco Fichtner
38049e4ea8 dhcp: radvd HUP brings back the infamous "can't join ipv6-allrouters" error
PR: https://forum.opnsense.org/index.php?topic=33148.0
2023-03-21 19:05:10 +01:00
Ad Schellevis
c8970545a7 VPN: OpenVPN: Connection Status - empty (null || '') on start/stop/restart should respond with an error. as discussed with @fichtner 2023-03-21 16:32:13 +01:00
Ad Schellevis
b9a1633a18 VPN: OpenVPN: Connection Status - refactor to MVC closes https://github.com/opnsense/core/issues/6382
o rename virtual_addr --> virtual_address in status call out
o add new endpoints to search connections and routes, kill sessions and service control
o remove old status page status_openvpn.php and change ACL and Menu registration
o offer two tab view on sessions / routes
o service controls (restart/start/stop) are shown for non client based records (p2p and client mode) or when no clients are connected.
2023-03-21 15:25:59 +01:00
Franco Fichtner
2d31af2a5e firewall: remove debug 2023-03-21 10:07:42 +01:00
Franco Fichtner
cc6857e597 ui: since touched make it 100% correct 2023-03-21 09:56:33 +01:00
Franco Fichtner
25f7d0e407 unbound: use deferred.reject() to clear spinner 2023-03-21 09:50:43 +01:00
Franco Fichtner
3032474e9f unbound: fix typo and adjust message
Try to to point user to do something and instead just tell them why
this cannot be accepted.
2023-03-21 09:31:00 +01:00