pythoncom.CoInitializeSecurity
CoInitializeSecurity(sd, authInfo, reserved1, authnLevel, impLevel, authInfo, capabilities, reserved2)
Registers security and sets the default security values.
Parameters
sd : PySECURITY_DESCRIPTOR
Security descriptor containing access permissions for process' objects, can be NoneauthInfo : object
A value of None tells COM to choose which authentication services to use. An empty list means use no services.reserved1 : object
Must be NoneauthnLevel : int
One of pythoncom.RPC_C_AUTHN_LEVEL_* values. The default authentication level for proxies. On the server side, COM will fail calls that arrive at a lower level. All calls to AddRef and Release are made at this level.impLevel : int
One of pythoncom.RPC_C_IMP_LEVEL_* values. The default impersonation level for proxies. This value is not checked on the server side. AddRef and Release calls are made with this impersonation level so even security aware apps should set this carefully. Setting IUnknown security only affects calls to QueryInterface, not AddRef or Release.authInfo : object
Must be Nonecapabilities : int
Additional client and/or server-side capabilities. Any set of pythoncom.EOAC_* flags may be passed. Currently only EOAC_MUTUAL_AUTH, EOAC_SECURE_REFS, and EOAC_NONE are definedreserved2 : object
Must be None