Land #9492, fix for reverse port forwards

MS-2855/keylogger-mettle-extension
scriptjunkie 2018-02-02 21:58:41 -06:00
commit b247b8e4f6
No known key found for this signature in database
GPG Key ID: E89DE255C921A2C6
1 changed files with 4 additions and 1 deletions

View File

@ -45,11 +45,14 @@ class Pivot
# Class request handler for all channels that dispatches requests
# to the appropriate class instance's DIO handler
def request_handler(client, packet)
handled = false
if packet.method == 'core_pivot_session_new'
handled = true
session_guid = packet.get_tlv_value(TLV_TYPE_SESSION_GUID)
listener_id = packet.get_tlv_value(TLV_TYPE_PIVOT_ID)
client.add_pivot_session(Pivot.new(client, session_guid, listener_id))
elsif packet.method == 'core_pivot_session_died'
handled = true
session_guid = packet.get_tlv_value(TLV_TYPE_SESSION_GUID)
pivot = client.find_pivot_session(session_guid)
if pivot
@ -57,7 +60,7 @@ class Pivot
client.remove_pivot_session(session_guid)
end
end
true
handled
end
end