Skip to content

Commit

Permalink
Add Needle Length to memory search request
Browse files Browse the repository at this point in the history
  • Loading branch information
sjanusz-r7 committed Nov 29, 2023
1 parent 8b757c9 commit f8a4f22
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,10 @@ def search(needles, min_search_len = 5, match_len = 500)
request = Packet.create_request(COMMAND_ID_STDAPI_SYS_PROCESS_MEMORY_SEARCH)

request.add_tlv(TLV_TYPE_PID, process.pid)
needles.each { | needle | request.add_tlv(TLV_TYPE_MEMORY_SEARCH_NEEDLE, needle) }
needles.each do | needle |
request.add_tlv(TLV_TYPE_MEMORY_SEARCH_NEEDLE, needle)
request.add_tlv(TLV_TYPE_MEMORY_SEARCH_NEEDLE_LEN, needle.length)
end
request.add_tlv(TLV_TYPE_MEMORY_SEARCH_MATCH_LEN, match_len)
request.add_tlv(TLV_TYPE_UINT, min_search_len)

Expand Down

0 comments on commit f8a4f22

Please sign in to comment.