Module: Sockit
- Extended by:
- Connection, Support, V4::Connection, V4::Support, V5::Authentication, V5::Connection, V5::Support
- Defined in:
- lib/sockit/version.rb,
lib/sockit.rb,
lib/sockit/support.rb,
lib/sockit/connection.rb,
lib/sockit/v4/support.rb,
lib/sockit/v5/support.rb,
lib/sockit/v4/connection.rb,
lib/sockit/v5/connection.rb,
lib/sockit/v5/authentication.rb
Overview
Author: Zachary Patten
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Defined Under Namespace
Modules: Connection, Support, V4, V5
Constant Summary
- DEFAULT_CONFIG =
{ :version => 5, :ignore => %w( 127.0.0.1 ), :debug => false }
- COLORS =
{ :reset => "\e[0m\e[37m", :red => "\e[1m\e[31m", :green => "\e[1m\e[32m", :yellow => "\e[1m\e[33m", :blue => "\e[1m\e[34m" }
- VERSION =
"1.1.1"
Class Method Summary (collapse)
Instance Method Summary (collapse)
Methods included from Support
connect_via_socks?, dump, is_configured?, is_host_configured?, is_port_configured?, is_socks_v4?, is_socks_v5?, is_version_configured?, log
Methods included from Connection
Methods included from V4::Support
Methods included from V4::Connection
build_v4_connection_request, process_v4_connection_response
Methods included from V5::Support
build_v5_authentication_method_message, build_v5_authentication_status_message, build_v5_result_code_message
Methods included from V5::Connection
build_v5_connection_request, process_v5_connection_response
Methods included from V5::Authentication
build_v5_authentication_request, perform_v5_authenticate, perform_v5_password_authentication_request, process_v5_authentication_response
Class Method Details
+ (Object) config(&block)
54 55 56 57 58 59 60 61 |
# File 'lib/sockit.rb', line 54 def self.config(&block) @@config ||= OpenStruct.new(Sockit::DEFAULT_CONFIG) if block_given? yield(@@config) else @@config end end |
Instance Method Details
- (Object) config(&block)
63 64 65 66 67 68 69 70 |
# File 'lib/sockit.rb', line 63 def config(&block) @@config ||= OpenStruct.new(Sockit::DEFAULT_CONFIG) if block_given? yield(@@config) else @@config end end |