7#include <aws/access-management/AccessManagement_EXPORTS.h>
9#include <aws/core/utils/memory/AWSMemory.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
16namespace CognitoIdentity
19class CognitoIdentityClient;
38namespace AccessManagement
58 AccessManagementClient(std::shared_ptr< Aws::IAM::IAMClient >& iamClient, std::shared_ptr< Aws::CognitoIdentity::CognitoIdentityClient >& cognitoClient);
139 bool RemoveUsersFromGroup(
const Aws::String& groupName);
140 bool DetachPoliciesFromGroup(
const Aws::String& groupName);
141 bool DeleteInlinePoliciesFromGroup(
const Aws::String& groupName);
143 bool DeleteAccessKeysForUser(
const Aws::String& userName);
144 bool RemoveUserFromGroups(
const Aws::String& userName);
145 bool RemoveCertificatesFromUser(
const Aws::String& userName);
146 bool RemovePasswordFromUser(
const Aws::String& userName);
147 bool DeleteInlinePoliciesFromUser(
const Aws::String& userName);
148 bool RemoveMFAFromUser(
const Aws::String& userName);
149 bool DetachPoliciesFromUser(
const Aws::String& userName);
151 bool RemovePolicyFromEntities(
const Aws::String& policyArn);
153 bool RemoveRoleFromInstanceProfiles(
const Aws::String& roleName);
154 bool DeleteInlinePoliciesFromRole(
const Aws::String& roleName);
155 bool DetachPoliciesFromRole(
const Aws::String& roleName);
157 std::shared_ptr< Aws::IAM::IAMClient > m_iamClient;
158 std::shared_ptr< Aws::CognitoIdentity::CognitoIdentityClient > m_cognitoClient;
QueryResult IsUserInGroup(const Aws::String &userName, const Aws::String &groupName)
bool AddUserToGroupIfNot(const Aws::String &userName, const Aws::String &groupName)
bool GetOrCreateGroup(const Aws::String &groupName, Aws::IAM::Model::Group &groupData)
bool GetOrCreatePolicy(const Aws::String &policyName, const PolicyGeneratorFunction &policyGenerator, Aws::IAM::Model::Policy &policyData)
bool BindRoleToIdentityPool(const Aws::String &identityPoolId, const Aws::String &roleArn, IdentityPoolRoleBindingType roleKey)
bool CreateIdentityPool(const Aws::String &poolName, bool allowUnauthenticated, Aws::String &identityPoolId)
AccessManagementClient(std::shared_ptr< Aws::IAM::IAMClient > &iamClient, std::shared_ptr< Aws::CognitoIdentity::CognitoIdentityClient > &cognitoClient)
Aws::String GetAccountId()
bool CreateCredentialsFileForUser(const Aws::String &credentialsFilename, const Aws::String &userName)
QueryResult GetUser(const Aws::String &userName, Aws::IAM::Model::User &userData)
static Aws::String ExtractAccountIdFromArn(const Aws::String &arn)
bool GetOrCreateRole(const Aws::String &roleName, const PolicyGeneratorFunction &assumedPolicyGenerator, Aws::IAM::Model::Role &roleData)
bool DetachPolicyFromGroup(const Aws::String &policyArn, const Aws::String &groupName)
bool CreatePolicy(const Aws::String &policyName, const Aws::String &policyDocument, Aws::IAM::Model::Policy &policyData)
bool GetOrCreateUser(const Aws::String &userName, Aws::IAM::Model::User &userData)
bool DeletePolicy(const Aws::String &policyName)
std::function< Aws::String(void) > PolicyGeneratorFunction
QueryResult IsPolicyAttachedToGroup(const Aws::String &policyName, const Aws::String &groupName)
bool DoesCredentialsFileExist(const Aws::String &credentialsFilename)
QueryResult GetIdentityPool(const Aws::String &poolName, Aws::String &identityPoolId)
QueryResult GetPolicy(const Aws::String &policyName, Aws::IAM::Model::Policy &policyData)
bool AttachPolicyToRole(const Aws::String &policyArn, const Aws::String &roleName)
bool DeleteRole(const Aws::String &roleName)
bool DeleteIdentityPool(const Aws::String &poolName)
bool AttachPolicyToGroup(const Aws::String &policyArn, const Aws::String &groupName)
bool CreateRole(const Aws::String &roleName, const Aws::String &assumedPolicyDocument, Aws::IAM::Model::Role &roleData)
bool CreateUser(const Aws::String &userName, Aws::IAM::Model::User &userData)
~AccessManagementClient()
QueryResult GetGroup(const Aws::String &groupName, Aws::IAM::Model::Group &groupData)
bool AddUserToGroup(const Aws::String &userName, const Aws::String &groupName)
bool DeleteGroup(const Aws::String &groupName)
bool AttachPolicyToGroupIfNot(const Aws::IAM::Model::Policy &policyData, const Aws::String &groupName)
bool DetachPolicyFromUser(const Aws::String &policyArn, const Aws::String &userName)
bool AttachPolicyToRoleIfNot(const Aws::IAM::Model::Policy &policyData, const Aws::String &roleName)
bool AttachPolicyToUserIfNot(const Aws::IAM::Model::Policy &policyData, const Aws::String &userName)
QueryResult GetRole(const Aws::String &roleName, Aws::IAM::Model::Role &roleData)
bool RemoveUserFromGroup(const Aws::String &userName, const Aws::String &groupName)
bool DeleteUser(const Aws::String &userName)
bool GetOrCreateIdentityPool(const Aws::String &poolName, bool allowUnauthenticated, Aws::String &identityPoolId)
bool BindRoleToIdentityPoolIfNot(const Aws::String &identityPoolId, const Aws::String &roleArn, IdentityPoolRoleBindingType roleKey)
QueryResult IsPolicyAttachedToUser(const Aws::String &policyName, const Aws::String &userName)
QueryResult IsPolicyAttachedToRole(const Aws::String &policyName, const Aws::String &roleName)
bool VerifyOrCreateCredentialsFileForUser(const Aws::String &credentialsFilename, const Aws::String &userName)
bool CreateGroup(const Aws::String &groupName, Aws::IAM::Model::Group &groupData)
bool AttachPolicyToUser(const Aws::String &policyArn, const Aws::String &userName)
bool DetachPolicyFromRole(const Aws::String &policyArn, const Aws::String &roleName)
QueryResult IsRoleBoundToIdentityPool(const Aws::String &identityPoolId, const Aws::String &roleArn, IdentityPoolRoleBindingType roleKey)
IdentityPoolRoleBindingType
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String