Commit graph

8679 commits

Author SHA1 Message Date
Ondřej Surý
46969dca75 Unobfuscate the code-flow logic in got_transfer_quota()
This refactors the code flow in got_transfer_quota() to not use the
CHECK() macro as it really obfuscates the code flow logic here.

(cherry picked from commit 00cb151f8e)
2023-09-04 08:04:52 +00:00
Aram Sargsyan
07b2d19b92 Reset the 'result' before using it again
The 'result' variable should be reset to ISC_R_NOTFOUND again,
because otherwise a log message could be logged about not being
able to get the TLS configuration based on on the 'result' value
from the previous calls to get the TSIG key.

(cherry picked from commit 6cab7fc627)
2023-09-04 08:04:52 +00:00
Mark Andrews
29a93d2889 Check that buf is large enough
(cherry picked from commit 299f519b09)
2023-09-01 14:06:27 +10:00
Mark Andrews
4c27f80476 Add missing "Design by Contract" REQUIREs
(cherry picked from commit b442ae8d3e)
2023-09-01 14:00:14 +10:00
Mark Andrews
0111782f1e Clear OpenSSL errors on context creation failures
(cherry picked from commit 96db614d69)
2023-09-01 13:45:34 +10:00
Mark Andrews
34a0bb146c Clear OpenSSL errors on engine errors
(cherry picked from commit 2ba62aebce)
2023-09-01 13:43:20 +10:00
Mark Andrews
b5b13771f2 Clear OpenSSL errors on EVP_PKEY_new failures
(cherry picked from commit 6df53cdb87)
2023-09-01 13:37:02 +10:00
Mark Andrews
4d37996b1a Clear OpenSSL errors on EC_KEY_get0_private_key failures
(cherry picked from commit 86b04368b0)
2023-09-01 13:34:14 +10:00
Mark Andrews
386e88d0e4 Clear OpenSSL errors on EVP_PKEY_get0_EC_KEY failures
(cherry picked from commit abd8c03592)
2023-09-01 13:30:30 +10:00
Mark Andrews
ababcd28c1 Clear OpenSSL errors on EVP_PKEY_get_bn_param failures
(cherry picked from commit d8a9adc821)
2023-09-01 13:24:02 +10:00
Mark Andrews
fb503aa275 Clear OpenSSL errors on EVP_MD_CTX_create failures
(cherry picked from commit 8529be30bb)
2023-09-01 13:13:59 +10:00
Mark Andrews
290896921d Clear OpenSSL errors on ECDSA_SIG_new failures
(cherry picked from commit eafcd41120)
2023-09-01 13:13:06 +10:00
Matthijs Mekking
6e078a79d5 After cache flush, restore serve-stale settings
When flushing the cache, we create a new cache database. The serve-stale
settings need to be restored after doing this. We already did this
for max-stale-ttl, but forgot to do this for stale-refresh-time.

(cherry picked from commit 3ae721db6c)
2023-08-31 11:13:08 +02:00
Mark Andrews
2282d5325a Only declare 'ex' if we will use it
Fixes
>>>     CID 464851:  Possible Control flow issues  (DEADCODE)
>>>     Execution cannot reach this statement: "BN_free(ex);".

Makes conditionals between declaring and use constistent. BN_free is
not needed as BIGNUM's returned by RSA_get0_key are not to be freed.
2023-08-29 22:05:27 +00:00
Matthijs Mekking
dab43f84dd Change default TTLsig to one week
Commit dc6dafdad1 allows larger TTL values
in zones that go insecure, and ignores the maximum zone TTL.

This means that if you use TTL values larger than 1 day in your zone,
your zone runs the risk of going bogus before it moves safely to
insecure.

Most resolvers by default cap the maximum TTL that they cache RRsets,
at one day (Unbound, Knot, PowerDNS) so that is fine. However, BIND 9's
default is one week.

Change the default TTLsig to one week, so that also for BIND 9
resolvers in the default cases responses for zones that are going
insecure will not be evaluated as bogus.

This change does mean that when unsigning your zone, it will take six
days longer to safely go insecure, regardless of what TTL values you
use in the zone.

(cherry picked from commit 32686beabc)
2023-08-02 12:19:25 +02:00
Matthijs Mekking
a21407d062 Ignore max-zone-ttl on dnssec-policy insecure
Allow larger TTL values in zones that go insecure. This is necessary
because otherwise the zone will not be loaded due to the max-zone-ttl
of P1D that is part of the current insecure policy.

