From e955fb69926a14dbefe410b984e80c00414807af Mon Sep 17 00:00:00 2001 From: Janus Varmarken Date: Fri, 21 Sep 2018 10:56:27 -0700 Subject: [PATCH] [minor work in progress] --- .../iotproject/detection/SignatureDetector.java | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/Code/Projects/SmartPlugDetector/src/main/java/edu/uci/iotproject/detection/SignatureDetector.java b/Code/Projects/SmartPlugDetector/src/main/java/edu/uci/iotproject/detection/SignatureDetector.java index 5c04c23..54feeba 100644 --- a/Code/Projects/SmartPlugDetector/src/main/java/edu/uci/iotproject/detection/SignatureDetector.java +++ b/Code/Projects/SmartPlugDetector/src/main/java/edu/uci/iotproject/detection/SignatureDetector.java @@ -39,13 +39,16 @@ public class SignatureDetector implements PacketListener { } -// private void performDetection() { -// // Let's start out simple by building a version that only works for signatures that do not span across multiple -// // TCP conversations... -// for (Conversation c : mTcpReassembler.getTcpConversations()) { -// boolean matchFound = isSequenceInConversation(c); -// } -// } + private void performDetection() { + // Let's start out simple by building a version that only works for signatures that do not span across multiple + // TCP conversations... + for (Conversation c : mTcpReassembler.getTcpConversations()) { + for (List sequence : mSignature) { + boolean matchFound = isSequenceInConversation(sequence, c); + + } + } + } /** * Examine if a {@link Conversation} contains a given sequence of packets. Note: the current implementation actually -- 2.34.1