Sha256: 5ffde6b110fa84a512115d3554c201e667a7c2683b0a3ac4d26fad036a545a7d

Contents?: true

Size: 1.38 KB

Versions: 28

Compression:

Stored size: 1.38 KB

Contents

module RubySMB
  module Gss
    #
    # This module provides GSS based authentication.
    #
    module Provider
      # A special constant implying that the authenticated user is anonymous.
      IDENTITY_ANONYMOUS = :anonymous
      # The result of a processed GSS request.
      Result = Struct.new(:buffer, :nt_status, :identity, :is_guest) do
        def is_anonymous
          identity == Gss::Provider::IDENTITY_ANONYMOUS
        end
      end

      #
      # The base class for a GSS authentication provider. This class defines a common interface and is not usable as a
      # provider on its own.
      #
      class Base
        # Create a new, client-specific authenticator instance. This new instance is then able to track the unique state
        # of a particular client / connection.
        #
        # @param [Server::ServerClient] server_client the client instance that this the authenticator will be for
        def new_authenticator(server_client)
          raise NotImplementedError
        end

        #
        # Whether or not anonymous authentication attempts should be permitted.
        #
        attr_accessor :allow_anonymous

        #
        # Whether or not unknown users should be allowed to authenticate as guests.
        #
        attr_accessor :allow_guests
      end
    end
  end
end

require 'ruby_smb/gss/provider/authenticator'
require 'ruby_smb/gss/provider/ntlm'

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
ruby_smb-3.3.13 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.12 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.11 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.10 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.9 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.7 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.6 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.5 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.4 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.3 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.2 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.1 lib/ruby_smb/gss/provider.rb
ruby_smb-3.3.0 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.8 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.7 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.6 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.5 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.4 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.3 lib/ruby_smb/gss/provider.rb
ruby_smb-3.2.2 lib/ruby_smb/gss/provider.rb