cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
yamahapacifi
Level 5

COM Security and flex initialization

It appears that one of the flex publisher methods initializes DCOM security by calling CoInitializeSecurity.

The method fails if I call it after a call to lc_flexinit:

# for hex 0x80010119 / decimal -2147417831 :
RPC_E_TOO_LATE winerror.h
# Security must be initialized before any interfaces are
# marshalled or unmarshalled. It cannot be changed once
# initialized.
# 1 matches found for "0x80010119"

The call succeeds if I remove flex initialization. This is going to be a big problem for us. Why is flex breaking COM rules and calling CoInitializeSecurity inside a library? Can this functionality be modified?

Thanks in advance,
Paul
Labels (1)
0 Kudos
(1) Reply
yamahapacifi
Level 5

It appears that lc_flexinit may be causing a DCOM marshalling event, which would cause the default security to be used anyway. If your app needs to explicitly set security it should do so before the call to flex init.
0 Kudos