Microsoft ODBC bug
Dom Latter
freeradius-users at latter.org
Thu Jul 4 17:10:51 CEST 2019
On 03/07/2019 07:53, Alan DeKok wrote:
> On Jul 2, 2019, at 6:21 PM, Dom Latter <freeradius-users at latter.org> wrote:
>>> That's all well and good, but what should *we* be doing differently?
>>
>> Well, if I knew that...
>
> That is the problem.
>
> As background, the unfortunate thing is that the FreeRADIUS core team is pretty darn small (less than 5, by a lot.) And we're expected to be experts in:
>
> * RADIUS
<snip>
Yes, it's a lot of stuff.
Anyway, I have run ltrace to grab calls to the MS ODBC driver, from both
freeradius and a small python test script (which doesn't exhibit this
weird bug).
These are the calls (sorted alphabetically) that are used by Freeradius:
SQLAllocHandle
SQLBindCol
SQLDisconnect
SQLFetch
SQLFreeStmt
SQLNumResultCols
SQLSetEnvAttr
And these are the ones used by Python:
SQLAllocHandle
SQLDescribeColW
SQLDisconnect
SQLEndTran
SQLExecDirectW
SQLFetch
SQLFreeHandle
SQLFreeStmt
SQLGetData
SQLNumResultCols
SQLRowCount
SQLSetConnectAttr
What is noticeably absent from the freeradius output is SQLExecDirect
(the 'W' in the Python output just means it's Unicode); this despite
that I have put debug output immediately before and after the line
in the FR module that says:
err_handle = SQLExecDirect(conn->stmt, odbc_query, strlen(query));
so I know it is doing it... or trying to... or something.
More information about the Freeradius-Users
mailing list