Search Options

Results per page
Sort
Preferred Languages
Advance

Results 111 - 120 of 208 for newHeader (0.1 sec)

  1. docs/debugging/inspect/decrypt-v2.go

    func extractInspectV2(pk []byte, r io.Reader, w io.Writer, okMsg string) error {
    	privKey, err := bytesToPrivateKey(pk)
    	if err != nil {
    		return fmt.Errorf("decoding key returned: %w", err)
    	}
    
    	sr, err := estream.NewReader(r)
    	if err != nil {
    		return err
    	}
    
    	sr.SetPrivateKey(privKey)
    	sr.ReturnNonDecryptable(true)
    
    	// Debug corrupted streams.
    	if false {
    		sr.SkipEncrypted(true)
    		return sr.DebugStream(os.Stdout)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Apr 11 21:22:47 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  2. internal/etag/etag_test.go

    	},
    }
    
    func TestReader(t *testing.T) {
    	for i, test := range readerTests {
    		reader := NewReader(context.Background(), strings.NewReader(test.Content), test.ETag, nil)
    		if _, err := io.Copy(io.Discard, reader); err != nil {
    			t.Fatalf("Test %d: read failed: %v", i, err)
    		}
    		if ETag := reader.ETag(); !Equal(ETag, test.ETag) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 18 17:00:54 UTC 2023
    - 12.6K bytes
    - Viewed (0)
  3. cmd/object-handlers_test.go

    				int64(testCase.dataLen), testCase.chunkSize, bytes.NewReader(testCase.data),
    				testCase.accessKey, testCase.secretKey)
    		case testCase.contentEncoding == "":
    			req, err = newTestStreamingSignedRequest(http.MethodPut,
    				getPutObjectURL("", testCase.bucketName, testCase.objectName),
    				int64(testCase.dataLen), testCase.chunkSize, bytes.NewReader(testCase.data),
    				testCase.accessKey, testCase.secretKey)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 12 20:10:44 UTC 2024
    - 163.2K bytes
    - Viewed (0)
  4. cmd/warm-backend.go

    // to perform all operations defined in the WarmBackend interface.
    func checkWarmBackend(ctx context.Context, w WarmBackend) error {
    	remoteVersionID, err := w.Put(ctx, probeObject, strings.NewReader("MinIO"), 5)
    	if err != nil {
    		if _, ok := err.(BackendDown); ok {
    			return err
    		}
    		return tierPermErr{
    			Op:  tierPut,
    			Err: err,
    		}
    	}
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Oct 31 22:10:24 UTC 2024
    - 4K bytes
    - Viewed (0)
  5. internal/dsync/dsync-client_test.go

    func (restClient *ReconnectRESTClient) Call(method string, args LockArgs) (status bool, err error) {
    	buf, err := args.MarshalMsg(nil)
    	if err != nil {
    		return false, err
    	}
    	body := bytes.NewReader(buf)
    	respBody, err := restClient.rest.Call(context.Background(), method,
    		url.Values{}, body, body.Size())
    	defer xhttp.DrainBody(respBody)
    
    	switch toLockError(err) {
    	case nil:
    		return true, nil
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Jan 20 17:36:09 UTC 2022
    - 4.4K bytes
    - Viewed (0)
  6. cmd/auth-handler_test.go

    		// Short Content-Md5 header.
    		{mustNewSignedShortMD5Request(http.MethodPut, "http://127.0.0.1:9000/", 5, bytes.NewReader([]byte("hello")), t), ErrInvalidDigest},
    		// When request is properly signed, but has bad Content-MD5 header.
    		{mustNewSignedBadMD5Request(http.MethodPut, "http://127.0.0.1:9000/", 5, bytes.NewReader([]byte("hello")), t), ErrBadDigest},
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Fri May 24 23:05:23 UTC 2024
    - 15.4K bytes
    - Viewed (0)
  7. cmd/tier.go

    	b, err := config.Bytes()
    	if err != nil {
    		return nil, nil, err
    	}
    
    	payloadSize := int64(len(b))
    	br := bytes.NewReader(b)
    	hr, err := hash.NewReader(ctx, br, payloadSize, "", "", payloadSize)
    	if err != nil {
    		return nil, nil, err
    	}
    	if GlobalKMS == nil {
    		return NewPutObjReader(hr), &ObjectOptions{MaxParity: true}, nil
    	}
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Sep 12 20:44:05 UTC 2024
    - 15.7K bytes
    - Viewed (0)
  8. internal/s3select/json/preader.go

    				r.bufferPool.Put(in.input)
    				in.input = nil
    				in.err = d.Err()
    				in.dst <- all
    			}
    		}()
    	}
    }
    
    // NewPReader - creates new parallel JSON reader using readCloser.
    // Should only be used for LINES types.
    func NewPReader(readCloser io.ReadCloser, args *ReaderArgs) *PReader {
    	r := &PReader{
    		args:       args,
    		buf:        bufio.NewReaderSize(readCloser, jsonSplitSize*2),
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 23 19:35:41 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  9. internal/deadlineconn/deadlineconn_test.go

    		t.Fatalf("failed to write to server. %v", err)
    	}
    	_, err = io.WriteString(c, "message two\n")
    	if err != nil {
    		t.Fatalf("failed to write to server. %v", err)
    	}
    
    	received, err := bufio.NewReader(c).ReadString('\n')
    	if err != nil {
    		t.Fatalf("failed to read from server. %v", err)
    	}
    	if received != "messages received\n" {
    		t.Fatalf(`client: expected: "messages received\n", got: %v`, received)
    	}
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sat Nov 05 18:09:21 UTC 2022
    - 3K bytes
    - Viewed (0)
  10. internal/bucket/versioning/versioning_test.go

    			excludeFolders:   true,
    		},
    	}
    
    	for i, tc := range testcases {
    		var v *Versioning
    		var err error
    		v, err = ParseConfig(strings.NewReader(tc.input))
    		if tc.err != err {
    			t.Fatalf("Test %d: expected %v but got %v", i+1, tc.err, err)
    		}
    		if err != nil {
    			if tc.err == nil {
    				t.Fatalf("Test %d: failed due to %v", i+1, err)
    			}
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun May 08 05:06:44 UTC 2022
    - 8.8K bytes
    - Viewed (0)
Back to top