nts: rework NTS-KE retry interval

Make the NTS-KE retry interval exponentially increasing, using a factor
provided by the NKE session. Use shorter intervals when the server is
refusing TCP connections or the connection is closed or timing out
before the TLS handshake.
This commit is contained in:
Miroslav Lichvar
2020-03-25 17:01:27 +01:00
parent bcdbbbd694
commit 66dc2b6d6b
7 changed files with 68 additions and 8 deletions

View File

@@ -393,3 +393,11 @@ NKC_GetNtsData(NKC_Instance inst,
return i;
}
/* ================================================== */
int
NKC_GetRetryFactor(NKC_Instance inst)
{
return NKSN_GetRetryFactor(inst->session);
}