MCPcopy
hub / github.com/kubernetes/node-problem-detector / GenerateKey

Function GenerateKey

test/e2e/lib/ssh/lib.go:507–513  ·  view source on GitHub ↗
(bits int)

Source from the content-addressed store, hash-verified

505}
506
507func GenerateKey(bits int) (*rsa.PrivateKey, *rsa.PublicKey, error) {
508 private, err := rsa.GenerateKey(rand.Reader, bits)
509 if err != nil {
510 return nil, nil, err
511 }
512 return private, &private.PublicKey, nil
513}

Callers 2

runTestSSHServerFunction · 0.85
TestSSHTunnelFunction · 0.85

Calls

no outgoing calls

Tested by 2

runTestSSHServerFunction · 0.68
TestSSHTunnelFunction · 0.68