Mitigate target_height attack

This commit is contained in:
tobtoht
2020-11-14 22:42:41 +01:00
parent d2d3978de6
commit d9dfef021f
6 changed files with 25 additions and 15 deletions
+2 -1
View File
@@ -459,7 +459,8 @@ void AppContext::onWSNodes(const QJsonArray &nodes) {
auto node = new FeatherNode(
obj.value("address").toString(),
(unsigned int)obj.value("height").toInt(),
obj.value("height").toInt(),
obj.value("target_height").toInt(),
obj.value("online").toBool());
QSharedPointer<FeatherNode> r = QSharedPointer<FeatherNode>(node);
l.append(r);