File: external.rb

package info (click to toggle)
ruby-amqp 1.8.0-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 2,508 kB
  • sloc: ruby: 8,272; sh: 11; makefile: 10
file content (27 lines) | stat: -rw-r--r-- 905 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# encoding: utf-8

module AMQP

  # Manages the encoding of credentials for the EXTERNAL authentication
  # mechanism.
  class AuthMechanismAdapter::External < AuthMechanismAdapter

    auth_mechanism "EXTERNAL"

    # Encodes a username and password for the EXTERNAL mechanism. Since
    # authentication is handled by an encapsulating protocol like SSL or
    # UNIX domain sockets, EXTERNAL doesn't pass along any username or
    # password information at all and this method always returns the
    # empty string.
    #
    # @param [String] username The username to encode. This parameter is
    #   ignored.
    # @param [String] password The password to encode. This parameter is
    #   ignored.
    # @return [String] The username and password, encoded for the
    #   EXTERNAL mechanism. This is always the empty string.
    def encode_credentials(username, password)
      ""
    end
  end
end