What does HRESULT 0x80010119 (RPC_E_TOO_LATE) mean?

 
Previous Next
RPC_E_UNSECURE_CALL RPC_E_NO_GOOD_SECURITY_PACKAGES

RPC_E_TOO_LATE

COM process security was initialized too late

RPC_E_TOO_LATE is HRESULT 2147549465 (0x80010119) from winerror.h. AllStat describes it as “Security must be initialized before any interfaces are marshalled or unmarshalled; It cannot be changed once initialized.” In the COM/RPC call control, message filtering, apartment routing, marshaling, security negotiation, or remote object lifetime, the code identifies a specific failure boundary and should not be replaced by a generic COM exception.

The hexadecimal value and symbolic name this result should remain attached to the originating API and operation generation.

Where it is encountered

  • Cross-apartment or cross-process COM method invocation and activation. Record the interface, method, component version, thread, apartment, process, and correlation ID.
  • STA message filtering, reentrancy, call cancellation, timeout, or retry handling.
  • DCOM security initialization, proxy/stub marshaling, OBJREF processing, and server object lifetime.

The immediate focus for this HRESULT is a call to <code>CoInitializeSecurity</code> after COM has already initialized security implicitly or marshaled an interface. Keep it attached to that operation; the same numeric severity outside the owning API does not supply enough context.

Decisive interpretation boundary

Before choosing recovery, verify that the first marshaling, activation, or implicit security event is earlier than the attempted explicit initialization. The decisive boundary for this HRESULT determines whether the same object can continue, a new object is required, or policy must change.

Also confirm that all observed objects, tokens, buffers, proxies, metadata files, or ACLs belong to the current operation generation and were not retained from an earlier attempt.

Correct handling and recovery

Move <code>CoInitializeSecurity</code> to process startup before interface marshaling. Remove competing framework initialization or configure security through supported registration.

Reconcile partial output and server-side effects before attempting the operation again.

Lifetime, retry, and cleanup rules

After it, determine whether the current object, interface pointer, call context, token, stream, metadata reader, asynchronous operation, or access-control instance remains valid. Release only resources owned by the failing attempt, cancel callbacks through their documented mechanism, and avoid double close, double commit, repeated activation, or replay of a non-idempotent remote method.

The retry policy for this HRESULT should state the trigger, maximum attempts, cancellation owner, and reconciliation step for effects that may have completed elsewhere.

Difference from nearby HRESULTs

It is initialization ordering; RPC_E_NO_GOOD_SECURITY_PACKAGES means timely initialization found no acceptable package.

A support tool discussing it should name the neighboring result only after the originating API and decisive state are known.

Practical scenario

A service loads a COM plug-in before calling <code>CoInitializeSecurity</code>. Startup is reordered so process security is configured before plug-in activation.

A regression test should reproduce it, assert the raw HRESULT and all relevant outputs, then correct only the decisive condition and verify the intended success or neighboring failure result.

References


Looking for a different code? Search another status or error code.