From 3522a608c5d57fdf1845111cff40d987c6348f9d Mon Sep 17 00:00:00 2001 From: Tod Beardsley Date: Mon, 23 Jan 2012 16:00:54 -0600 Subject: [PATCH] Adds a default context for the TFTP Client lib. For use with nonstandard routing. --- lib/rex/proto/tftp/client.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/rex/proto/tftp/client.rb b/lib/rex/proto/tftp/client.rb index 82ae2641de..f01c477163 100644 --- a/lib/rex/proto/tftp/client.rb +++ b/lib/rex/proto/tftp/client.rb @@ -52,7 +52,7 @@ class Client self.local_port = params["LocalPort"] || (1025 + rand(0xffff-1025)) self.peer_host = params["PeerHost"] || (raise ArgumentError, "Need a peer host.") self.peer_port = params["PeerPort"] || 69 - self.context = params["Context"] || {} + self.context = params["Context"] || {'Msf' => framework, 'MsfExploit' => self} self.local_file = params["LocalFile"] self.remote_file = params["RemoteFile"] || (::File.split(self.local_file).last if self.local_file) self.mode = params["Mode"] || "octet"