Marius Tomaschewski
348f524f0a
reorder config to add all global options or option declarations to the dhcpService object instead to create new service object (bsc#886094,ISC-Bugs#37876). [+ dhcp-4.2.x-contrib-conf-to-ldap-reorder.886094.patch] - Applied an upstream patch by Thomas Markwalder adding missed mapping of SHA TSIG algorithm names to their constants to enable hmac-sha1, hmac_sha224, hmac_sha256, hmac_sha384 and hmac_sha512 authenticated dynamic DNS updates (bsc#890731, ISC-Bugs#36947). [+ dhcp-4.2.x-ddns-tsig-hmac-sha-support.890731.patch] - Decline IPv6 addresses on Duplicate Address Detection failure and stop client message exchanges on reached MRD rather than at some point after it. Applied fedora patches by Jiri Popelka and added DAD reporting via exit 3 to the dhclient-script and a fix to use correct address variables in the DEPREF6 action (bsc#872609,ISC-Bugs#26735,ISC-Bugs#21238). [+ dhcp-4.2.x-dhcpv6-decline-on-DAD-failure.872609.patch, + dhcp-4.2.x-dhcpv6-retransmission-until-MRD.872609.patch] - Applied backport patch by William Preston avoiding to bind ddns socket in the server when ddns-update-style is none (bsc#891655). [+ dhcp-4.2.x-disable-unused-ddns-port-in-server.891655.patch] - Applied patch for the contrib/ldap/dhcpd-conf-to-ldap script fixing subclass statement handling (bnc#878846,[ISC-Bugs #36409]) [+ dhcp-4.2.4-P2-bnc878846-conf-to-ldap.patch] - Updated licence statement and FSF address in our scripts. - Added missed service_add_pre macro calls for dhcrelay services OBS-URL: https://build.opensuse.org/package/show/network:dhcp/dhcp?expand=0&rev=141
58 lines
1.9 KiB
Diff
58 lines
1.9 KiB
Diff
Author: Jiri Popelka <jpopelka@redhat.com>
|
|
References: bsc#872609, ISC-Bugs#21238
|
|
Upstream: yes
|
|
|
|
In client initiated message exchanges stop retransmission upon
|
|
reaching the MRD rather than at some point after it (#559153)
|
|
(Submitted to dhcp-bugs@isc.org - [ISC-Bugs #21238])
|
|
|
|
diff --git a/client/dhc6.c b/client/dhc6.c
|
|
index f8ad25d..63cbb65 100644
|
|
--- a/client/dhc6.c
|
|
+++ b/client/dhc6.c
|
|
@@ -365,7 +365,7 @@ dhc6_retrans_init(struct client_state *client)
|
|
static void
|
|
dhc6_retrans_advance(struct client_state *client)
|
|
{
|
|
- struct timeval elapsed;
|
|
+ struct timeval elapsed, elapsed_after_RT;
|
|
|
|
/* elapsed = cur - start */
|
|
elapsed.tv_sec = cur_tv.tv_sec - client->start_time.tv_sec;
|
|
@@ -382,6 +382,8 @@ dhc6_retrans_advance(struct client_state *client)
|
|
elapsed.tv_sec += 1;
|
|
elapsed.tv_usec -= 1000000;
|
|
}
|
|
+ elapsed_after_RT.tv_sec = elapsed.tv_sec;
|
|
+ elapsed_after_RT.tv_usec = elapsed.tv_usec;
|
|
|
|
/*
|
|
* RT for each subsequent message transmission is based on the previous
|
|
@@ -419,13 +421,10 @@ dhc6_retrans_advance(struct client_state *client)
|
|
elapsed.tv_usec -= 1000000;
|
|
}
|
|
if (elapsed.tv_sec >= client->MRD) {
|
|
- /*
|
|
- * wake at RT + cur = start + MRD
|
|
- */
|
|
- client->RT = client->MRD +
|
|
- (client->start_time.tv_sec - cur_tv.tv_sec);
|
|
- client->RT = client->RT * 100 +
|
|
- (client->start_time.tv_usec - cur_tv.tv_usec) / 10000;
|
|
+ client->RT = client->MRD - elapsed_after_RT.tv_sec;
|
|
+ client->RT = client->RT * 100 - elapsed_after_RT.tv_usec / 10000;
|
|
+ if (client->RT < 0)
|
|
+ client->RT = 0;
|
|
}
|
|
client->txcount++;
|
|
}
|
|
@@ -1502,7 +1501,7 @@ check_timing6 (struct client_state *client, u_int8_t msg_type,
|
|
}
|
|
|
|
/* Check if finished (-1 argument). */
|
|
- if ((client->MRD != 0) && (elapsed.tv_sec > client->MRD)) {
|
|
+ if ((client->MRD != 0) && (elapsed.tv_sec >= client->MRD)) {
|
|
log_info("Max retransmission duration exceeded.");
|
|
return(CHK_TIM_MRD_EXCEEDED);
|
|
}
|