Fix device registration expiration with system clock adjusted

When system clock is being adjusted on device during registration,
the registration process could prematurely be considered expired
when the clock rolls forward. Change the logic to use retry counters
instead of absolute expiration time to mitigate this problem.

BUG: 26107811
Change-Id: I31de553bedabd7b501ed1d222932d4f379018dd2
Reviewed-on: https://weave-review.googlesource.com/1893
Reviewed-by: Vitaly Buka <vitalybuka@google.com>
1 file changed