Commit Graph

3967 Commits

Author SHA1 Message Date
DL6ER e460a67bb4 Fix overtime computation logic broken in PR #1312
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-04-07 23:01:01 +02:00
yubiuser 3ebb7b2c4a Merge pull request #1326 from pi-hole/new/stale_bot
Add stale bot to FTL repo
2022-04-02 22:41:40 +02:00
DL6ER 69f85ce8df Apply suggestions from code review
Co-authored-by: yubiuser <ckoenig@posteo.de>
2022-04-02 22:37:39 +02:00
yubiuser 4f6f6caa41 Merge pull request #1322 from pi-hole/fix/negative_replies
Fix query counts
2022-04-02 20:20:19 +02:00
DL6ER 4979e54b30 Add stale bot to FTL repo
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-04-02 16:42:04 +02:00
DL6ER 392ff15d72 Merge pull request #1312 from icyflame/update-init-overtime
Fix initOverTime's calculation of last slot timestamp
2022-04-02 14:57:06 +02:00
Siddharth Kannan 06b0606199 Fix initOverTime's calculation of last slot timestamp
initOverTime calculate's the last slot timestamp with the assumption that `OVERTIME_INTERVAL` will
allow atleast `OVERTIME_SLOTS` number of slots between now and the last slot in the current
hour. This leads it to calculate the timestamp of the last slot, and then assign timestamps to each
slot counting down from that timestamp.

This logic is not compatible with changes in the OVERTIME_INTERVAL and the MAXLOGAGE variables. Here
is a demonstration of a case where this can be shown clearly:

```
OVERTIME_INTERVAL = 60s (Each slot stores 1 minute of data)
MAXLOGAGE = 600s (Store date for only 10 minutes)
OVERTIME_SLOTS = 11 (MAXLOGAGE/OVERTIME_INTERVAL)
```

- Current time: 10:35
- Last slot time: 10:59:30
- First slot time: 10:48:30

Note that this logic *does* work as expected with the default minimum of 1 hour for the MAXLOGAGE
configuration variable.

Signed-off-by: Siddharth Kannan <mail@siddharthkannan.in>
2022-04-02 13:14:33 +09:00
yubiuser 6576eb699f Merge pull request #1323 from pi-hole/update/sqlite_3.38.2
Update SQLite to v3.38.2
2022-03-27 10:40:44 +02:00
DL6ER 77c5665d64 Update SQLite to v3.38.2
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-27 10:30:00 +02:00
DL6ER 8734b60a53 Ensure we subtract from the old reply counter when reply type changes
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-26 13:24:08 +01:00
DL6ER a24e187486 Add individual reply counters as well as their sum to the API + ensure we subtract from the previous reply counter when setting a new status
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-26 13:22:51 +01:00
DL6ER 5ac2ed2813 Merge pull request #1316 from abesnier/patch-1
Added support for compilation on MIPS platform
2022-03-26 12:23:16 +01:00
yubiuser 9ba75b7947 Merge pull request #1320 from pi-hole/update/sqlite_3.38.1
Update SQLite to 3.38.1
2022-03-20 09:48:35 +01:00
DL6ER fbe28c9f27 Update SQLite to v3.38.1
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-20 09:16:42 +01:00
yubiuser 7e45549a51 Merge pull request #1317 from pi-hole/fix/negative_replies
Adjust query type counters when importing from the database
2022-03-18 20:58:32 +01:00
DL6ER 7383842813 Merge pull request #1318 from pi-hole/tweak/escape
Be more precise about escaping invalid characters in queries
2022-03-18 17:52:02 +01:00
Christian König 4cf9129d7d Be more precise about escaping invalid characters in queries
Signed-off-by: Christian König <ckoenig@posteo.de>
2022-03-18 17:35:15 +01:00
DL6ER f527e733eb Merge pull request #1313 from icyflame/update-gc-remove-hardcoded-gc-interval
Replace reference to hard-coded default GCinterval value
2022-03-18 13:35:24 +01:00
DL6ER 213b7eb7f4 Adjust query type counters when importing from the database
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-18 13:05:19 +01:00
abesnier 9262fb91e7 Merge branch 'patch-1' of https://github.com/abesnier/FTL into patch-1 2022-03-16 10:29:54 +01:00
abesnier d6e19bd3ab Updated for simplication
Signed-off-by: abesnier <besnier_antoine@yahoo.fr>
2022-03-16 10:27:19 +01:00
abesnier a68908c91b Updated for simplication
Signed-off-by: abesnier <besnier_antoine@yahoo.fr>
2022-03-16 09:40:26 +01:00
abesnier f14051894d Added support for compilation on MIPS platform
Compiling FTL on MIPS platform would fail with the following error:
/home/git/FTL/src/database/../shmem.h:57:41: error: expected declaration specifiers or ‘...’ before numeric constant
   57 | ASSERT_SIZEOF(countersStruct, 240, 240, 240);
