Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 73 for cipherText (0.16 sec)

  1. src/crypto/rsa/rsa.go

    	}
    
    	switch opts := opts.(type) {
    	case *OAEPOptions:
    		if opts.MGFHash == 0 {
    			return decryptOAEP(opts.Hash.New(), opts.Hash.New(), rand, priv, ciphertext, opts.Label)
    		} else {
    			return decryptOAEP(opts.Hash.New(), opts.MGFHash.New(), rand, priv, ciphertext, opts.Label)
    		}
    
    	case *PKCS1v15DecryptOptions:
    		if l := opts.SessionKeyLen; l > 0 {
    			plaintext = make([]byte, l)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 00:11:18 UTC 2024
    - 23.4K bytes
    - Viewed (0)
  2. src/crypto/rsa/pkcs1v15.go

    //
    // The random parameter is used as a source of entropy to ensure that
    // encrypting the same message twice doesn't result in the same
    // ciphertext. Most applications should use [crypto/rand.Reader]
    // as random. Note that the returned ciphertext does not depend
    // deterministically on the bytes read from random, and may change
    // between calls and/or between versions.
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 00:11:21 UTC 2024
    - 12.8K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/envelope/kmsv2/grpc_service.go

    	defer cancel()
    
    	request := &kmsapi.DecryptRequest{
    		Ciphertext:  req.Ciphertext,
    		Uid:         uid,
    		KeyId:       req.KeyID,
    		Annotations: req.Annotations,
    	}
    	response, err := g.kmsClient.Decrypt(ctx, request)
    	if err != nil {
    		return nil, err
    	}
    	return response.Plaintext, nil
    }
    
    // Encrypt bytes to a string ciphertext.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 14 23:18:16 UTC 2023
    - 4.6K bytes
    - Viewed (0)
  4. src/crypto/internal/boring/aes.go

    	n := len(dst)
    	for cap(dst) < n+len(ciphertext)-gcmTagSize {
    		dst = append(dst[:cap(dst)], 0)
    	}
    	dst = dst[:n+len(ciphertext)-gcmTagSize]
    
    	// Check delayed until now to make sure len(dst) is accurate.
    	if inexactOverlap(dst[n:], ciphertext) {
    		panic("cipher: invalid buffer overlap")
    	}
    
    	outLen := C.size_t(len(ciphertext) - gcmTagSize)
    	ok := C.EVP_AEAD_CTX_open_wrapper(
    		&g.ctx,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jan 26 22:52:27 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  5. src/vendor/golang.org/x/crypto/chacha20poly1305/chacha20poly1305_noasm.go

    	return c.sealGeneric(dst, nonce, plaintext, additionalData)
    }
    
    func (c *chacha20poly1305) open(dst, nonce, ciphertext, additionalData []byte) ([]byte, error) {
    	return c.openGeneric(dst, nonce, ciphertext, additionalData)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:33 UTC 2023
    - 534 bytes
    - Viewed (0)
  6. src/main/java/jcifs/smb1/util/DES.java

        }
    
    
        /// Encrypt a block of bytes.
        public void encrypt( byte[] clearText, byte[] cipherText )  {
            encrypt( clearText, 0, cipherText, 0 );
        }
    
        /// Decrypt a block of bytes.
        public void decrypt( byte[] cipherText, byte[] clearText ) {
    
            decrypt( cipherText, 0, clearText, 0 );
        }
    
        /**
         * encrypts an array where the length must be a multiple of 8
    Registered: Wed Jun 12 15:45:55 UTC 2024
    - Last Modified: Fri Mar 22 20:39:42 UTC 2019
    - 21.4K bytes
    - Viewed (0)
  7. internal/kms/kms.go

    		KeyID:      name,
    		Version:    resp.Version,
    		Plaintext:  resp.Plaintext,
    		Ciphertext: resp.Ciphertext,
    	}, nil
    }
    
    func (c *kmsConn) Decrypt(ctx context.Context, req *DecryptRequest) ([]byte, error) {
    	aad, err := req.AssociatedData.MarshalText()
    	if err != nil {
    		return nil, err
    	}
    
    	ciphertext, _ := parseCiphertext(req.Ciphertext)
    	resp, err := c.client.Decrypt(ctx, &kms.DecryptRequest{
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue May 07 23:55:37 UTC 2024
    - 11.4K bytes
    - Viewed (0)
  8. internal/config/crypto_test.go

    	if err != nil {
    		t.Fatalf("Failed to create KMS: %v", err)
    	}
    
    	for i, test := range encryptDecryptTests {
    		ciphertext, err := Encrypt(KMS, bytes.NewReader(test.Data), test.Context)
    		if err != nil {
    			t.Fatalf("Test %d: failed to encrypt stream: %v", i, err)
    		}
    		data, err := io.ReadAll(ciphertext)
    		if err != nil {
    			t.Fatalf("Test %d: failed to encrypt stream: %v", i, err)
    		}
    
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue May 07 23:55:37 UTC 2024
    - 3.2K bytes
    - Viewed (0)
  9. src/crypto/internal/hpke/hpke_test.go

    					}
    
    					expectedCiphertext := mustDecodeHex(t, enc["ct"])
    					ciphertext, err := context.Seal(mustDecodeHex(t, enc["aad"]), mustDecodeHex(t, enc["pt"]))
    					if err != nil {
    						t.Fatal(err)
    					}
    					if !bytes.Equal(ciphertext, expectedCiphertext) {
    						t.Errorf("unexpected ciphertext: got %x want %x", ciphertext, expectedCiphertext)
    					}
    				})
    			}
    		})
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 22:33:33 UTC 2024
    - 4.7K bytes
    - Viewed (0)
  10. staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/envelope/testing/v2/kms_plugin_mock.go

    func (s *Base64Plugin) Decrypt(ctx context.Context, request *kmsapi.DecryptRequest) (*kmsapi.DecryptResponse, error) {
    	klog.V(3).InfoS("Received Decrypt Request", "ciphertext", string(request.Ciphertext))
    
    	s.mu.Lock()
    	defer s.mu.Unlock()
    	if s.inFailedState {
    		return nil, status.Error(codes.FailedPrecondition, "failed precondition - key disabled")
    	}
    	if len(request.Uid) == 0 {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Jul 21 19:25:52 UTC 2023
    - 6.5K bytes
    - Viewed (0)
Back to top