In the keymgr.c code, default back to P1D if the max-zone-ttl is set
to zero.

(cherry picked from commit dc6dafdad1)
2023-08-01 09:53:03 +02:00
Mark Andrews
b64aa2d7a2 Return REFUSED if GSSAPI is not configured
Return REFUSED if neither a keytab nor a gssapi credential is
configured to GSSAPI/TKEY requests.

(cherry picked from commit b5076014b9)
2023-07-29 05:46:32 +10:00
Mark Andrews
c36d41d39c Mark a primary as unreachable on timed out in xfin
When a primary server is not responding, mark it as temporarialy
unreachable.  This will prevent too many zones queuing up on a
unreachable server and allow the refresh process to move onto
the next primary sooner once it has been so marked.

(cherry picked from commit 621c117101)
2023-07-22 09:00:08 +10:00
Aram Sargsyan
4fdb57a1f3 Add shutdown checks in dns_catz_dbupdate_callback()
When a zone database update callback is called, the 'catzs' object,
extracted from the callback argument, might be already shutting down,
in which case the 'catzs->zones' can be NULL and cause an assertion
failure when calling isc_ht_find().

Add an early return from the callback if 'catzs->shuttingdown' is true.

Also check the validity of 'catzs->zones' after locking 'catzs' in
case there is a race with dns_catz_shutdown_catzs() running in another
thread.

(cherry picked from commit 28bb419edc)
2023-07-06 11:27:45 +00:00
Ondřej Surý
26bb402b44 Run RPZ and catalog zones tasks in exclusive mode
All the heavy RPZ and CATZ work is already running with offloaded
threads, and running the remaining small functions in exclusive mode
offers more synchronization guaranties.

Move the update notify registration code from the offloaded
dns__catz_update_cb() function into dns__catz_done_cb().

After this change, it should be safe to remove the lock/unlock code
from the dns_catz_dbupdate_register() and dns_catz_dbupdate_unregister()
functions, as they were causing a benign TSAN lock-order-inversion
report.
2023-07-06 10:44:03 +00:00
Aram Sargsyan
c67ce97045 Fix a data race between the dns_zone and dns_catz modules
The dns_zone_catz_enable_db() and dns_zone_catz_disable_db()
functions can race with similar operations in the catz module
because there is no synchronization between the threads.

Add catz functions which use the view's catalog zones' lock
when registering/unregistering the database update notify callback,
and use those functions in the dns_zone module, instead of doing it
directly.

(cherry picked from commit 6f1f5fc307)
2023-07-06 10:44:03 +00:00
Evan Hunt
995b78ea4e clean up numbering of FETCHOPT and ADDRINFO flags
in the past there was overlap between the fields used
as resolver fetch options and ADB addrinfo flags. this has
mostly been eliminated; now we can clean up the rest of
it and remove some confusing comments.

(cherry picked from commit 0955cf1af5)
2023-07-04 11:58:09 -07:00
Mark Andrews
c73876fa90 Emit deprecated warning for K* file pairs
We try reading the same file using different methods so only
emit a warning if we successfully read the file.

(cherry picked from commit e3e20ed76e)
2023-06-29 10:52:48 +10:00
Mark Andrews
2376abc18e Restore the ability to read legacy K*+157+* files
The ability to read legacy HMAC-MD5 K* keyfile pairs using algorithm
number 157 was accidentally lost when the algorithm numbers were
consolidated into a single block, in commit
09f7e0607a.

The assumption was that these algorithm numbers were only known
internally, but they were also used in key files. But since HMAC-MD5
got renumbered from 157 to 160, legacy HMAC-MD5 key files no longer
work.

Move HMAC-MD5 back to 157 and GSSAPI back to 160.  Add exception for
GSSAPI to list_hmac_algorithms.

(cherry picked from commit 3f93d3f757)
2023-06-29 10:32:10 +10:00
Mark Andrews
5739b4817a
In rctx_answer return DNS_R_DELEGATION on NOFOLLOW
When DNS_FETCHOPT_NOFOLLOW is set DNS_R_DELEGATION needs to be
returned to restart the resolution process rather than converting
it to ISC_R_SUCCESS.

