Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for sartrey (0.22 sec)

  1. internal/crypto/key.go

    // DerivePartKey derives an unique 256 bit key from an ObjectKey and the part index.
    func (key ObjectKey) DerivePartKey(id uint32) (partKey [32]byte) {
    	var bin [4]byte
    	binary.LittleEndian.PutUint32(bin[:], id)
    
    	mac := hmac.New(sha256.New, key[:])
    	mac.Write(bin[:])
    	mac.Sum(partKey[:0])
    	return partKey
    }
    
    // SealETag seals the etag using the object key.
    // It does not encrypt empty ETags because such ETags indicate
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Tue Mar 19 20:28:10 GMT 2024
    - 6.4K bytes
    - Viewed (0)
  2. cmd/metacache-set.go

    		return 0, nil
    	}
    	o.debugln("searching for ", search)
    	var tmp metacacheBlock
    	json := jsoniter.ConfigCompatibleWithStandardLibrary
    	i := 0
    	for {
    		partKey := fmt.Sprintf("%s-metacache-part-%d", ReservedMetadataPrefixLower, i)
    		v, ok := fi.Metadata[partKey]
    		if !ok {
    			o.debugln("no match in metadata, waiting")
    			return -1, io.ErrUnexpectedEOF
    		}
    		err := json.Unmarshal([]byte(v), &tmp)
    		if !ok {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Wed May 01 17:59:08 GMT 2024
    - 30.4K bytes
    - Viewed (0)
Back to top