mirror of
https://github.com/minio/minio.git
synced 2025-01-24 13:13:16 -05:00
avoid unnecessary logging in IAM (#9502)
This commit is contained in:
parent
71ce63f79c
commit
09571d03a5
@ -1361,7 +1361,6 @@ var iamAccountOtherAccessActions = iampolicy.NewActionSet(
|
|||||||
func (sys *IAMSys) GetAccountAccess(accountName, bucket string) (rd, wr, o bool) {
|
func (sys *IAMSys) GetAccountAccess(accountName, bucket string) (rd, wr, o bool) {
|
||||||
policies, err := sys.PolicyDBGet(accountName, false)
|
policies, err := sys.PolicyDBGet(accountName, false)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.LogIf(context.Background(), err)
|
|
||||||
return false, false, false
|
return false, false, false
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1508,7 +1507,6 @@ func (sys *IAMSys) IsAllowedServiceAccount(args iampolicy.Args, parent string) b
|
|||||||
// Check if the parent is allowed to perform this action, reject if not
|
// Check if the parent is allowed to perform this action, reject if not
|
||||||
parentUserPolicies, err := sys.PolicyDBGet(parent, false)
|
parentUserPolicies, err := sys.PolicyDBGet(parent, false)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.LogIf(context.Background(), err)
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1729,7 +1727,6 @@ func (sys *IAMSys) IsAllowed(args iampolicy.Args) bool {
|
|||||||
// If the credential is temporary, perform STS related checks.
|
// If the credential is temporary, perform STS related checks.
|
||||||
ok, err := sys.IsTempUser(args.AccountName)
|
ok, err := sys.IsTempUser(args.AccountName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.LogIf(context.Background(), err)
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if ok {
|
if ok {
|
||||||
@ -1739,7 +1736,6 @@ func (sys *IAMSys) IsAllowed(args iampolicy.Args) bool {
|
|||||||
// If the credential is for a service account, perform related check
|
// If the credential is for a service account, perform related check
|
||||||
ok, parentUser, err := sys.IsServiceAccount(args.AccountName)
|
ok, parentUser, err := sys.IsServiceAccount(args.AccountName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.LogIf(context.Background(), err)
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if ok {
|
if ok {
|
||||||
@ -1749,7 +1745,6 @@ func (sys *IAMSys) IsAllowed(args iampolicy.Args) bool {
|
|||||||
// Continue with the assumption of a regular user
|
// Continue with the assumption of a regular user
|
||||||
policies, err := sys.PolicyDBGet(args.AccountName, false)
|
policies, err := sys.PolicyDBGet(args.AccountName, false)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logger.LogIf(context.Background(), err)
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user