(cherry picked from commit ea11650376)
2023-06-28 12:32:26 +02:00
Mark Andrews
7f2eeb60ee
Skip some QNAME mininisation queries if possible
If we know that the NS RRset for an intermediate label doesn't exist
on cache contents don't query using that name when looking for a
referral.

(cherry picked from commit 80bc0ee075)
2023-06-28 12:32:23 +02:00
Mark Andrews
b3a97da7a7
Use NS rather than A records for qname-minimization relaxed
Remove all references to DNS_FETCHOPT_QMIN_USE_A and adjust
the expected tests results in the qmin system test.

(cherry picked from commit dd00b3c50b)
2023-06-28 12:31:49 +02:00
Mark Andrews
0d3693f08f Remove unnecessary REQUIRE in dns_resolver_attach
There is no harm in aquiring an additional reference to the resolver
after it has started shutting down.  All the REQUIRE was doing was
introducing a point of failure when shutting down the server.
2023-06-27 05:19:56 +00:00
Mark Andrews
e7e29278a8
Handle FORMERR on unknown EDNS option that are echoed
If the resolver received a FORMERR response to a request with
an DNS COOKIE option present that echoes the option back, resend
the request without an DNS COOKIE option present.

(cherry picked from commit f3b24ba789)
2023-06-26 16:36:11 +02:00
Michal Nowak
d527fca768 BIND 9.18.16
-----BEGIN SSH SIGNATURE-----
 U1NIU0lHAAAAAQAAARcAAAAHc3NoLXJzYQAAAAMBAAEAAAEBANamVSTMToLcHCXRu1f52e
 tTJWV3T1GSVrPYXwAGe6EVC7m9CTl06FZ9ZG/ymn1S1++dk4ByVZXf6dODe2Mu0RuqGmyf
 MUEMKXVdj3cEQhgRaMjBXvIZoYAsQlbHO2BEttomq8PhrpLRizDBq4Bv2aThM0XN2QqSGS
 ozwYMcPiGUoMVNcVrC4ZQ+Cptb5C4liqAcpRqrSo8l1vcNg5b1Hk6r7NFPdx542gsGMLae
 wZrnKn3LWz3ZXTGeK2cRmBxm/bydiVSCsc9XjB+tWtIGUpQsfaXqZ7Hs6t+1f1vsnu88oJ
 oi1dRBo3YNRl49UiCukXWayQrPJa8wwxURS9W28JMAAAADZ2l0AAAAAAAAAAZzaGE1MTIA
 AAEUAAAADHJzYS1zaGEyLTUxMgAAAQCvKOzeCryYGKi7lhj2xQB8mNVPoyQtUV9h1BgFRR
 AxBbFhIfDW2LnZWJmYspWT+6u5m3E/F5bk2JxngQWrTwRQ3N4ur8IxdPytw8R9oixxR3a6
 TVVXAM29dtEWf+nrGQQsLd8pYA0C1HpIW0m8h6IuSjl08aSQzs7c7/G4T5F2+vbxqSjMpR
 uP4w7AweBpT/Jb1oBmSCAiBeGnfKtQVXwW5qDph10y3+ZinYmoRRf97xIk2Au79TyQHmi3
 NCVpSKmJdfs4Uqe4dIhevjiITBCsm60BsL4RC0ABNcbtxX/Ui9IGbC+OxI6csa2eOB5hYx
 894SXj9vAjSJIdql8YxIDd
 -----END SSH SIGNATURE-----