This error originates from static_assert.h, where there are no definition of ASSERT_SIZEOF and STATIC_ASSERT for the mips architecture.
Support added in this commit.
2022-03-16 09:18:44 +01:00
yubiuser e62063adc1 Merge pull request #1310 from pi-hole/tweak/blockind_status
Reload blocking mode independently of incoming queries
2022-03-08 13:02:44 +01:00
Christian König 29cc88212e Change blocking mode to blocking status in comment
Signed-off-by: Christian König <ckoenig@posteo.de>
2022-03-08 12:59:10 +01:00
Siddharth Kannan 2d1e7adf7b Replace reference to hard-coded default GCinterval value
This hard-coded GCinterval value makes any change to the macro defining the GCinterval ineffective
when the GC runs.

For e.g., if I reduce the GC from once an hour to once every 3 minutes, the GC runs every 3 minutes,
but the mintime is set to the start of the next hour, which wipes everything from the overTime data.

I believe that this change is safe and can be merged and shipped to existing users because the
GCinterval value is not configurable and users who don't build the PiHole version that they are
running will not be affected by this change.

Signed-off-by: Siddharth Kannan <mail@siddharthkannan.in>
2022-03-07 00:40:42 +09:00
DL6ER 7f7dc2e9fa Reload blocking mode independently of incoming queries
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-03-01 04:27:40 +01:00
yubiuser cb0d42db1c Merge pull request #1307 from pi-hole/update/sqlite_3.38.0
Update SQLite to v3.38.0
2022-02-23 18:19:49 +01:00
DL6ER 8ff5b0a47e Update SQLite to v3.38.0
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-23 06:11:06 +01:00
yubiuser 08de9d0e41 Merge pull request #1305 from pi-hole/fix/negative_others
Fix negative "others" in Upstream Servers pie chart
2022-02-18 14:45:44 +01:00
DL6ER da62df2fa6 Fix how we compute the total number of DNS packets (not queries)
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-18 12:33:05 +01:00
Adam Warner 9b087b1388 Merge pull request #1304 from pi-hole/master
sync: master to development
2022-02-16 15:49:01 +00:00
Adam Warner 53bff37ade add dco.yml to ignore requirement from Org members (it's already implied!) 2022-02-16 15:43:17 +00:00
Adam Warner 13ea3c62ab remove the CONTENT_COMPARISON setting (defaults to false) 2022-02-16 15:41:57 +00:00
Adam Warner 52e6b95858 Merge pull request #1300 from pi-hole/development
Pi-hole FTL v5.14
v5.14
2022-02-12 19:58:34 +00:00
yubiuser 3a5c0acae4 Merge pull request #1299 from pi-hole/blocklist
Rename upstream 'blocklist' => 'blocked' and 'cache' => 'cached'
2022-02-12 18:36:36 +01:00
Christian König 1e880d3c80 penny-pitchy
Signed-off-by: Christian König <ckoenig@posteo.de>
2022-02-12 13:21:05 +01:00
Christian König 7417a83a10 Rename upstream blocklist to blocked
Signed-off-by: Christian König <ckoenig@posteo.de>
2022-02-12 10:08:23 +01:00
DL6ER 1dbdce0ad4 Merge pull request #1281 from pi-hole/update/dnsmasq
Update embedded dnsmasq to v2.87test8
2022-02-09 17:37:50 +01:00
DL6ER 2e479f6a8c Merge pull request #1286 from stuXORstu/tweak/domainid_perf
performance improvements for findDomainID()
2022-02-08 20:31:21 +01:00
DL6ER 1a9a7aa725 Update dnsmasq version
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-08 20:29:23 +01:00
Simon Kelley 584e752ee4 Add --conf-script
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-08 20:23:42 +01:00
Simon Kelley 5bd230a436 Ask netlink for new address events unconditionally.
The circumstances under which actions occur depending on
configuration is now controlled only by newaddress() in network.c

Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-08 20:22:11 +01:00
DL6ER fd244b273c Merge branch 'development' into update/dnsmasq 2022-02-06 22:12:05 +01:00
Simon Kelley ec386ccef5 Tidy iface_check().
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-06 22:10:49 +01:00
stuXORstu 8410af394a Updates for tweak/domainid_perf to implement better hash based comparisions
Signed-off-by: stuXORstu <stuxorstu@gmail.com>
2022-02-06 12:34:08 +00:00
yubiuser 76d332861b Merge pull request #1297 from pi-hole/fix/DB_upstream_reply
Prevent excessive reply times in the Query Log after restarting
2022-02-05 12:12:48 +01:00
DL6ER 2c91e487fd Store NULL in the REPLY_TIME column when the reply time is not available
Signed-off-by: DL6ER <dl6er@dl6er.de>
2022-02-05 10:11:20 +01:00
DL6ER 3f472e971b Merge branch 'development' into update/dnsmasq 2022-02-05 09:53:45 +01:00
DL6ER 64005f92be Merge pull request #1296 from pi-hole/fix/sparse_ecs
Do not warn about less-than-full addresses when analyzing EDNS(0) packets
2022-02-04 20:05:06 +01:00