Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions google-apis-core/lib/google/api_client/auth/storage.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ class Storage
#
# @param [Object] store
# Storage object
#
# @note Warning: This class is part of a deprecated credentials flow.
# Providing an unvalidated credential configuration to Google APIs can
# compromise the security of your systems and data. Use
# google-auth-library-ruby instead.
def initialize(store)
@store= store
@authorization = nil
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ def initialize(path)

##
# Attempt to read in credentials from the specified file.
#
# @note Warning: This method is part of a deprecated credentials flow.
# Providing an unvalidated credential configuration to Google APIs can
# compromise the security of your systems and data. Use
# google-auth-library-ruby instead.
def load_credentials
open(path, 'r') { |f| JSON.parse(f.read) }
rescue
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ def initialize(redis, key = nil)

##
# Attempt to read in credentials from redis.
#
# @note Warning: This method is part of a deprecated credentials flow.
# Providing an unvalidated credential configuration to Google APIs can
# compromise the security of your systems and data. Use
# google-auth-library-ruby instead.
#
# @return [Hash]
def load_credentials
credentials = redis.get redis_credentials_key
Expand Down