Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for crc32 (0.2 sec)

  1. cmd/erasure-metadata-utils.go

    func hashOrder(key string, cardinality int) []int {
    	if cardinality <= 0 {
    		// Returns an empty int slice for cardinality < 0.
    		return nil
    	}
    
    	nums := make([]int, cardinality)
    	keyCrc := crc32.Checksum([]byte(key), crc32.IEEETable)
    
    	start := int(keyCrc % uint32(cardinality))
    	for i := 1; i <= cardinality; i++ {
    		nums[i-1] = 1 + ((start + i) % cardinality)
    	}
    	return nums
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Apr 23 17:15:52 GMT 2024
    - 11.3K bytes
    - Viewed (0)
  2. cmd/object-handlers_test.go

    			wantHeaders:        map[string]string{"x-amz-checksum-crc32c": checksumData(bytesData, crc32.New(crc32.MakeTable(crc32.Castagnoli)))},
    		},
    		// CRC32 as CRC32C
    		11: {
    			bucketName:         bucketName,
    			objectName:         objectName,
    			headers:            map[string]string{"x-amz-checksum-crc32c": checksumData(bytesData, crc32.New(crc32.IEEETable))},
    			data:               bytesData,
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 160K bytes
    - Viewed (0)
  3. cmd/erasure-sets.go

    	sum64 := siphash.Hash(k0, k1, []byte(key))
    	return int(sum64 % uint64(cardinality))
    }
    
    func crcHashMod(key string, cardinality int) int {
    	if cardinality <= 0 {
    		return -1
    	}
    	keyCrc := crc32.Checksum([]byte(key), crc32.IEEETable)
    	return int(keyCrc % uint32(cardinality))
    }
    
    func hashKey(algo string, key string, cardinality int, id [16]byte) int {
    	switch algo {
    	case formatErasureVersionV2DistributionAlgoV1:
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Fri May 03 20:08:20 GMT 2024
    - 37.7K bytes
    - Viewed (5)
  4. cmd/erasure-multipart.go

    		ETag:           partInfo.ETag,
    		LastModified:   partInfo.ModTime,
    		Size:           partInfo.Size,
    		ActualSize:     partInfo.ActualSize,
    		ChecksumCRC32:  partInfo.Checksums["CRC32"],
    		ChecksumCRC32C: partInfo.Checksums["CRC32C"],
    		ChecksumSHA1:   partInfo.Checksums["SHA1"],
    		ChecksumSHA256: partInfo.Checksums["SHA256"],
    	}, nil
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sun Apr 28 17:53:50 GMT 2024
    - 43K bytes
    - Viewed (0)
  5. cmd/object-handlers.go

    		switch {
    		case chkSums["CRC32"] != "":
    			OA.Checksum = new(objectAttributesChecksum)
    			OA.Checksum.ChecksumCRC32 = strings.Split(chkSums["CRC32"], "-")[0]
    		case chkSums["CRC32C"] != "":
    			OA.Checksum = new(objectAttributesChecksum)
    			OA.Checksum.ChecksumCRC32C = strings.Split(chkSums["CRC32C"], "-")[0]
    		case chkSums["SHA256"] != "":
    			OA.Checksum = new(objectAttributesChecksum)
    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)
  6. cmd/admin-handlers.go

    package cmd
    
    import (
    	"bytes"
    	"context"
    	crand "crypto/rand"
    	"crypto/rsa"
    	"crypto/subtle"
    	"crypto/x509"
    	"encoding/base64"
    	"encoding/json"
    	"encoding/pem"
    	"errors"
    	"fmt"
    	"hash/crc32"
    	"io"
    	"math"
    	"net/http"
    	"net/url"
    	"os"
    	"path"
    	"path/filepath"
    	"regexp"
    	"runtime"
    	"sort"
    	"strconv"
    	"strings"
    	"sync/atomic"
    	"time"
    
    	"github.com/dustin/go-humanize"
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Apr 29 17:39:04 GMT 2024
    - 97.8K bytes
    - Viewed (2)
Back to top