Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 22 for generateCert (0.22 sec)

  1. pkg/test/cert/cert.go

    func GenerateCSR(confFile, keyFile, csrFile string) error {
    	return openssl("req", "-new",
    		"-config", confFile,
    		"-key", keyFile,
    		"-out", csrFile)
    }
    
    // GenerateCert and writes output to certFile.
    func GenerateCert(confFile, csrFile, keyFile, certFile string) error {
    	return openssl("x509", "-req",
    		"-days", "100000",
    		"-signkey", keyFile,
    		"-extensions", "req_ext",
    		"-extfile", confFile,
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Mar 22 14:18:21 UTC 2023
    - 1.8K bytes
    - Viewed (0)
  2. pkg/test/cert/ca/root.go

    		return Root{}, err
    	}
    
    	// Create the root CSR
    	if err := cert.GenerateCSR(root.ConfFile, root.KeyFile, root.CSRFile); err != nil {
    		return Root{}, err
    	}
    
    	// Create the root cert
    	if err := cert.GenerateCert(root.ConfFile, root.CSRFile, root.KeyFile, root.CertFile); err != nil {
    		return Root{}, err
    	}
    	return root, nil
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Aug 03 18:09:59 UTC 2021
    - 2.3K bytes
    - Viewed (0)
  3. src/crypto/x509/verify_test.go

    	parent, parentKey, err := generateCert("Root CA", true, nil, nil)
    	if err != nil {
    		t.Fatal(err)
    	}
    	roots.AddCert(parent)
    
    	for i := 1; i < 100; i++ {
    		parent, parentKey, err = generateCert("Intermediate CA", true, parent, parentKey)
    		if err != nil {
    			t.Fatal(err)
    		}
    		intermediates.AddCert(parent)
    	}
    
    	leaf, _, err := generateCert("Leaf", false, parent, parentKey)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 110.2K bytes
    - Viewed (0)
  4. security/pkg/pki/util/generate_cert.go

    // limitations under the License.
    
    // Provides utility methods to generate X.509 certificates with different
    // options. This implementation is Largely inspired from
    // https://golang.org/src/crypto/tls/generate_cert.go.
    
    package util
    
    import (
    	"crypto"
    	"crypto/ecdsa"
    	"crypto/ed25519"
    	"crypto/elliptic"
    	"crypto/rand"
    	"crypto/rsa"
    	"crypto/x509"
    	"crypto/x509/pkix"
    	"encoding/pem"
    	"errors"
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Aug 02 14:34:38 UTC 2023
    - 14.2K bytes
    - Viewed (0)
  5. src/crypto/tls/generate_cert.go

    cuiweixie <******@****.***> 1659534034 +0000
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 08 15:22:02 UTC 2022
    - 4.8K bytes
    - Viewed (0)
  6. security/pkg/pki/testdata/README.md

    # Generating ECC certificate for unit test
    
    In general, we prefer to generate certs by running `security/tools/generate_cert/main.go`
    
    ## ECC root certificate
    
    ```bash
    go run main.go -ec-sig-alg ECDSA -ca true
    ```
    
    ## ECC client certificate signed by root certificate
    
    ```bash
    go run main.go -ec-sig-alg ECDSA -san watt -signer-cert ../../pkg/pki/testdata/ec-root-cert.pem -signer-priv ../../pkg/pki/testdata/ec-root-key.pem -mode signer
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Sun Apr 25 06:24:06 UTC 2021
    - 442 bytes
    - Viewed (0)
  7. staging/src/k8s.io/apiserver/pkg/server/options/serving.go

    	// It becomes CertDirectory/PairName.crt and CertDirectory/PairName.key
    	PairName string
    
    	// GeneratedCert holds an in-memory generated certificate if CertFile/KeyFile aren't explicitly set, and CertDirectory/PairName are not set.
    	GeneratedCert dynamiccertificates.CertKeyContentProvider
    
    	// FixtureDirectory is a directory that contains test fixture used to avoid regeneration of certs during tests.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Apr 27 13:08:18 UTC 2024
    - 15.9K bytes
    - Viewed (0)
  8. src/net/http/internal/testcert/testcert.go

    package testcert
    
    import "strings"
    
    // LocalhostCert is a PEM-encoded TLS cert with SAN IPs
    // "127.0.0.1" and "[::1]", expiring at Jan 29 16:00:00 2084 GMT.
    // generated from src/crypto/tls:
    // go run generate_cert.go  --rsa-bits 2048 --host 127.0.0.1,::1,example.com --ca --start-date "Jan 1 00:00:00 1970" --duration=1000000h
    var LocalhostCert = []byte(`-----BEGIN CERTIFICATE-----
    MIIDOTCCAiGgAwIBAgIQSRJrEpBGFc7tNb1fb5pKFzANBgkqhkiG9w0BAQsFADAS
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat Jan 08 00:24:25 UTC 2022
    - 3.6K bytes
    - Viewed (0)
  9. staging/src/k8s.io/apiextensions-apiserver/test/integration/conversion/webhook.go

    			review.Response.Result = metav1.Status{Status: "Failure", Message: strings.Join(errMsgs, ", ")}
    		}
    		return review, nil
    	})
    }
    
    // localhostCert was generated from crypto/tls/generate_cert.go with the following command:
    //
    //	go run generate_cert.go  --rsa-bits 2048 --host 127.0.0.1,::1,example.com --ca --start-date "Jan 1 00:00:00 1970" --duration=1000000h
    var localhostCert = []byte(`-----BEGIN CERTIFICATE-----
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Dec 14 01:38:09 UTC 2022
    - 10.2K bytes
    - Viewed (0)
  10. staging/src/k8s.io/apimachinery/pkg/util/proxy/dial_test.go

    			if tc.ExpectError != "" {
    				t.Errorf("%s: expected error %q, got none", k, tc.ExpectError)
    			}
    		}()
    	}
    
    }
    
    // localhostCert was generated from crypto/tls/generate_cert.go with the following command:
    //
    //	go run generate_cert.go  --rsa-bits 2048 --host 127.0.0.1,::1,example.com --ca --start-date "Jan 1 00:00:00 1970" --duration=1000000h
    var localhostCert = []byte(`-----BEGIN CERTIFICATE-----
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Oct 23 22:33:38 UTC 2023
    - 8.4K bytes
    - Viewed (0)
Back to top