gpgsig -----BEGIN SSH SIGNATURE-----
 U1NIU0lHAAAAAQAAARcAAAAHc3NoLXJzYQAAAAMBAAEAAAEBANamVSTMToLcHCXRu1f52e
 tTJWV3T1GSVrPYXwAGe6EVC7m9CTl06FZ9ZG/ymn1S1++dk4ByVZXf6dODe2Mu0RuqGmyf
 MUEMKXVdj3cEQhgRaMjBXvIZoYAsQlbHO2BEttomq8PhrpLRizDBq4Bv2aThM0XN2QqSGS
 ozwYMcPiGUoMVNcVrC4ZQ+Cptb5C4liqAcpRqrSo8l1vcNg5b1Hk6r7NFPdx542gsGMLae
 wZrnKn3LWz3ZXTGeK2cRmBxm/bydiVSCsc9XjB+tWtIGUpQsfaXqZ7Hs6t+1f1vsnu88oJ
 oi1dRBo3YNRl49UiCukXWayQrPJa8wwxURS9W28JMAAAADZ2l0AAAAAAAAAAZzaGE1MTIA
 AAEUAAAADHJzYS1zaGEyLTUxMgAAAQBELZ30W2rUZkbIql8Lz0scLApeCnAdR10MIpvxZ2
 K+nbAhkovhD3zERJv7zdQVfv2WFykDwNGeY5kwo1fxLtVaVguwe+teJM3olG16VXQM9jpu
 iztHDD28Jm3o5/gZH51MYROXx+RMzhc6g9DcUY4+fpjySNW+SREoF46C0O8J1QO2p2h7Rk
 VYqlP6FuTLtyzOlNXjoPkVycLQvTCj+MS483OXymUOqqaufCIGZ2u10f/8NzBR9b9exjWp
 jP5WzFgFz20LZO4ZIhlDnzva60Jxtr5QOzRtAt3f7NPtQWKfVUepo09GlhpdL/tYBMrHkA
 on25nJIj95wPid00X6+Cw/
 -----END SSH SIGNATURE-----

Merge tag 'v9.18.16' into bind-9.18

BIND 9.18.16
2023-06-21 19:51:22 +02:00
Ondřej Surý
a29de517fa
Refactor how we map isc_result_t <-> dns_rcode_t
The mapping functions between isc_result_t and dns_rcode_t could return
both isc_result_t values not defined in the header and dns_rcode_t
values not defined in the header because it blindly maps anything
withing full 12-bits defined for RCODEs to isc_result_t and back.

Refactor the dns_result_{from,to}rcode() functions to always return
valid isc_result_t and dns_rcode_t values by explicitly mapping the
values to each other and returning DNS_R_SERVFAIL (dns_rcode_servfail)
when encountering value out of the defined range.

(cherry picked from commit b53d1d7069)
2023-06-15 16:27:17 +02:00
Aram Sargsyan
6154eab679 Fix catz db update callback registration logic error
When a catalog zone is updated using AXFR, the zone database is changed,
so it is required to unregister the update notification callback from
the old database, and register it for the new one.

Currently, here is the order of the steps happening in such scenario:

1. The zone.c:zone_startload() function registers the notify callback
   on the new database using dns_zone_catz_enable_db()
2. The callback, when called, notices that the new 'db' is different
   than 'catz->db', and unregisters the old callback for 'catz->db',
   marks that it's unregistered by setting 'catz->db_registered' to
   false, then it schedules an update if it isn't already scheduled.
3. The offloaded update process, after completing its job, notices that
   'catz->db_registered' is false, and (re)registers the update callback
   for the current database it is working on. There is no harm here even
   if it was registered also on step 1, and we can't skip it, because
   this function can also be called "artificially" during a
   reconfiguration, and in that case the registration step is required
   here.

A problem arises when before step 1 an update process was already
in a running state, operating on the old database, and finishing its
work only after step 2. As described in step 3, dns__catz_update_cb()
notices that 'catz->db_registered' is false and registers the callback
on the current database it is working on, which, at that state, is
already obsolete and unused by the zone. When it detaches the database,
the function which is responsible for its cleanup (e.g. free_rbtdb())
asserts because there is a registered update notify callback there.

To fix the problem, instead of delaying the (re)registration to step 3,
make sure that the new callback is registered and 'catz->db_registered'
is accordingly marked on step 2.

(cherry picked from commit 998765fea5)
2023-06-14 09:24:41 +00:00
Ondřej Surý
e9d5219fca
Improve RBT overmem cache cleaning
When cache memory usage is over the configured cache size (overmem) and
we are cleaning unused entries, it might not be enough to clean just two
entries if the entries to be expired are smaller than the newly added
rdata.  This could be abused by an attacker to cause a remote Denial of
Service by possibly running out of the operating system memory.

Currently, the addrdataset() tries to do a single TTL-based cleaning
considering the serve-stale TTL and then optionally moves to overmem
cleaning if we are in that condition.  Then the overmem_purge() tries to
do another single TTL based cleaning from the TTL heap and then continue
with LRU-based cleaning up to 2 entries cleaned.

Squash the TTL-cleaning mechanism into single call from addrdataset(),
but ignore the serve-stale TTL if we are currently overmem.

