https://bugs.winehq.org/show_bug.cgi?id=46671
--- Comment #2 from Harri Olin harri.olin@gmail.com --- Tested with wine 4.8, didn't work.
Did a bit of digging, looks like something is calling ntlm_InitializeSecurityContextW without username, domain and cached credentials so it fails before doing much.
Added username and domain if not present (after setting ntlm_cred): if (ntlm_cred->no_cached_credentials) { LPWKSTA_USER_INFO_1 ui = NULL; NetWkstaUserGetInfo(NULL, 1, (LPBYTE *)&ui); ntlm_cred->username_arg = ntlm_GetUsernameArg(ui->wkui1_username, -1); ntlm_cred->domain_arg = ntlm_GetDomainArg(ui->wkui1_logon_domain, -1); }
With this, ntlm_auth helper asks for PW after TT which wine does not understand, so I added dummy --password to command line arguments - static const char username_arg[] = "--username="; + static const char username_arg[] = "--password=Asd12345678 --username=";
With this now everything proceeds bit further, ntlm_auth gets to send AF and instead of "Unknown error" following error is logged: "A security requirement was not fulfilled during authentication. Required: None, negotiated: EncryptAndSign."