- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 415 for publicKey (0.18 sec)
-
src/crypto/tls/tls.go
return fail(err) } switch pub := x509Cert.PublicKey.(type) { case *rsa.PublicKey: priv, ok := cert.PrivateKey.(*rsa.PrivateKey) if !ok { return fail(errors.New("tls: private key type does not match public key type")) } if pub.N.Cmp(priv.N) != 0 { return fail(errors.New("tls: private key does not match public key")) } case *ecdsa.PublicKey: priv, ok := cert.PrivateKey.(*ecdsa.PrivateKey)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Jun 07 17:57:01 UTC 2024 - 12.2K bytes - Viewed (0) -
pkg/serviceaccount/jwt.go
// accidentally obtain the real key from the key ID and use it for token // validation. func keyIDFromPublicKey(publicKey interface{}) (string, error) { publicKeyDERBytes, err := x509.MarshalPKIXPublicKey(publicKey) if err != nil { return "", fmt.Errorf("failed to serialize public key to DER format: %v", err) } hasher := crypto.SHA256.New()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Feb 27 22:16:08 UTC 2024 - 10.7K bytes - Viewed (0) -
internal/config/identity/openid/jwks_test.go
t.Fatalf("Expected 2 keys, got %d", len(jk.Keys)) } keys := make([]crypto.PublicKey, len(jk.Keys)) for ii, jks := range jk.Keys { var err error keys[ii], err = jks.DecodePublicKey() if err != nil { t.Fatalf("Failed to decode key %d: %v", ii, err) } } //nolint:gocritic if key0, ok := keys[0].(*ecdsa.PublicKey); !ok { t.Fatalf("Expected ECDSA key[0], got %T", keys[0])
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Sun Jan 02 17:15:06 UTC 2022 - 9.8K bytes - Viewed (0) -
src/crypto/dsa/dsa.go
// be shared across many keys. The bit length of Q must be a multiple of 8. type Parameters struct { P, Q, G *big.Int } // PublicKey represents a DSA public key. type PublicKey struct { Parameters Y *big.Int } // PrivateKey represents a DSA private key. type PrivateKey struct { PublicKey X *big.Int } // ErrInvalidPublicKey results when a public key is not usable by this code.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 17:09:47 UTC 2023 - 7.2K bytes - Viewed (0) -
src/encoding/pem/example_test.go
} pub, err := x509.ParsePKIXPublicKey(block.Bytes) if err != nil { log.Fatal(err) } fmt.Printf("Got a %T, with remaining data: %q", pub, rest) // Output: Got a *rsa.PublicKey, with remaining data: "and some more" } func ExampleEncode() { block := &pem.Block{ Type: "MESSAGE", Headers: map[string]string{ "Animal": "Gopher", }, Bytes: []byte("test"), }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Nov 15 03:08:55 UTC 2017 - 1.8K bytes - Viewed (0) -
src/crypto/ed25519/ed25519vectors_test.go
// compared bytewise against the canonical encoding. case "NonCanonicalR": expectedToVerify = false } } publicKey := decodeHex(t, v.A) signature := append(decodeHex(t, v.R), decodeHex(t, v.S)...) message := []byte(v.M) didVerify := ed25519.Verify(publicKey, message, signature) if didVerify && !expectedToVerify { t.Errorf("#%d: vector with flags %s unexpectedly verified", i, v.Flags) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Apr 25 14:52:51 UTC 2022 - 3.7K bytes - Viewed (0) -
docs/debugging/inspect/main.go
os.Exit(1) } // dump public key to file publicKeyBytes := x509.MarshalPKCS1PublicKey(&privatekey.PublicKey) if err != nil { fmt.Printf("error when dumping publickey: %s n", err) os.Exit(1) } publicKeyBlock := &pem.Block{ Type: "PUBLIC KEY", Bytes: publicKeyBytes, } publicPem, err := os.Create("support_public.pem") if err != nil { fmt.Printf("error when create public.pem: %s n", err)
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Fri May 31 14:49:23 UTC 2024 - 5.2K bytes - Viewed (0) -
src/crypto/tls/handshake_client.go
} } switch certs[0].PublicKey.(type) { case *rsa.PublicKey, *ecdsa.PublicKey, ed25519.PublicKey: break default: c.sendAlert(alertUnsupportedCertificate) return fmt.Errorf("tls: server's certificate contains an unsupported type of public key: %T", certs[0].PublicKey) } c.activeCertHandles = activeHandles c.peerCertificates = certs
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:10:12 UTC 2024 - 38.6K bytes - Viewed (0) -
platforms/software/security/src/main/java/org/gradle/security/internal/SecuritySupport.java
} } public static void assertInitialized() { } public static boolean verify(File file, PGPSignature signature, PGPPublicKey publicKey) throws PGPException { signature.init(createContentVerifier(), publicKey); byte[] buffer = new byte[BUFFER]; int len; try (InputStream in = new BufferedInputStream(new FileInputStream(file))) {
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Thu Mar 21 14:42:50 UTC 2024 - 6K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/internal/der/Certificate.kt
* limitations under the License. */ package okhttp3.tls.internal.der import java.math.BigInteger import java.security.GeneralSecurityException import java.security.PublicKey import java.security.Signature import java.security.SignatureException import java.security.cert.CertificateFactory import java.security.cert.X509Certificate import okio.Buffer import okio.ByteString
Registered: Sun Jun 16 04:42:17 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 6.4K bytes - Viewed (0)