Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 15 for IsValid (0.2 sec)

  1. cmd/erasure-metadata.go

    }
    
    // ShardSize - returns actual shared size from erasure blockSize.
    func (e ErasureInfo) ShardSize() int64 {
    	return ceilFrac(e.BlockSize, int64(e.DataBlocks))
    }
    
    // IsValid - tells if erasure info fields are valid.
    func (fi FileInfo) IsValid() bool {
    	if fi.Deleted {
    		// Delete marker has no data, no need to check
    		// for erasure coding information
    		return true
    	}
    	dataBlocks := fi.Erasure.DataBlocks
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 19.2K bytes
    - Viewed (1)
  2. cmd/storage-rest-server.go

    	if err := storageServerRequestValidate(r); err != nil {
    		s.writeErrorResponse(w, err)
    		return false
    	}
    
    	return true
    }
    
    // IsValid - To authenticate and check if the disk-id in the request corresponds to the underlying disk.
    func (s *storageRESTServer) IsValid(w http.ResponseWriter, r *http.Request) bool {
    	if !s.IsAuthValid(w, r) {
    		return false
    	}
    
    	if err := r.ParseForm(); err != nil {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 44.8K bytes
    - Viewed (0)
  3. cmd/erasure-object.go

    	freeVersionID := fi.TierFreeVersionID()
    	freeVersionMarker := fi.TierFreeVersion()
    
    	// Update `xl.meta` content on each disks.
    	for index := range metaArr {
    		if metaArr[index].IsValid() {
    			metaArr[index].ModTime = modTime
    			metaArr[index].VersionID = versionID
    			if !metaArr[index].InlineData() {
    				// If the data is not inlined, we may end up incorrectly
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun May 05 16:56:21 GMT 2024
    - 77.2K bytes
    - Viewed (2)
  4. cmd/bucket-targets.go

    }
    
    // SetTarget - sets a new minio-go client target for this bucket.
    func (sys *BucketTargetSys) SetTarget(ctx context.Context, bucket string, tgt *madmin.BucketTarget, update bool) error {
    	if !tgt.Type.IsValid() && !update {
    		return BucketRemoteArnTypeInvalid{Bucket: bucket}
    	}
    	clnt, err := sys.getRemoteTargetClient(tgt)
    	if err != nil {
    		return BucketRemoteTargetNotFound{Bucket: tgt.TargetBucket, Err: err}
    	}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 01:09:56 GMT 2024
    - 20.9K bytes
    - Viewed (0)
  5. cmd/iam.go

    	atomic.StoreUint64(&sys.LastRefreshTimeUnixNano, uint64(loadStartTime.Add(loadDuration).UnixNano()))
    	atomic.AddUint64(&sys.TotalRefreshSuccesses, 1)
    
    	if !globalSiteReplicatorCred.IsValid() {
    		sa, _, err := sys.getServiceAccount(ctx, siteReplicatorSvcAcc)
    		if err == nil {
    			globalSiteReplicatorCred.Set(sa.Credentials)
    		}
    	}
    
    	if firstTime {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 25 21:28:16 GMT 2024
    - 71.1K bytes
    - Viewed (1)
  6. cmd/object-handlers.go

    		return
    	}
    
    	// Validate storage class metadata if present
    	dstSc := r.Header.Get(xhttp.AmzStorageClass)
    	if dstSc != "" && !storageclass.IsValid(dstSc) {
    		writeErrorResponse(ctx, w, errorCodes.ToAPIErr(ErrInvalidStorageClass), r.URL)
    		return
    	}
    
    	// Check if bucket encryption is enabled
    	sseConfig, _ := globalBucketSSEConfigSys.Get(dstBucket)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu May 02 20:15:54 GMT 2024
    - 125.2K bytes
    - Viewed (0)
  7. cmd/iam-store.go

    	}
    
    	// When looking for a user's policies, we also check if the user
    	// and the groups they are member of are enabled.
    	u, ok := c.iamUsersMap[name]
    	if ok {
    		if !u.Credentials.IsValid() {
    			return nil, time.Time{}, nil
    		}
    	}
    
    	// For internal IDP regular/service account user accounts, the policy
    	// mapping is iamUserPolicyMap. For STS accounts, the parent user would be
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sat Apr 27 10:04:10 GMT 2024
    - 75.2K bytes
    - Viewed (2)
  8. cmd/site-replication.go

    }
    
    func (s *siteReplicatorCred) Set(c auth.Credentials) {
    	s.Lock()
    	defer s.Unlock()
    	s.Creds = c
    }
    
    func (s *siteReplicatorCred) IsValid() bool {
    	s.RLock()
    	defer s.RUnlock()
    	return s.Creds.IsValid()
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 01:09:56 GMT 2024
    - 184.2K bytes
    - Viewed (1)
  9. cmd/erasure-metadata_test.go

    		{7, 4},
    		// Insert part.
    		{3, 2},
    		// Replace existing part.
    		{4, 3},
    		// Missing part.
    		{6, -1},
    	}
    
    	// Setup.
    	fi := newFileInfo("test-object", 8, 8)
    	fi.Erasure.Index = 1
    	if !fi.IsValid() {
    		t.Fatalf("unable to get xl meta")
    	}
    
    	// Test them.
    	for _, testCase := range testCases {
    		if testCase.expectedIndex > -1 {
    			partNumString := strconv.Itoa(testCase.partNum)
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri Apr 26 00:31:12 GMT 2024
    - 9.1K bytes
    - Viewed (0)
  10. internal/auth/credentials.go

    func (cred Credentials) IsImpliedPolicy() bool {
    	if cred.IsServiceAccount() {
    		return cred.Claims[iamPolicyClaimNameSA] == "inherited-policy"
    	}
    	return false
    }
    
    // IsValid - returns whether credential is valid or not.
    func (cred Credentials) IsValid() bool {
    	// Verify credentials if its enabled or not set.
    	if cred.Status == AccountOff {
    		return false
    	}
    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)
Back to top