SqlServer: support single sign on / Windows credential authentication
This is done through a new db-extra-arguments section in instance_dir/sources
which is passed as a string to the extra_args named argument of
lgc.db.get_connection. If this argument is Trusted_Connection, windows
authentication is used instead of login/password.
This change requires at least revision 5475ec3f6412 of logilab.common which
will be included in logilab-common 0.46. debian/control updated to mention this
new dependency.
""":organization: Logilab:copyright: 2001-2009 LOGILAB S.A. (Paris, FRANCE), license is LGPL v2.:contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr:license: GNU Lesser General Public License, v2.1 - http://www.gnu.org/licenses"""fromlogilab.common.adbhimportFunctionDescrfromrql.utilsimportregister_functiontry:classDUMB_SORT(FunctionDescr):supported_backends=('sqlite',)register_function(DUMB_SORT)definit_sqlite_connexion(cnx):defdumb_sort(something):returnsomethingcnx.create_function("DUMB_SORT",1,dumb_sort)fromcubicweb.serverimportsqlutilssqlutils.SQL_CONNECT_HOOKS['sqlite'].append(init_sqlite_connexion)except:# already registeredpass