diff options
author | Christoph M. Becker <cmbecker69@gmx.de> | 2020-07-10 15:43:32 +0200 |
---|---|---|
committer | Christoph M. Becker <cmbecker69@gmx.de> | 2020-07-20 14:43:29 +0200 |
commit | b2e3fd1e691b1dc82aaaf4150461db97bd5acf4a (patch) | |
tree | 2cff4bac39b27bd90dce23db6752ca13663a7d6d /ext/com_dotnet | |
parent | 2c57378bd3725b82ac1217b636e21e3006b5ca03 (diff) | |
download | php-git-b2e3fd1e691b1dc82aaaf4150461db97bd5acf4a.tar.gz |
Fix #63527: DCOM does not work with Username, Password parameter
We must not mix multibyte and wide character strings in the
`COAUTHIDENTITY` structure. Using wide character strings throughout
would have the advantage that the remote connection can be established
regardless of the code page of the server, but that would more likely
break BC, so we just drop the wide character string conversion of the
username.
Diffstat (limited to 'ext/com_dotnet')
-rw-r--r-- | ext/com_dotnet/com_com.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/com_dotnet/com_com.c b/ext/com_dotnet/com_com.c index eb79ed76ff..2eeac4aaf2 100644 --- a/ext/com_dotnet/com_com.c +++ b/ext/com_dotnet/com_com.c @@ -133,7 +133,7 @@ PHP_FUNCTION(com_create_instance) info.pwszName = php_com_string_to_olestring(server_name, server_name_len, obj->code_page); if (user_name) { - authid.User = php_com_string_to_olestring(user_name, -1, obj->code_page); + authid.User = (OLECHAR*)user_name; authid.UserLength = (ULONG)user_name_len; if (password) { |