- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 11 for ConstantTimeCompare (0.2 sec)
-
cmd/sftp-server.go
CriticalOptions: map[string]string{ ldapUser: targetUser, ldapUserN: c.User(), }, Extensions: make(map[string]string), }, nil } if subtle.ConstantTimeCompare([]byte(sa.Credentials.SecretKey), pass) == 1 { return &ssh.Permissions{ CriticalOptions: map[string]string{ "accessKey": c.User(), }, Extensions: make(map[string]string),
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Wed May 01 11:07:40 GMT 2024 - 10.4K bytes - Viewed (0) -
cmd/auth-handler.go
// based on admin credential such that token cannot be decoded // on the client side and is treated like an opaque value. claims, err := auth.ExtractClaims(token, secret) if err != nil { if subtle.ConstantTimeCompare([]byte(secret), []byte(globalActiveCred.SecretKey)) == 1 { return nil, errAuthentication } claims, err = auth.ExtractClaims(token, globalActiveCred.SecretKey) if err != nil {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Apr 04 12:04:40 GMT 2024 - 26K bytes - Viewed (0) -
cmd/signature-v2.go
if err != nil { return false } signature2, err := base64.StdEncoding.DecodeString(sig2) if err != nil { return false } return subtle.ConstantTimeCompare(signature1, signature2) == 1 } // Return canonical headers. func canonicalizedAmzHeadersV2(headers http.Header) string { var keys []string keyval := make(map[string]string, len(headers))
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Jan 18 07:03:17 GMT 2024 - 12.2K bytes - Viewed (0) -
cmd/encryption-v1.go
if subtle.ConstantTimeCompare(oldKey, newKey) == 1 { return errInvalidSSEParameters // AWS returns special error for equal but invalid keys. } return crypto.ErrInvalidCustomerKey // To provide strict AWS S3 compatibility we return: access denied. } if subtle.ConstantTimeCompare(oldKey, newKey) == 1 && sealedKey.Algorithm == crypto.SealAlgorithm {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Apr 04 12:04:40 GMT 2024 - 36.5K bytes - Viewed (0) -
cmd/signature-v4.go
func compareSignatureV4(sig1, sig2 string) bool { // The CTC using []byte(str) works because the hex encoding // is unique for a sequence of bytes. See also compareSignatureV2. return subtle.ConstantTimeCompare([]byte(sig1), []byte(sig2)) == 1 } // doesPolicySignatureMatch - Verify query headers with post policy // - http://docs.aws.amazon.com/AmazonS3/latest/API/sigv4-HTTPPOSTConstructPolicy.html //
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Apr 19 16:45:54 GMT 2024 - 12.3K bytes - Viewed (0) -
cmd/kms-handlers.go
return } writeSuccessResponseJSON(w, resp) return } // 3. Compare generated key with decrypted key if subtle.ConstantTimeCompare(key.Plaintext, decryptedKey) != 1 { response.DecryptionErr = "The generated and the decrypted data key do not match" resp, err := json.Marshal(response) if err != nil {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Mar 01 21:09:42 GMT 2024 - 20.7K bytes - Viewed (0) -
internal/auth/credentials.go
func (cred Credentials) Equal(ccred Credentials) bool { if !ccred.IsValid() { return false } return (cred.AccessKey == ccred.AccessKey && subtle.ConstantTimeCompare([]byte(cred.SecretKey), []byte(ccred.SecretKey)) == 1 && subtle.ConstantTimeCompare([]byte(cred.SessionToken), []byte(ccred.SessionToken)) == 1) } var timeSentinel = time.Unix(0, 0).UTC() // ErrInvalidDuration invalid token expiry
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Wed May 01 12:41:13 GMT 2024 - 11.7K bytes - Viewed (0) -
cmd/ftp-server-driver.go
return len(ldapPolicies) > 0, nil } return subtle.ConstantTimeCompare([]byte(sa.Credentials.SecretKey), []byte(password)) == 1, nil } ui, ok := globalIAMSys.GetUser(context.Background(), username) if !ok { return false, nil } return subtle.ConstantTimeCompare([]byte(ui.Credentials.SecretKey), []byte(password)) == 1, nil }
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Apr 19 12:23:42 GMT 2024 - 13.6K bytes - Viewed (0) -
internal/kms/kes.go
decryptedKey, err := client.Decrypt(ctx, env.Get(EnvKESKeyName, ""), key.Ciphertext, kmsCtx) switch { case err != nil: result.Decrypt = fmt.Sprintf("Decryption failed: %v", err) case subtle.ConstantTimeCompare(key.Plaintext, decryptedKey) != 1: result.Decrypt = "Decryption failed: decrypted key does not match generated key" default: result.Decrypt = "success" } results = append(results, result) }
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Tue Apr 16 15:43:39 GMT 2024 - 14.9K bytes - Viewed (0) -
cmd/object-lambda-handlers.go
tokenErr := errorCodes.ToAPIErr(ErrInvalidRequest) tokenErr.Description = "The request route included in the request is invalid" writeErrorResponse(ctx, w, tokenErr, r.URL) return } if subtle.ConstantTimeCompare([]byte(resp.Header.Get(xhttp.AmzRequestToken)), []byte(eventData.GetObjectContext.OutputToken)) != 1 { tokenErr := errorCodes.ToAPIErr(ErrInvalidToken)
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Sep 15 04:58:17 GMT 2023 - 10.2K bytes - Viewed (1)