File: service_client_credentials.rb

package info (click to toggle)
ruby-ms-rest 0.7.6-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 424 kB
  • sloc: ruby: 693; makefile: 4
file content (22 lines) | stat: -rw-r--r-- 647 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# encoding: utf-8
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.

module MsRest
  #
  # Class that serves as a base for all authentications classes.
  #
  class ServiceClientCredentials

    AUTHORIZATION = 'authorization'

    #
    # Base method for performing authentication of HTTP requests.
    # @param request [Net::HTTPRequest] HTTP request to authenticate
    #
    # @return [Net::HTTPRequest] authenticated HTTP request
    def sign_request(request)
      fail ArgumentError, 'request is nil.' if request.nil?
    end
  end
end