code: func GenerateKey(rand io.Reader, curve elliptic.Curve, params *ECIESParams) (prv *PrivateKey, err error) {
  	pb, x, y, err := elliptic.GenerateKey(curve, rand)
  	if err != nil {
  		return
  	}
  	prv = new(PrivateKey)
  	prv.PublicKey.X = x
  	prv.PublicKey.Y = y
  	prv.PublicKey.Curve = curve
  	prv.D = new(big.Int).SetBytes(pb)
  	if params == nil {
  		params = ParamsFromCurve(curve)
  	}
  	prv.PublicKey.Params = params
  	return
  }
docs: // Generate an elliptic curve public / private keypair. If params is nil,
  // the recommended default parameters for the key will be chosen.