diag: trace RTC synchronization and WSS clock state
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
#include "sockets.h"
|
||||
#include "ql_rtos.h"
|
||||
#include <time.h>
|
||||
#include "time_diag.h"
|
||||
#include "rws_handshake.h"
|
||||
#ifdef LIBRWS_USING_MBED_TLS
|
||||
#include "mbedtls/base64.h"
|
||||
@@ -1945,7 +1946,8 @@ int rws_ssl_conn(_rws_socket *s)
|
||||
LOG_E("WSS requires a trusted root CA\n");
|
||||
goto exit;
|
||||
}
|
||||
if (time(NULL) < 1704067200) {
|
||||
stage = "check RTC time";
|
||||
if (talkingq_time_diag_wss_time() < 1704067200) {
|
||||
LOG_E("WSS requires valid network/RTC time before certificate verification\n");
|
||||
goto exit;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user