class Amazonite::Core::Credentials

Overview

A resolved set of AWS credentials - #session_token/#expiration are only present for temporary credentials (from a CredentialsProvider in the dynamic chain); a static access key/secret has neither.

Defined in:

core/credentials.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(access_key_id : String, secret_access_key : String, session_token : String | Nil = nil, expiration : Time | Nil = nil) #

[View source]

Instance Method Detail

def access_key_id : String #

[View source]
def expiration : Time | Nil #

[View source]
def expired?(now : Time = Time.utc, buffer : Time::Span = 1.minute) : Bool #

static credentials (no expiration) never expire; temporary credentials are treated as stale slightly before their real expiry so a refresh can happen before an in-flight request gets signed with a dead token


[View source]
def secret_access_key : String #

[View source]
def session_token : String | Nil #

[View source]