http://bugs.winehq.org/show_bug.cgi?id=19144
Summary: QueryContextAttributesW returns wrong return value Product: Wine Version: 1.1.24 Platform: PC OS/Version: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: secur32 AssignedTo: wine-bugs@winehq.org ReportedBy: andras@csevego.net
If a .net application wants to connect to an mssql server, it will fail because of wine's secur32.dll (schan) return value. It should return 0 (SEC_E_OK), but it returns -2146893048. I got a successful connection with native secur32.
I have done some further investigation: If I manually return 1 at scannel.c:872 (return SEC_E_OK;), I got error 1 in error dialog. But if I pass 0, I got -2146893048.
MSSQL Management Studio's error in detail:
TITLE: Connect to Server ------------------------------
Cannot connect to <ip addr>.
------------------------------ ADDITIONAL INFORMATION:
A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: SSL Provider, error: 0 - SSL Provider: ) (Microsoft SQL Server, Error: -2146893048)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&EvtSrc=MSSQ...
------------------------------ BUTTONS:
OK ------------------------------
I tested with a private .net application, and MSSQL Management Studio 2005 Express. I have .net Framework 3.5 installed under wine. (with Louis Lenders' lsa and wbemprox patch)