From c1c7daea00058fc20b85fd1628bb35ddd7bcef23 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 21 May 2018 10:09:54 +0200 Subject: Prevent malicious peer from replaying user ping --- include/Channel.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include/Channel.hpp') diff --git a/include/Channel.hpp b/include/Channel.hpp index 28d174b..26b5286 100644 --- a/include/Channel.hpp +++ b/include/Channel.hpp @@ -63,12 +63,12 @@ namespace dchat void update(); // Returns 0 if we are offline - u64 getSyncedTimestampUtcCombined(); + u32 getSyncedTimestampUtcInSec(); static void setCurrent(Channel *channel); static Channel* getCurrent(); private: - void sendPing(u32 pingCounter, u64 pingTimestamp); + void sendPing(u32 pingTimestampSec); protected: odhtdb::Database *database; odhtdb::DatabaseNode databaseNodeInfo; -- cgit v1.2.3