mirror of
https://github.com/minio/minio.git
synced 2025-11-09 13:39:46 -05:00
Reduce Minio access key minimum length to 3 (#5478)
This is a generic minimum value. The current reason is to support Azure blob storage accounts name whose length is less than 5. 3 is the minimum length for Azure.
This commit is contained in:
committed by
Nitish Tiwari
parent
2afd196c83
commit
da2faa19a1
@@ -39,8 +39,8 @@ func testAuthenticate(authType string, t *testing.T) {
|
||||
secretKey string
|
||||
expectedErr error
|
||||
}{
|
||||
// Access key (less than 5 chrs) too small.
|
||||
{"user", cred.SecretKey, auth.ErrInvalidAccessKeyLength},
|
||||
// Access key (less than 3 chrs) too small.
|
||||
{"u1", cred.SecretKey, auth.ErrInvalidAccessKeyLength},
|
||||
// Secret key (less than 8 chrs) too small.
|
||||
{cred.AccessKey, "pass", auth.ErrInvalidSecretKeyLength},
|
||||
// Authentication error.
|
||||
|
||||
@@ -53,7 +53,7 @@ FLAGS:
|
||||
{{end}}{{end}}
|
||||
ENVIRONMENT VARIABLES:
|
||||
ACCESS:
|
||||
MINIO_ACCESS_KEY: Custom username or access key of minimum 5 characters in length.
|
||||
MINIO_ACCESS_KEY: Custom username or access key of minimum 3 characters in length.
|
||||
MINIO_SECRET_KEY: Custom password or secret key of minimum 8 characters in length.
|
||||
|
||||
BROWSER:
|
||||
|
||||
@@ -116,10 +116,10 @@ func TestParseCredentialHeader(t *testing.T) {
|
||||
expectedErrCode: ErrCredMalformed,
|
||||
},
|
||||
// Test Case - 4.
|
||||
// Test case with AccessKey of length 4.
|
||||
// Test case with AccessKey of length 2.
|
||||
{
|
||||
inputCredentialStr: generateCredentialStr(
|
||||
"^#@.",
|
||||
"^#",
|
||||
UTCNow().Format(yyyymmdd),
|
||||
"ABCD",
|
||||
"ABCD",
|
||||
|
||||
Reference in New Issue
Block a user