static NTSTATUS winexe_svc_upload(
const char *hostname,
- int port,
+ const struct smb_transports *transports,
const char *service_filename,
const DATA_BLOB *svc32_exe,
const DATA_BLOB *svc64_exe,
uint16_t fnum = 0xffff;
NTSTATUS status;
const DATA_BLOB *binary = NULL;
- struct smb_transports ts = smbsock_transports_from_port(port);
status = cli_full_connection_creds(
talloc_tos(),
NULL,
hostname,
NULL,
- &ts,
+ transports,
"ADMIN$",
"?????",
credentials,
static NTSTATUS winexe_svc_install(
struct cli_state *cli,
const char *hostname,
- int port,
+ const struct smb_transports *transports,
const char *service_name,
const char *service_filename,
const DATA_BLOB *svc32_exe,
if (need_start) {
status = winexe_svc_upload(
hostname,
- port,
+ transports,
service_filename,
svc32_exe,
svc64_exe,
status = winexe_svc_install(
cli,
options.hostname,
- options.port,
+ &ts,
service_name,
service_filename,
winexesvc32_exe,