Then instead of having a fixed number of entries to clean, pass the size
of newly added rdatasetheader to the overmem_purge() function and
cleanup at least the size of the newly added data.  This prevents the
cache going over the configured memory limit (`max-cache-size`).

Additionally, refactor the overmem_purge() function to reduce for-loop
nesting for readability.
2023-06-08 11:43:18 +02:00
Aram Sargsyan
d91edda639 Fix a clients-per-query miscalculation bug
The number of clients per query is calculated using the pending
fetch responses in the list. The dns_resolver_createfetch() function
includes every item in the list when deciding whether the limit is
reached (i.e. fctx->spilled is true). Then, when the limit is reached,
there is another calculation in fctx_sendevents(), when deciding
whether it is needed to increase the limit, but this time the TRYSTALE
responses are not included in the calculation (because of early break
from the loop), and because of that the limit is never increased.

A single client can have more than one associated response/event in the
list (currently max. two), and calculating them as separate "clients"
is unexpected. E.g. if 'stale-answer-enable' is enabled and
'stale-answer-client-timeout' is enabled and is larger than 0, then
each client will have two events, which will effectively halve the
clients-per-query limit.

Fix the dns_resolver_createfetch() function to calculate only the
regular FETCHDONE responses/events.

Change the fctx_sendevents() function to also calculate only FETCHDONE
responses/events. Currently, this second change doesn't have any impact,
because the TRYSTALE events were already skipped, but having the same
condition in both places will help prevent similar bugs in the future
if a new type of response/event is ever added.

(cherry picked from commit 2ae5c4a674)
2023-06-06 12:45:00 +00:00
Aram Sargsyan
db45cab546 Fix a lock-order-inversion bug in resolver.c
There is a lock-order-inversion (potential deadlock) in resolver.c,
because in dns_resolver_shutdown() a resolver bucket lock is locked
while the resolver lock itself is already locked, while in
fctx_sendevents() the resolver lock is locked while a bucket lock
is locked before calling that function in fctx__done_detach().

The resolver lock/unlock in dns_resolver_shutdown() was added back in
the 317e36d47e commit to make sure that
the function is finished before the resolver object is destroyed.

Since res->exiting is atomic, it should be possible to remove the
resolver locking in dns_resolver_shutdown() and add it to the
send_shutdown_events() function which requires it.

Also, since 'res->exiting' is now set while unlocked, the 'INSIST'
in spillattimer_countdown() is wrong, and is removed.
2023-06-06 11:02:24 +00:00
Aram Sargsyan
cd47429365 Add ClientQuota statistics channel counter
This counter indicates the number of the resolver's spilled
queries due to reaching the clients per query quota.

(cherry picked from commit 04648d7c2f)
2023-05-31 11:07:08 +00:00
Artem Boldariev
cec8947bc1
ZMGR: TLS contexts cache - properly synchronise access
This commit ensures that access to the TLS context cache within zone
manager is properly synchronised.

Previously there was a possibility for it to get unexpectedly
NULLified for a brief moment by a call to
dns_zonemgr_set_tlsctx_cache() from one thread, while being accessed
from another (e.g. from got_transfer_quota()). This behaviour could
lead to server abort()ing on configuration reload (under very rare
circumstances).

That behaviour has been fixed.

(cherry picked from commit 0b95cf74ff)
2023-05-26 15:24:51 +03:00
Evan Hunt
e9b6991357 fix handling of TCP timeouts
when a TCP dispatch times out, we call tcp_recv() with a result
value of ISC_R_TIMEDOUT; this cancels the oldest dispatch
entry in the dispatch's active queue, plus any additional entries
that have waited longer than their configured timeouts. if, at
that point, there were more dispatch entries still on the active
queue, it resumes reading, but until now it failed to restart
the timer.

this has been corrected: we now calculate a new timeout
based on the oldest dispatch entry still remaining.  this
requires us to initialize the start time of each dispatch entry
when it's first added to the queue.

in order to ensure that the handling of timed-out requests is
consistent, we now calculate the runtime of each dispatch
entry based on the same value for 'now'.

incidentally also fixed a compile error that turned up when
DNS_DISPATCH_TRACE was turned on.

(cherry picked from commit 0e800467ee)
2023-05-26 02:07:02 -07:00
Evan Hunt
afae1b65e8 prevent TSIG keys from being added to multiple rings
it was possible to add a TSIG key to more than one TSIG
keyring at a time, and this was in fact happening with the
session key, which was generated once and then added to the
keyrings for each view as it was configured.

