len(label)].lower()
for label in line.strip().encode('ascii').split(b'.')]).decode('ascii'))
Thanks in advance :-)
--
WBRBW, Leonid Evdokimov, https://darkk.net.ru tel:+79816800702
PGP: 6691 DE6B 4CCD C1C1 76A0 0D4A E1F2 A980 7F50 FAB2
__
security bug and improving
code size a bit.
My goal of this specific submission is to reduce my local patch-stack
to ease further rebasing & merging.
I would be happy to see those patches either merged or declined
explicitly, but it's not up to me to decide. :-)
--
WBRBW, Leonid Evdoki
surf() takes 18256 cycles to generate u32[8*2] and needs ~290 opcodes.
chacha8() either takes 4086 cycles to generate same amount of entropy
with just ~100 opcodes, or 1944 cycles with 320 opcodes depending
on QUARTERROUND() inlining.
`gcc-13.2.0 -Os -mips32r2 -mtune=24kc -mips16` gives following
It's equally fast, but it's measurably smaller.
---
src/util.c | 34 +++---
1 file changed, 11 insertions(+), 23 deletions(-)
diff --git src/util.c src/util.c
index fefa8333..c27d77c4 100644
--- src/util.c
+++ src/util.c
@@ -61,6 +61,10 @@ static void surf(void)
u32
---
src/dnsmasq.c | 6 +++---
src/dnsmasq.h | 1 +
src/helper.c | 4 ++--
src/util.c| 21 +
4 files changed, 27 insertions(+), 5 deletions(-)
diff --git src/dnsmasq.c src/dnsmasq.c
index a9f26ae3..d15177f8 100644
--- src/dnsmasq.c
+++ src/dnsmasq.c
@@ -607,7 +607,7 @@
---
src/dnsmasq.c| 10 +++---
src/dnsmasq.h| 1 +
src/hash-questions.c | 2 ++
src/util.c | 47 +++-
4 files changed, 48 insertions(+), 12 deletions(-)
diff --git src/dnsmasq.c src/dnsmasq.c
index d15177f8..68c290a3 100644
--
It might be security vulnerability as rand64() is basically transmitted
to network in address6_allocate() and it might expose values for some of
next rand16() and rand32() calls as no other function calls rand64().
---
src/util.c | 2 --
1 file changed, 2 deletions(-)
diff --git src/util.c src/ut
8 is faster & smaller than SURF and, I assume, it's equally good
for this use-case.
I'm submitting these patches as a patch train hoping that it eases
review as the patches deal with a one issue at a time.
Leonid Evdokimov (6):
Fix -Wshadow: rand64() was mistakenly using its own
It reduces binary by ~80 bytes on x86_64 :-)
---
src/config.h | 8
src/util.c | 25 ++---
2 files changed, 26 insertions(+), 7 deletions(-)
diff --git src/config.h src/config.h
index e722e986..b86a53f3 100644
--- src/config.h
+++ src/config.h
@@ -144,6 +144,9 @@ HA
nsmasq/compare/ready-for-review-01-chacha8-prng...ready-for-review-02-memory-usage
I'll try to keep branches rebased on top of the main branch for a while.
--
WBRBW, Leonid Evdokimov, https://darkk.net.ru tel:+79816800702
PGP: 6691 DE6B 4
et. We can't know if it'll be merged to the main dnsmasq repo,
but extra testing and feedback kinda increases chances of that
happening :-)
[1] https://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/2024q3/017627.html
--
WBRBW, Leonid Evdokimov, https://darkk.net.ru tel:+79816800702
P
11 matches
Mail list logo