code: func New(s *terraform.InstanceState) (*Communicator, error) {
  	connInfo, err := parseConnectionInfo(s)
  	if err != nil {
  		return nil, err
  	}
  
  	endpoint := &winrm.Endpoint{
  		Host:     connInfo.Host,
  		Port:     connInfo.Port,
  		HTTPS:    connInfo.HTTPS,
  		Insecure: connInfo.Insecure,
  	}
  	if len(connInfo.CACert) > 0 {
  		endpoint.CACert = []byte(connInfo.CACert)
  	}
  
  	comm := &Communicator{
  		connInfo: connInfo,
  		endpoint: endpoint,
  		// Seed our own rand source so that script paths are not deterministic
  		rand: rand.New(rand.NewSource(time.Now().UnixNano())),
  	}
  
  	return comm, nil
  }
docs: // New creates a new communicator implementation over WinRM.