lib/ronin/network/telnet.rb in ronin-0.2.4 vs lib/ronin/network/telnet.rb in ronin-0.3.0

- old
+ new

@@ -1,9 +1,7 @@ # -#-- -# Ronin - A Ruby platform designed for information security and data -# exploration tasks. +# Ronin - A Ruby platform for exploit development and security research. # # Copyright (c) 2006-2009 Hal Brodigan (postmodern.mod3 at gmail.com) # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -16,11 +14,10 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -#++ # require 'ronin/network/extensions/telnet' module Ronin @@ -34,59 +31,75 @@ # The default timeout DEFAULT_TIMEOUT = 10 # - # Returns the default Ronin Telnet port. + # @return [Integer] + # The default Ronin Telnet port. # def Telnet.default_port @@telnet_default_port ||= DEFAULT_PORT end # - # Sets the default Ronin Telnet port to the specified _port_. + # Sets the default Ronin Telnet port. # + # @param [Integer] port + # The new default Ronin Telnet port. + # def Telnet.default_port=(port) @@telnet_default_port = port end # - # Returns the default Ronin Telnet prompt. + # @return [Regexp] + # The default Ronin Telnet prompt pattern. # def Telnet.default_prompt @@telnet_default_prompt ||= DEFAULT_PROMPT end # - # Sets the default Ronin Telnet prompt to the specified _prompt_. + # Sets the default Ronin Telnet prompt pattern. # + # @param [Regexp] prompt + # The new default Ronin Telnet prompt pattern. + # def Telnet.default_prompt=(prompt) @@telnet_default_prompt = prompt end # - # Returns the default Ronin Telnet timeout. + # @return [Integer] + # The default Ronin Telnet timeout. # def Telnet.default_timeout @@telnet_default_timeout ||= DEFAULT_TIMEOUT end # - # Sets the default Ronin Telnet timeout to the specified _timeout_. + # Sets the default Ronin Telnet timeout. # + # @param [Integer] timeout + # The new default Ronin Telnet timeout. + # def Telnet.default_timeout=(timeout) @@telnet_default_timeout = timeout end # - # Returns the Ronin Telnet proxy. + # @return [Telnet, IO, nil] + # The Ronin Telnet proxy. # def Telnet.proxy @@telnet_proxy ||= nil end # - # Sets the Ronin Telnet proxy to _new_proxy_. + # Sets the Ronin Telnet proxy. + # + # @param [Telnet, IO, nil] new_proxy + # The new Ronin Telnet proxy. # def Telnet.proxy=(new_proxy) @@telnet_proxy = new_proxy end end