this has been corrected and a REQUIRE added to dns_tsigkeyring_add()
to prevent it from happening again.
2023-05-25 15:08:48 -07:00
Aram Sargsyan
7713d2cb6d Check whether zone->db is a valid pointer before attaching
The zone_resigninc() function does not check the validity of
'zone->db', which can crash named if the zone was unloaded earlier,
for example with "rndc delete".

Check that 'zone->db' is not 'NULL' before attaching to it, like
it is done in zone_sign() and zone_nsec3chain() functions, which
can similarly be called by zone maintenance.

(cherry picked from commit fae0930eb8)
2023-05-15 12:01:23 +00:00
Ondřej Surý
e0620ca208
Honour the source-port when retrying in dns_dispatch
When retrying in the DNS dispatch, the local port would be forgotten on
ISC_R_ADDRINUSE, keep the configured source-port even when retrying.

Additionally, treat ISC_R_NOPERM same as ISC_R_ADDRINUSE.

Closes: #3986
(cherry picked from commit c8e8ccd026)
2023-05-05 15:40:12 +02:00
Mark Andrews
0eee434741 Cleanup orphaned empty-non-terminal NSEC3
When OPTOUT was in use we didn't ensure that NSEC3 records
for orphaned empty-non-terminals where removed.  Check if
there are orphaned empty-non-terminal NSEC3 even if there
wasn't an NSEC3 RRset to be removed in dns_nsec3_delnsec3.

(cherry picked from commit 27160c137f)
2023-04-25 06:46:08 +01:00
Ondřej Surý
fa2cb06c75
Implement maximum global and idle time for incoming XFR
After the dns_xfrin was changed to use network manager, the maximum
global (max-transfer-time-in) and idle (max-transfer-idle-in) times for
incoming transfers were turned inoperational because of missing
implementation.

Restore this functionality by implementing the timers for the incoming
transfers.

(cherry picked from commit d2377f8e04)
2023-04-21 17:21:32 +02:00
Evan Hunt
960e4dadd2
check for invalid protocol when dispatch fails
treat ISC_R_INVALIDPROTO as a networking error when it occurs.

(cherry picked from commit 2269a3e6fb)
2023-04-21 12:47:07 +02:00
Matthijs Mekking
bf5eea515d Add key state init debugging
When debugging an issue it can be useful to see what BIND initially
set the key states to.

(cherry picked from commit e752656a38)
2023-04-17 12:14:06 +02:00
Ondřej Surý
07720989a0
Eliminate the dead code in dst_api.c
In write_public_key() and write_key_state(), there were left-over checks
for result, that were effectively dead code after the last refactoring.
Remove those.

(cherry picked from commit 766366e934)
2023-04-05 09:11:24 +02:00
Ondřej Surý
7e7985c9c7 Attach catzs to catz instead of doing this explicitly
Instead of explicitly adding a reference to catzs (catalog zones) when
calling the update callback, attach the catzs to the catz (catalog zone)
object to keep it referenced for the whole time the catz exists.

(cherry picked from commit 2ded876db2)
2023-04-04 11:47:43 +00:00
Ondřej Surý
2bb4fa34cc
Fix xfrin_connect_done() error paths
The xfrin_connect_done() had several problems:

- it would not add the server to unreachable table in case of the
  failure coming from the dispatch [GL #3989]

- if dns_dispatch_checkperm() disallowed the connection, the xfr would
  be left undetached

- if xfrin_send_request() failed to send the request, the xfr would be
  left undetached

All of these have been fixed in this commit.

(cherry picked from commit 536e439c79)
2023-04-04 10:07:27 +02:00
Aram Sargsyan
7beda284d2 Do not resend TCP requests
The req_response() function is using 'udpcount' variable to resend
the request 'udpcount' times on timeout even for TCP requests,
which does not make sense, as it would use the same connection.

Add a condition to use the resend logic only for UDP requests.

(cherry picked from commit edcdb881da)
2023-04-03 16:18:39 +00:00
Aram Sargsyan
14084d8eac Perform request validation in req_response() before using the pointer
The 'request' pointer is used before it is checked. Perform the check
before using the pointer.

(cherry picked from commit 5b37359697)
2023-04-03 16:18:39 +00:00