From 3f65b85b3b578d6622c0b62aadf08e0c02ae43a6 Mon Sep 17 00:00:00 2001 From: grasevski Date: Tue, 28 Jan 2025 09:56:47 +1100 Subject: [PATCH] fix(credentials): check expiry properly Expiry flag was inverted when checking credentials. This causes ChainedCredentialsProvider to fail. --- include/miniocpp/credentials.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/miniocpp/credentials.h b/include/miniocpp/credentials.h index bcf0fb6..9c68e8d 100644 --- a/include/miniocpp/credentials.h +++ b/include/miniocpp/credentials.h @@ -69,7 +69,7 @@ struct Credentials { bool IsExpired() const { return expired(expiration); } explicit operator bool() const { - return !err && !access_key.empty() && expired(expiration); + return !err && !access_key.empty() && !expired(expiration); } static Credentials ParseXML(std::string_view data, const std::string& root);