// // Automatically generated by ipdlc. // Edit at your own risk // #include "mozilla/net/PSocketProcessChild.h" #include "mozilla/AntiTrackingIPCUtils.h" #include "mozilla/ProfilerLabels.h" #include "mozilla/TimeStamp.h" #include "mozilla/dom/ConsoleReportIPCUtils.h" #include "mozilla/dom/DomSecurityIPCUtils.h" #include "mozilla/dom/FetchIPCTypes.h" #include "mozilla/dom/NavigationAPIIPCUtils.h" #include "mozilla/dom/PermissionsPolicyUtils.h" #include "mozilla/dom/PropertyBagUtils.h" #include "mozilla/dom/ReferrerInfoUtils.h" #include "mozilla/dom/RemoteType.h" #include "mozilla/dom/SessionHistoryEntry.h" #include "mozilla/ipc/ByteBufUtils.h" #include "mozilla/ipc/IPCCore.h" #include "mozilla/ipc/URIUtils.h" #include "mozilla/net/CacheInfoIPCTypes.h" #include "mozilla/net/ClassOfService.h" #include "mozilla/net/SocketProcessChild.h" #include "nsDOMNavigationTiming.h" #include "nsDocShellLoadState.h" #include "nsHttp.h" #include "nsHttpResponseHead.h" #include "nsID.h" #include "nsIPropertyBag2.h" #include "mozilla/net/PDNSRequestChild.h" #include "mozilla/net/PSocketProcessBridgeChild.h" #include "mozilla/PProfilerChild.h" #include "mozilla/net/PWebrtcTCPSocketChild.h" #include "mozilla/net/PHttpTransactionChild.h" #include "mozilla/net/PHttpConnectionMgrChild.h" #include "mozilla/net/PInputChannelThrottleQueueChild.h" #include "mozilla/net/PAltServiceChild.h" #include "mozilla/net/PAltSvcTransactionChild.h" #include "mozilla/net/PTRRServiceChild.h" #include "mozilla/net/PProxyConfigLookupChild.h" #include "mozilla/net/PNativeDNSResolverOverrideChild.h" #include "mozilla/net/PProxyAutoConfigChild.h" #include "mozilla/net/PSocketProcessBackgroundChild.h" #include "ipc/IPCMessageUtils.h" #include "ipc/IPCMessageUtilsSpecializations.h" #include "nsIFile.h" #include "mozilla/ipc/Endpoint.h" #include "mozilla/ipc/ProtocolMessageUtils.h" #include "mozilla/ipc/ProtocolUtils.h" #include "mozilla/ipc/ShmemMessageUtils.h" #include "mozilla/ipc/TaintingIPCUtils.h" namespace mozilla { namespace net { auto PSocketProcessChild::RecvPHttpTransactionConstructor(PHttpTransactionChild* actor) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPHttpConnectionMgrConstructor( PHttpConnectionMgrChild* actor, const HttpHandlerInitArgs& aArgs) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPInputChannelThrottleQueueConstructor( PInputChannelThrottleQueueChild* actor, const uint32_t& meanBytesPerSecond, const uint32_t& maxBytesPerSecond) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPAltSvcTransactionConstructor( PAltSvcTransactionChild* actor, const HttpConnectionInfoCloneArgs& aConnInfo, const uint32_t& aCaps) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPTRRServiceConstructor( PTRRServiceChild* actor, const bool& aCaptiveIsPassed, const bool& aParentalControlEnabled, nsTArray&& aDNSSuffixList) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPNativeDNSResolverOverrideConstructor(PNativeDNSResolverOverrideChild* actor) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::RecvPDNSRequestConstructor( PDNSRequestChild* actor, const nsACString& hostName, const nsACString& trrServer, const int32_t& port, const uint16_t& type, const OriginAttributes& originAttributes, const DNSFlags& flags) -> mozilla::ipc::IPCResult { return IPC_OK(); } auto PSocketProcessChild::ProcessingError( Result aCode, const char* aReason) -> void { } auto PSocketProcessChild::ShouldContinueFromReplyTimeout() -> bool { return true; } MOZ_IMPLICIT PSocketProcessChild::PSocketProcessChild() : mozilla::ipc::IToplevelProtocol("PSocketProcessChild", kProtocolId, mozilla::ipc::ChildSide) { MOZ_COUNT_CTOR(PSocketProcessChild); } PSocketProcessChild::~PSocketProcessChild() { MOZ_COUNT_DTOR(PSocketProcessChild); } auto PSocketProcessChild::ActorAlloc() -> void { MOZ_RELEASE_ASSERT(XRE_IsSocketProcess(), "Invalid process for `PSocketProcessChild'"); AddRef(); } auto PSocketProcessChild::ActorDealloc() -> void { Release(); } auto PSocketProcessChild::OtherPid() const -> ::base::ProcessId { ::base::ProcessId pid = ::mozilla::ipc::IProtocol::ToplevelProtocol()->OtherPidMaybeInvalid(); MOZ_RELEASE_ASSERT(pid != ::base::kInvalidProcessId); return pid; } auto PSocketProcessChild::OtherChildID() const -> ::GeckoChildID { ::GeckoChildID childID = ::mozilla::ipc::IProtocol::ToplevelProtocol()->OtherChildIDMaybeInvalid(); MOZ_RELEASE_ASSERT(childID != -1); return childID; } auto PSocketProcessChild::OtherEndpointProcInfo() const -> ::mozilla::ipc::EndpointProcInfo { return ::mozilla::ipc::EndpointProcInfo{OtherPid(), OtherChildID()}; } auto PSocketProcessChild::ManagedPDNSRequestChild(nsTArray& aArr) const -> void { mManagedPDNSRequestChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPDNSRequestChild() const -> const ManagedContainer& { return mManagedPDNSRequestChild; } auto PSocketProcessChild::ManagedPWebrtcTCPSocketChild(nsTArray& aArr) const -> void { mManagedPWebrtcTCPSocketChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPWebrtcTCPSocketChild() const -> const ManagedContainer& { return mManagedPWebrtcTCPSocketChild; } auto PSocketProcessChild::ManagedPHttpTransactionChild(nsTArray& aArr) const -> void { mManagedPHttpTransactionChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPHttpTransactionChild() const -> const ManagedContainer& { return mManagedPHttpTransactionChild; } auto PSocketProcessChild::ManagedPHttpConnectionMgrChild(nsTArray& aArr) const -> void { mManagedPHttpConnectionMgrChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPHttpConnectionMgrChild() const -> const ManagedContainer& { return mManagedPHttpConnectionMgrChild; } auto PSocketProcessChild::ManagedPInputChannelThrottleQueueChild(nsTArray& aArr) const -> void { mManagedPInputChannelThrottleQueueChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPInputChannelThrottleQueueChild() const -> const ManagedContainer& { return mManagedPInputChannelThrottleQueueChild; } auto PSocketProcessChild::ManagedPAltServiceChild(nsTArray& aArr) const -> void { mManagedPAltServiceChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPAltServiceChild() const -> const ManagedContainer& { return mManagedPAltServiceChild; } auto PSocketProcessChild::ManagedPAltSvcTransactionChild(nsTArray& aArr) const -> void { mManagedPAltSvcTransactionChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPAltSvcTransactionChild() const -> const ManagedContainer& { return mManagedPAltSvcTransactionChild; } auto PSocketProcessChild::ManagedPTRRServiceChild(nsTArray& aArr) const -> void { mManagedPTRRServiceChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPTRRServiceChild() const -> const ManagedContainer& { return mManagedPTRRServiceChild; } auto PSocketProcessChild::ManagedPProxyConfigLookupChild(nsTArray& aArr) const -> void { mManagedPProxyConfigLookupChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPProxyConfigLookupChild() const -> const ManagedContainer& { return mManagedPProxyConfigLookupChild; } auto PSocketProcessChild::ManagedPNativeDNSResolverOverrideChild(nsTArray& aArr) const -> void { mManagedPNativeDNSResolverOverrideChild.ToArray(aArr); } auto PSocketProcessChild::ManagedPNativeDNSResolverOverrideChild() const -> const ManagedContainer& { return mManagedPNativeDNSResolverOverrideChild; } auto PSocketProcessChild::ManagedProtocolIds() const -> mozilla::Span { static constexpr ::mozilla::ipc::ProtocolId sIds[] = { PDNSRequestMsgStart, PWebrtcTCPSocketMsgStart, PHttpTransactionMsgStart, PHttpConnectionMgrMsgStart, PInputChannelThrottleQueueMsgStart, PAltServiceMsgStart, PAltSvcTransactionMsgStart, PTRRServiceMsgStart, PProxyConfigLookupMsgStart, PNativeDNSResolverOverrideMsgStart }; return sIds; } auto PSocketProcessChild::GetManagedActors(mozilla::ipc::ProtocolId aProtocol) -> UntypedManagedContainer* { switch (aProtocol) { case PDNSRequestMsgStart: return (&(mManagedPDNSRequestChild)); case PWebrtcTCPSocketMsgStart: return (&(mManagedPWebrtcTCPSocketChild)); case PHttpTransactionMsgStart: return (&(mManagedPHttpTransactionChild)); case PHttpConnectionMgrMsgStart: return (&(mManagedPHttpConnectionMgrChild)); case PInputChannelThrottleQueueMsgStart: return (&(mManagedPInputChannelThrottleQueueChild)); case PAltServiceMsgStart: return (&(mManagedPAltServiceChild)); case PAltSvcTransactionMsgStart: return (&(mManagedPAltSvcTransactionChild)); case PTRRServiceMsgStart: return (&(mManagedPTRRServiceChild)); case PProxyConfigLookupMsgStart: return (&(mManagedPProxyConfigLookupChild)); case PNativeDNSResolverOverrideMsgStart: return (&(mManagedPNativeDNSResolverOverrideChild)); default: return nullptr; } } auto PSocketProcessChild::RejectPendingResponses(ResponseRejectReason aReason) -> void { mAsyncCallbacks.RejectPendingResponses(aReason); } auto PSocketProcessChild::OpenPDNSRequestEndpoint(PDNSRequestChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PDNSRequestChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PDNSRequestChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPDNSRequestEndpoint( ManagedEndpoint aEndpoint, PDNSRequestChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPWebrtcTCPSocketEndpoint(PWebrtcTCPSocketChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PWebrtcTCPSocketChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PWebrtcTCPSocketChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPWebrtcTCPSocketEndpoint( ManagedEndpoint aEndpoint, PWebrtcTCPSocketChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPHttpTransactionEndpoint(PHttpTransactionChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PHttpTransactionChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PHttpTransactionChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPHttpTransactionEndpoint( ManagedEndpoint aEndpoint, PHttpTransactionChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPHttpConnectionMgrEndpoint(PHttpConnectionMgrChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PHttpConnectionMgrChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PHttpConnectionMgrChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPHttpConnectionMgrEndpoint( ManagedEndpoint aEndpoint, PHttpConnectionMgrChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPInputChannelThrottleQueueEndpoint(PInputChannelThrottleQueueChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PInputChannelThrottleQueueChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PInputChannelThrottleQueueChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPInputChannelThrottleQueueEndpoint( ManagedEndpoint aEndpoint, PInputChannelThrottleQueueChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPAltServiceEndpoint(PAltServiceChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PAltServiceChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PAltServiceChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPAltServiceEndpoint( ManagedEndpoint aEndpoint, PAltServiceChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPAltSvcTransactionEndpoint(PAltSvcTransactionChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PAltSvcTransactionChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PAltSvcTransactionChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPAltSvcTransactionEndpoint( ManagedEndpoint aEndpoint, PAltSvcTransactionChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPTRRServiceEndpoint(PTRRServiceChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PTRRServiceChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PTRRServiceChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPTRRServiceEndpoint( ManagedEndpoint aEndpoint, PTRRServiceChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPProxyConfigLookupEndpoint(PProxyConfigLookupChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PProxyConfigLookupChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PProxyConfigLookupChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPProxyConfigLookupEndpoint( ManagedEndpoint aEndpoint, PProxyConfigLookupChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::OpenPNativeDNSResolverOverrideEndpoint(PNativeDNSResolverOverrideChild* aActor) -> ManagedEndpoint { if (!aActor) { NS_WARNING("Cannot bind null PNativeDNSResolverOverrideChild actor"); return ManagedEndpoint(); } if (!aActor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PNativeDNSResolverOverrideChild actor"); return ManagedEndpoint(); } // Mark our actor as awaiting the other side to be bound. This will // be cleared when a `MANAGED_ENDPOINT_{DROPPED,BOUND}` message is // received. aActor->mAwaitingManagedEndpointBind = true; return ManagedEndpoint(mozilla::ipc::PrivateIPDLInterface(), aActor); } auto PSocketProcessChild::BindPNativeDNSResolverOverrideEndpoint( ManagedEndpoint aEndpoint, PNativeDNSResolverOverrideChild* aActor) -> bool { return aEndpoint.Bind(mozilla::ipc::PrivateIPDLInterface(), aActor, this); } auto PSocketProcessChild::SendInitCrashReporter(CrashReporterInitArgs&& aInitArgs) -> bool { UniquePtr msg__ = PSocketProcess::Msg_InitCrashReporter(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), std::move(aInitArgs)); // Sentinel = 'aInitArgs' ((&(writer__)))->WriteSentinel(286327683); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitCrashReporter", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendAddMemoryReport(const MemoryReport& aReport) -> bool { UniquePtr msg__ = PSocketProcess::Msg_AddMemoryReport(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), aReport); // Sentinel = 'aReport' ((&(writer__)))->WriteSentinel(184025822); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_AddMemoryReport", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendAccumulateChildHistograms(mozilla::Span accumulations) -> bool { UniquePtr msg__ = PSocketProcess::Msg_AccumulateChildHistograms(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), accumulations); // Sentinel = 'accumulations' ((&(writer__)))->WriteSentinel(632030585); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_AccumulateChildHistograms", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendAccumulateChildKeyedHistograms(mozilla::Span accumulations) -> bool { UniquePtr msg__ = PSocketProcess::Msg_AccumulateChildKeyedHistograms(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), accumulations); // Sentinel = 'accumulations' ((&(writer__)))->WriteSentinel(632030585); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_AccumulateChildKeyedHistograms", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendUpdateChildScalars(mozilla::Span actions) -> bool { UniquePtr msg__ = PSocketProcess::Msg_UpdateChildScalars(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), actions); // Sentinel = 'actions' ((&(writer__)))->WriteSentinel(193200882); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_UpdateChildScalars", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendUpdateChildKeyedScalars(mozilla::Span actions) -> bool { UniquePtr msg__ = PSocketProcess::Msg_UpdateChildKeyedScalars(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), actions); // Sentinel = 'actions' ((&(writer__)))->WriteSentinel(193200882); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_UpdateChildKeyedScalars", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendRecordChildEvents(mozilla::Span events) -> bool { UniquePtr msg__ = PSocketProcess::Msg_RecordChildEvents(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), events); // Sentinel = 'events' ((&(writer__)))->WriteSentinel(149619350); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_RecordChildEvents", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendRecordDiscardedData(const DiscardedData& data) -> bool { UniquePtr msg__ = PSocketProcess::Msg_RecordDiscardedData(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), data); // Sentinel = 'data' ((&(writer__)))->WriteSentinel(67109275); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_RecordDiscardedData", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendPWebrtcTCPSocketConstructor( PWebrtcTCPSocketChild* actor, const mozilla::Maybe& tabId) -> PWebrtcTCPSocketChild* { if (!actor) { NS_WARNING("Cannot bind null PWebrtcTCPSocketChild actor"); return nullptr; } if (!actor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PWebrtcTCPSocketChild actor"); return nullptr; } // Build our constructor message. UniquePtr msg__ = PSocketProcess::Msg_PWebrtcTCPSocketConstructor(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), (actor)->Id()); // Sentinel = 'actorid' ((&(writer__)))->WriteSentinel(193725159); IPC::WriteParam((&(writer__)), tabId); // Sentinel = 'tabId' ((&(writer__)))->WriteSentinel(99156453); // Notify the other side about the newly created actor. This can // fail if our manager has already been destroyed. // // NOTE: If the send call fails due to toplevel channel teardown, // the `IProtocol::ChannelSend` wrapper absorbs the error for us, // so we don't tear down actors unexpectedly. if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PWebrtcTCPSocketConstructor", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); // Warn, destroy the actor, and return null if the message failed to // send. Otherwise, return the successfully created actor reference. if (!sendok__) { NS_WARNING("Error sending PWebrtcTCPSocketChild constructor"); actor->ActorDisconnected(FailedConstructor); return nullptr; } return actor; } auto PSocketProcessChild::SendObserveHttpActivity( const HttpActivityArgs& aActivityArgs, const uint32_t& aActivityType, const uint32_t& aActivitySubtype, const PRTime& aTimestamp, const uint64_t& aExtraSizeData, const nsACString& aExtraStringData) -> bool { UniquePtr msg__ = PSocketProcess::Msg_ObserveHttpActivity(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), aActivityArgs); // Sentinel = 'aActivityArgs' ((&(writer__)))->WriteSentinel(599721276); IPC::WriteParam((&(writer__)), aActivityType); // Sentinel = 'aActivityType' ((&(writer__)))->WriteSentinel(606340433); IPC::WriteParam((&(writer__)), aActivitySubtype); // Sentinel = 'aActivitySubtype' ((&(writer__)))->WriteSentinel(916326043); IPC::WriteParam((&(writer__)), aTimestamp); // Sentinel = 'aTimestamp' ((&(writer__)))->WriteSentinel(367330326); IPC::WriteParam((&(writer__)), aExtraSizeData); // Sentinel = 'aExtraSizeData' ((&(writer__)))->WriteSentinel(689833339); IPC::WriteParam((&(writer__)), aExtraStringData); // Sentinel = 'aExtraStringData' ((&(writer__)))->WriteSentinel(905315927); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_ObserveHttpActivity", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendInitSocketBackground(Endpoint<::mozilla::net::PSocketProcessBackgroundParent>&& aEndpoint) -> bool { UniquePtr msg__ = PSocketProcess::Msg_InitSocketBackground(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), std::move(aEndpoint)); // Sentinel = 'aEndpoint' ((&(writer__)))->WriteSentinel(292225955); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitSocketBackground", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendPAltServiceConstructor(PAltServiceChild* actor) -> PAltServiceChild* { if (!actor) { NS_WARNING("Cannot bind null PAltServiceChild actor"); return nullptr; } if (!actor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PAltServiceChild actor"); return nullptr; } // Build our constructor message. UniquePtr msg__ = PSocketProcess::Msg_PAltServiceConstructor(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), (actor)->Id()); // Sentinel = 'actorid' ((&(writer__)))->WriteSentinel(193725159); // Notify the other side about the newly created actor. This can // fail if our manager has already been destroyed. // // NOTE: If the send call fails due to toplevel channel teardown, // the `IProtocol::ChannelSend` wrapper absorbs the error for us, // so we don't tear down actors unexpectedly. if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PAltServiceConstructor", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); // Warn, destroy the actor, and return null if the message failed to // send. Otherwise, return the successfully created actor reference. if (!sendok__) { NS_WARNING("Error sending PAltServiceChild constructor"); actor->ActorDisconnected(FailedConstructor); return nullptr; } return actor; } auto PSocketProcessChild::SendPProxyConfigLookupConstructor( PProxyConfigLookupChild* actor, nsIURI* aUri, const uint32_t& aFlags, const bool& aIsTRRServiceChannel) -> PProxyConfigLookupChild* { if (!actor) { NS_WARNING("Cannot bind null PProxyConfigLookupChild actor"); return nullptr; } if (!actor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PProxyConfigLookupChild actor"); return nullptr; } // Build our constructor message. UniquePtr msg__ = PSocketProcess::Msg_PProxyConfigLookupConstructor(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), (actor)->Id()); // Sentinel = 'actorid' ((&(writer__)))->WriteSentinel(193725159); IPC::WriteParam((&(writer__)), aUri); // Sentinel = 'aUri' ((&(writer__)))->WriteSentinel(64225682); IPC::WriteParam((&(writer__)), aFlags); // Sentinel = 'aFlags' ((&(writer__)))->WriteSentinel(129892943); IPC::WriteParam((&(writer__)), aIsTRRServiceChannel); // Sentinel = 'aIsTRRServiceChannel' ((&(writer__)))->WriteSentinel(1306462112); // Notify the other side about the newly created actor. This can // fail if our manager has already been destroyed. // // NOTE: If the send call fails due to toplevel channel teardown, // the `IProtocol::ChannelSend` wrapper absorbs the error for us, // so we don't tear down actors unexpectedly. if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PProxyConfigLookupConstructor", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); // Warn, destroy the actor, and return null if the message failed to // send. Otherwise, return the successfully created actor reference. if (!sendok__) { NS_WARNING("Error sending PProxyConfigLookupChild constructor"); actor->ActorDisconnected(FailedConstructor); return nullptr; } return actor; } auto PSocketProcessChild::SendExcludeHttp2OrHttp3(const HttpConnectionInfoCloneArgs& aArgs) -> bool { UniquePtr msg__ = PSocketProcess::Msg_ExcludeHttp2OrHttp3(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), aArgs); // Sentinel = 'aArgs' ((&(writer__)))->WriteSentinel(92602863); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_ExcludeHttp2OrHttp3", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendOnConsoleMessage(const nsAString& aMessage) -> bool { UniquePtr msg__ = PSocketProcess::Msg_OnConsoleMessage(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), aMessage); // Sentinel = 'aMessage' ((&(writer__)))->WriteSentinel(233440039); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_OnConsoleMessage", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendFOGData(ByteBuf&& buf) -> bool { UniquePtr msg__ = PSocketProcess::Msg_FOGData(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), std::move(buf)); // Sentinel = 'buf' ((&(writer__)))->WriteSentinel(41484606); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_FOGData", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendGeckoTraceExport(ByteBuf&& aBuf) -> bool { UniquePtr msg__ = PSocketProcess::Msg_GeckoTraceExport(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), std::move(aBuf)); // Sentinel = 'aBuf' ((&(writer__)))->WriteSentinel(60686719); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GeckoTraceExport", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendSSLTokensCacheData(mozilla::Span aRecords) -> bool { UniquePtr msg__ = PSocketProcess::Msg_SSLTokensCacheData(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), aRecords); // Sentinel = 'aRecords' ((&(writer__)))->WriteSentinel(233308980); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_SSLTokensCacheData", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); return sendok__; } auto PSocketProcessChild::SendPDNSRequestConstructor( PDNSRequestChild* actor, const nsACString& hostName, const nsACString& trrServer, const int32_t& port, const uint16_t& type, const OriginAttributes& originAttributes, const DNSFlags& flags) -> PDNSRequestChild* { if (!actor) { NS_WARNING("Cannot bind null PDNSRequestChild actor"); return nullptr; } if (!actor->SetManagerAndRegister(this)) { NS_WARNING("Failed to bind PDNSRequestChild actor"); return nullptr; } // Build our constructor message. UniquePtr msg__ = PSocketProcess::Msg_PDNSRequestConstructor(MSG_ROUTING_CONTROL); IPC::MessageWriter writer__{ (*(msg__)), this}; IPC::WriteParam((&(writer__)), (actor)->Id()); // Sentinel = 'actorid' ((&(writer__)))->WriteSentinel(193725159); IPC::WriteParam((&(writer__)), hostName); // Sentinel = 'hostName' ((&(writer__)))->WriteSentinel(249627456); IPC::WriteParam((&(writer__)), trrServer); // Sentinel = 'trrServer' ((&(writer__)))->WriteSentinel(320603088); IPC::WriteParam((&(writer__)), port); // Sentinel = 'port' ((&(writer__)))->WriteSentinel(73990598); IPC::WriteParam((&(writer__)), type); // Sentinel = 'type' ((&(writer__)))->WriteSentinel(75760067); IPC::WriteParam((&(writer__)), originAttributes); // Sentinel = 'originAttributes' ((&(writer__)))->WriteSentinel(947259056); IPC::WriteParam((&(writer__)), flags); // Sentinel = 'flags' ((&(writer__)))->WriteSentinel(102171150); // Notify the other side about the newly created actor. This can // fail if our manager has already been destroyed. // // NOTE: If the send call fails due to toplevel channel teardown, // the `IProtocol::ChannelSend` wrapper absorbs the error for us, // so we don't tear down actors unexpectedly. if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending ", msg__->type(), mozilla::ipc::MessageDirection::eSending); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PDNSRequestConstructor", OTHER); bool sendok__ = ChannelSend(std::move(msg__)); // Warn, destroy the actor, and return null if the message failed to // send. Otherwise, return the successfully created actor reference. if (!sendok__) { NS_WARNING("Error sending PDNSRequestChild constructor"); actor->ActorDisconnected(FailedConstructor); return nullptr; } return actor; } auto PSocketProcessChild::DeallocManagee( mozilla::ipc::ProtocolId aProtocolId, IProtocol* aListener) -> void { switch (aProtocolId) { default: FatalError("unreached"); return; } } auto PSocketProcessChild::OnMessageReceived(const Message& msg__) -> PSocketProcessChild::Result { if (!CanSend()) { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Ignored message for dead actor", (&(msg__))->type(), mozilla::ipc::MessageDirection::eSending); } return MsgProcessed; } IPC::Message::routeid_t route__ = msg__.routing_id(); if (MSG_ROUTING_CONTROL != route__) { IProtocol* routed__ = Lookup(route__); if (!routed__ || !routed__->GetLifecycleProxy()) { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Ignored message for dead actor", (&(msg__))->type(), mozilla::ipc::MessageDirection::eSending); } return MsgProcessed; } RefPtr proxy__ = routed__->GetLifecycleProxy(); return proxy__->Get()->OnMessageReceived(msg__); } switch (msg__.type()) { case PSocketProcess::Reply_PWebrtcTCPSocketConstructor__ID: { return MsgProcessed; } case PSocketProcess::Reply_PAltServiceConstructor__ID: { return MsgProcessed; } case PSocketProcess::Reply_PProxyConfigLookupConstructor__ID: { return MsgProcessed; } case PSocketProcess::Msg_Init__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_Init", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aAttributes = IPC::ReadParam((&(reader__))); if (!maybe__aAttributes) { FatalError("Error deserializing 'SocketProcessInitAttributes'"); return MsgValueError; } auto& aAttributes = *maybe__aAttributes; // Sentinel = 'aAttributes' if ((!(((&(reader__)))->ReadSentinel(442434697)))) { mozilla::ipc::SentinelReadError("Error deserializing 'SocketProcessInitAttributes'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvInit(std::move(aAttributes)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PreferenceUpdate__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PreferenceUpdate", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__pref = IPC::ReadParam((&(reader__))); if (!maybe__pref) { FatalError("Error deserializing 'Pref'"); return MsgValueError; } auto& pref = *maybe__pref; // Sentinel = 'pref' if ((!(((&(reader__)))->ReadSentinel(71958958)))) { mozilla::ipc::SentinelReadError("Error deserializing 'Pref'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPreferenceUpdate(std::move(pref)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_RequestMemoryReport__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_RequestMemoryReport", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__generation = IPC::ReadParam((&(reader__))); if (!maybe__generation) { FatalError("Error deserializing 'uint32_t'"); return MsgValueError; } auto& generation = *maybe__generation; // Sentinel = 'generation' if ((!(((&(reader__)))->ReadSentinel(381158445)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint32_t'"); return MsgValueError; } auto maybe__anonymize = IPC::ReadParam((&(reader__))); if (!maybe__anonymize) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& anonymize = *maybe__anonymize; // Sentinel = 'anonymize' if ((!(((&(reader__)))->ReadSentinel(321127387)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } auto maybe__minimizeMemoryUsage = IPC::ReadParam((&(reader__))); if (!maybe__minimizeMemoryUsage) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& minimizeMemoryUsage = *maybe__minimizeMemoryUsage; // Sentinel = 'minimizeMemoryUsage' if ((!(((&(reader__)))->ReadSentinel(1321600977)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } auto maybe__DMDFile = IPC::ReadParam>((&(reader__))); if (!maybe__DMDFile) { FatalError("Error deserializing 'FileDescriptor?'"); return MsgValueError; } auto& DMDFile = *maybe__DMDFile; // Sentinel = 'DMDFile' if ((!(((&(reader__)))->ReadSentinel(143983190)))) { mozilla::ipc::SentinelReadError("Error deserializing 'FileDescriptor?'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_RequestMemoryReport(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); RequestMemoryReportResolver resolver = [resolver__ = std::move(resolver__)](const uint32_t& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'aGeneration' ((&(writer__)))->WriteSentinel(430179438); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvRequestMemoryReport(std::move(generation), std::move(anonymize), std::move(minimizeMemoryUsage), std::move(DMDFile), std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_SetOffline__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_SetOffline", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__offline = IPC::ReadParam((&(reader__))); if (!maybe__offline) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& offline = *maybe__offline; // Sentinel = 'offline' if ((!(((&(reader__)))->ReadSentinel(194904804)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvSetOffline(std::move(offline)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_SetConnectivity__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_SetConnectivity", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__connectivity = IPC::ReadParam((&(reader__))); if (!maybe__connectivity) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& connectivity = *maybe__connectivity; // Sentinel = 'connectivity' if ((!(((&(reader__)))->ReadSentinel(548734240)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvSetConnectivity(std::move(connectivity)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_InitLinuxSandbox__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitLinuxSandbox", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__sandboxBroker = IPC::ReadParam>((&(reader__))); if (!maybe__sandboxBroker) { FatalError("Error deserializing 'FileDescriptor?'"); return MsgValueError; } auto& sandboxBroker = *maybe__sandboxBroker; // Sentinel = 'sandboxBroker' if ((!(((&(reader__)))->ReadSentinel(625149269)))) { mozilla::ipc::SentinelReadError("Error deserializing 'FileDescriptor?'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvInitLinuxSandbox(std::move(sandboxBroker)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_InitSocketProcessBridgeParent__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitSocketProcessBridgeParent", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__processId = IPC::ReadParam((&(reader__))); if (!maybe__processId) { FatalError("Error deserializing 'ProcessId'"); return MsgValueError; } auto& processId = *maybe__processId; // Sentinel = 'processId' if ((!(((&(reader__)))->ReadSentinel(318243757)))) { mozilla::ipc::SentinelReadError("Error deserializing 'ProcessId'"); return MsgValueError; } auto maybe__endpoint = IPC::ReadParam>((&(reader__))); if (!maybe__endpoint) { FatalError("Error deserializing 'Endpoint<::mozilla::net::PSocketProcessBridgeParent>'"); return MsgValueError; } auto& endpoint = *maybe__endpoint; // Sentinel = 'endpoint' if ((!(((&(reader__)))->ReadSentinel(251724642)))) { mozilla::ipc::SentinelReadError("Error deserializing 'Endpoint<::mozilla::net::PSocketProcessBridgeParent>'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvInitSocketProcessBridgeParent(std::move(processId), std::move(endpoint)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_InitProfiler__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitProfiler", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aEndpoint = IPC::ReadParam>((&(reader__))); if (!maybe__aEndpoint) { FatalError("Error deserializing 'Endpoint<::mozilla::PProfilerChild>'"); return MsgValueError; } auto& aEndpoint = *maybe__aEndpoint; // Sentinel = 'aEndpoint' if ((!(((&(reader__)))->ReadSentinel(292225955)))) { mozilla::ipc::SentinelReadError("Error deserializing 'Endpoint<::mozilla::PProfilerChild>'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvInitProfiler(std::move(aEndpoint)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_SocketProcessTelemetryPing__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_SocketProcessTelemetryPing", OTHER); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvSocketProcessTelemetryPing(); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PHttpTransactionConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PHttpTransactionConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPHttpTransactionChild(); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPHttpTransactionConstructor(actor); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PHttpConnectionMgrConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PHttpConnectionMgrConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__aArgs = IPC::ReadParam((&(reader__))); if (!maybe__aArgs) { FatalError("Error deserializing 'HttpHandlerInitArgs'"); return MsgValueError; } auto& aArgs = *maybe__aArgs; // Sentinel = 'aArgs' if ((!(((&(reader__)))->ReadSentinel(92602863)))) { mozilla::ipc::SentinelReadError("Error deserializing 'HttpHandlerInitArgs'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPHttpConnectionMgrChild(aArgs); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPHttpConnectionMgrConstructor(actor, std::move(aArgs)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_UpdateDeviceModelId__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_UpdateDeviceModelId", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aModelId = IPC::ReadParam((&(reader__))); if (!maybe__aModelId) { FatalError("Error deserializing 'nsCString'"); return MsgValueError; } auto& aModelId = *maybe__aModelId; // Sentinel = 'aModelId' if ((!(((&(reader__)))->ReadSentinel(226951936)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsCString'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvUpdateDeviceModelId(std::move(aModelId)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_OnHttpActivityDistributorActivated__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_OnHttpActivityDistributorActivated", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aIsActivated = IPC::ReadParam((&(reader__))); if (!maybe__aIsActivated) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& aIsActivated = *maybe__aIsActivated; // Sentinel = 'aIsActivated' if ((!(((&(reader__)))->ReadSentinel(496501939)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvOnHttpActivityDistributorActivated(std::move(aIsActivated)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_OnHttpActivityDistributorObserveProxyResponse__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_OnHttpActivityDistributorObserveProxyResponse", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aIsEnabled = IPC::ReadParam((&(reader__))); if (!maybe__aIsEnabled) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& aIsEnabled = *maybe__aIsEnabled; // Sentinel = 'aIsEnabled' if ((!(((&(reader__)))->ReadSentinel(340984777)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvOnHttpActivityDistributorObserveProxyResponse(std::move(aIsEnabled)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_OnHttpActivityDistributorObserveConnection__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_OnHttpActivityDistributorObserveConnection", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aIsEnabled = IPC::ReadParam((&(reader__))); if (!maybe__aIsEnabled) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& aIsEnabled = *maybe__aIsEnabled; // Sentinel = 'aIsEnabled' if ((!(((&(reader__)))->ReadSentinel(340984777)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvOnHttpActivityDistributorObserveConnection(std::move(aIsEnabled)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PInputChannelThrottleQueueConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PInputChannelThrottleQueueConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__meanBytesPerSecond = IPC::ReadParam((&(reader__))); if (!maybe__meanBytesPerSecond) { FatalError("Error deserializing 'uint32_t'"); return MsgValueError; } auto& meanBytesPerSecond = *maybe__meanBytesPerSecond; // Sentinel = 'meanBytesPerSecond' if ((!(((&(reader__)))->ReadSentinel(1142097708)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint32_t'"); return MsgValueError; } auto maybe__maxBytesPerSecond = IPC::ReadParam((&(reader__))); if (!maybe__maxBytesPerSecond) { FatalError("Error deserializing 'uint32_t'"); return MsgValueError; } auto& maxBytesPerSecond = *maybe__maxBytesPerSecond; // Sentinel = 'maxBytesPerSecond' if ((!(((&(reader__)))->ReadSentinel(1032193745)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint32_t'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPInputChannelThrottleQueueChild(meanBytesPerSecond, maxBytesPerSecond); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPInputChannelThrottleQueueConstructor(actor, std::move(meanBytesPerSecond), std::move(maxBytesPerSecond)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PAltSvcTransactionConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PAltSvcTransactionConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__aConnInfo = IPC::ReadParam((&(reader__))); if (!maybe__aConnInfo) { FatalError("Error deserializing 'HttpConnectionInfoCloneArgs'"); return MsgValueError; } auto& aConnInfo = *maybe__aConnInfo; // Sentinel = 'aConnInfo' if ((!(((&(reader__)))->ReadSentinel(284558204)))) { mozilla::ipc::SentinelReadError("Error deserializing 'HttpConnectionInfoCloneArgs'"); return MsgValueError; } auto maybe__aCaps = IPC::ReadParam((&(reader__))); if (!maybe__aCaps) { FatalError("Error deserializing 'uint32_t'"); return MsgValueError; } auto& aCaps = *maybe__aCaps; // Sentinel = 'aCaps' if ((!(((&(reader__)))->ReadSentinel(90964457)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint32_t'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPAltSvcTransactionChild(aConnInfo, aCaps); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPAltSvcTransactionConstructor(actor, std::move(aConnInfo), std::move(aCaps)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_ClearSessionCache__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_ClearSessionCache", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_ClearSessionCache(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); ClearSessionCacheResolver resolver = [resolver__ = std::move(resolver__)](const void_t& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'ok' ((&(writer__)))->WriteSentinel(21692635); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvClearSessionCache(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_ClearPrivateBrowsingSessionCache__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_ClearPrivateBrowsingSessionCache", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_ClearPrivateBrowsingSessionCache(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); ClearPrivateBrowsingSessionCacheResolver resolver = [resolver__ = std::move(resolver__)](const void_t& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'ok' ((&(writer__)))->WriteSentinel(21692635); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvClearPrivateBrowsingSessionCache(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PTRRServiceConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PTRRServiceConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__aCaptiveIsPassed = IPC::ReadParam((&(reader__))); if (!maybe__aCaptiveIsPassed) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& aCaptiveIsPassed = *maybe__aCaptiveIsPassed; // Sentinel = 'aCaptiveIsPassed' if ((!(((&(reader__)))->ReadSentinel(883689034)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } auto maybe__aParentalControlEnabled = IPC::ReadParam((&(reader__))); if (!maybe__aParentalControlEnabled) { FatalError("Error deserializing 'bool'"); return MsgValueError; } auto& aParentalControlEnabled = *maybe__aParentalControlEnabled; // Sentinel = 'aParentalControlEnabled' if ((!(((&(reader__)))->ReadSentinel(1835010341)))) { mozilla::ipc::SentinelReadError("Error deserializing 'bool'"); return MsgValueError; } auto maybe__aDNSSuffixList = IPC::ReadParam>((&(reader__))); if (!maybe__aDNSSuffixList) { FatalError("Error deserializing 'nsCString[]'"); return MsgValueError; } auto& aDNSSuffixList = *maybe__aDNSSuffixList; // Sentinel = 'aDNSSuffixList' if ((!(((&(reader__)))->ReadSentinel(636552536)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsCString[]'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPTRRServiceChild(aCaptiveIsPassed, aParentalControlEnabled, aDNSSuffixList); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPTRRServiceConstructor(actor, std::move(aCaptiveIsPassed), std::move(aParentalControlEnabled), std::move(aDNSSuffixList)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_PNativeDNSResolverOverrideConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PNativeDNSResolverOverrideConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPNativeDNSResolverOverrideChild(); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPNativeDNSResolverOverrideConstructor(actor); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_NotifyObserver__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_NotifyObserver", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aTopic = IPC::ReadParam((&(reader__))); if (!maybe__aTopic) { FatalError("Error deserializing 'nsCString'"); return MsgValueError; } auto& aTopic = *maybe__aTopic; // Sentinel = 'aTopic' if ((!(((&(reader__)))->ReadSentinel(137429601)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsCString'"); return MsgValueError; } auto maybe__aData = IPC::ReadParam((&(reader__))); if (!maybe__aData) { FatalError("Error deserializing 'nsString'"); return MsgValueError; } auto& aData = *maybe__aData; // Sentinel = 'aData' if ((!(((&(reader__)))->ReadSentinel(90571228)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsString'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvNotifyObserver(std::move(aTopic), std::move(aData)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_GetSocketData__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GetSocketData", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_GetSocketData(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); GetSocketDataResolver resolver = [resolver__ = std::move(resolver__)](const SocketDataArgs& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'data' ((&(writer__)))->WriteSentinel(67109275); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvGetSocketData(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_GetDNSCacheEntries__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GetDNSCacheEntries", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_GetDNSCacheEntries(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); GetDNSCacheEntriesResolver resolver = [resolver__ = std::move(resolver__)](mozilla::Span aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'entries' ((&(writer__)))->WriteSentinel(199361275); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvGetDNSCacheEntries(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_GetHttpConnectionData__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GetHttpConnectionData", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_GetHttpConnectionData(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); GetHttpConnectionDataResolver resolver = [resolver__ = std::move(resolver__)](mozilla::Span aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'params' ((&(writer__)))->WriteSentinel(146997893); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvGetHttpConnectionData(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_GetHttp3ConnectionStatsData__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GetHttp3ConnectionStatsData", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_GetHttp3ConnectionStatsData(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); GetHttp3ConnectionStatsDataResolver resolver = [resolver__ = std::move(resolver__)](mozilla::Span aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'params' ((&(writer__)))->WriteSentinel(146997893); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvGetHttp3ConnectionStatsData(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_GetSSLTokensCacheData__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_GetSSLTokensCacheData", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_GetSSLTokensCacheData(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); GetSSLTokensCacheDataResolver resolver = [resolver__ = std::move(resolver__)](mozilla::Span aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'records' ((&(writer__)))->WriteSentinel(197067507); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvGetSSLTokensCacheData(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_InitProxyAutoConfigChild__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_InitProxyAutoConfigChild", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__endpoint = IPC::ReadParam>((&(reader__))); if (!maybe__endpoint) { FatalError("Error deserializing 'Endpoint<::mozilla::net::PProxyAutoConfigChild>'"); return MsgValueError; } auto& endpoint = *maybe__endpoint; // Sentinel = 'endpoint' if ((!(((&(reader__)))->ReadSentinel(251724642)))) { mozilla::ipc::SentinelReadError("Error deserializing 'Endpoint<::mozilla::net::PProxyAutoConfigChild>'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvInitProxyAutoConfigChild(std::move(endpoint)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_RecheckIPConnectivity__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_RecheckIPConnectivity", OTHER); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvRecheckIPConnectivity(); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_RecheckDNS__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_RecheckDNS", OTHER); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvRecheckDNS(); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_FlushFOGData__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_FlushFOGData", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_FlushFOGData(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); FlushFOGDataResolver resolver = [resolver__ = std::move(resolver__)](ByteBuf&& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), std::move(aParam)); // Sentinel = 'buf' ((&(writer__)))->WriteSentinel(41484606); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvFlushFOGData(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_LoadSSLTokensCache__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_LoadSSLTokensCache", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aRecords = IPC::ReadParam>((&(reader__))); if (!maybe__aRecords) { FatalError("Error deserializing 'SSLTokensCacheRecordInfo[]'"); return MsgValueError; } auto& aRecords = *maybe__aRecords; // Sentinel = 'aRecords' if ((!(((&(reader__)))->ReadSentinel(233308980)))) { mozilla::ipc::SentinelReadError("Error deserializing 'SSLTokensCacheRecordInfo[]'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvLoadSSLTokensCache(std::move(aRecords)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_FlushSSLTokensCache__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_FlushSSLTokensCache", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_FlushSSLTokensCache(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); FlushSSLTokensCacheResolver resolver = [resolver__ = std::move(resolver__)](mozilla::Span aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'records' ((&(writer__)))->WriteSentinel(197067507); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvFlushSSLTokensCache(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_TestTriggerMetrics__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_TestTriggerMetrics", OTHER); mozilla::ipc::ActorId id__ = MSG_ROUTING_CONTROL; UniquePtr reply__(PSocketProcess::Reply_TestTriggerMetrics(id__)); reply__->set_seqno(msg__.seqno()); RefPtr resolver__ = new mozilla::ipc::IPDLResolverInner(std::move(reply__), this); TestTriggerMetricsResolver resolver = [resolver__ = std::move(resolver__)](const bool& aParam) { resolver__->Resolve([&] (IPC::Message* reply__, IProtocol* self__) { IPC::MessageWriter writer__(*reply__, self__); IPC::WriteParam((&(writer__)), aParam); // Sentinel = 'unused' ((&(writer__)))->WriteSentinel(155517589); if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", self__->ToplevelProtocol()->OtherPidMaybeInvalid(), "Sending reply ", reply__->type(), mozilla::ipc::MessageDirection::eSending); } }); }; mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvTestTriggerMetrics(std::move(resolver)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_AddNetAddrOverride__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_AddNetAddrOverride", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__aFrom = IPC::ReadParam((&(reader__))); if (!maybe__aFrom) { FatalError("Error deserializing 'NetAddr'"); return MsgValueError; } auto& aFrom = *maybe__aFrom; // Sentinel = 'aFrom' if ((!(((&(reader__)))->ReadSentinel(94568950)))) { mozilla::ipc::SentinelReadError("Error deserializing 'NetAddr'"); return MsgValueError; } auto maybe__aTo = IPC::ReadParam((&(reader__))); if (!maybe__aTo) { FatalError("Error deserializing 'NetAddr'"); return MsgValueError; } auto& aTo = *maybe__aTo; // Sentinel = 'aTo' if ((!(((&(reader__)))->ReadSentinel(37552421)))) { mozilla::ipc::SentinelReadError("Error deserializing 'NetAddr'"); return MsgValueError; } reader__.EndRead(); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvAddNetAddrOverride(std::move(aFrom), std::move(aTo)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Msg_ClearNetAddrOverrides__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_ClearNetAddrOverrides", OTHER); mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvClearNetAddrOverrides(); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } case PSocketProcess::Reply_PDNSRequestConstructor__ID: { return MsgProcessed; } case PSocketProcess::Msg_PDNSRequestConstructor__ID: { if (mozilla::ipc::LoggingEnabledFor("PSocketProcess", mozilla::ipc::ChildSide)) { mozilla::ipc::LogMessageForProtocol( "PSocketProcessChild", this->ToplevelProtocol()->OtherPidMaybeInvalid(), "Received ", (&(msg__))->type(), mozilla::ipc::MessageDirection::eReceiving); } AUTO_PROFILER_LABEL("PSocketProcess::Msg_PDNSRequestConstructor", OTHER); IPC::MessageReader reader__{ msg__, this}; auto maybe__actorid__ = IPC::ReadParam((&(reader__))); if (!maybe__actorid__) { FatalError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto& actorid__ = *maybe__actorid__; // Sentinel = 'actorid' if ((!(((&(reader__)))->ReadSentinel(193725159)))) { mozilla::ipc::SentinelReadError("Error deserializing 'mozilla::ipc::ActorId'"); return MsgValueError; } auto maybe__hostName = IPC::ReadParam((&(reader__))); if (!maybe__hostName) { FatalError("Error deserializing 'nsCString'"); return MsgValueError; } auto& hostName = *maybe__hostName; // Sentinel = 'hostName' if ((!(((&(reader__)))->ReadSentinel(249627456)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsCString'"); return MsgValueError; } auto maybe__trrServer = IPC::ReadParam((&(reader__))); if (!maybe__trrServer) { FatalError("Error deserializing 'nsCString'"); return MsgValueError; } auto& trrServer = *maybe__trrServer; // Sentinel = 'trrServer' if ((!(((&(reader__)))->ReadSentinel(320603088)))) { mozilla::ipc::SentinelReadError("Error deserializing 'nsCString'"); return MsgValueError; } auto maybe__port = IPC::ReadParam((&(reader__))); if (!maybe__port) { FatalError("Error deserializing 'int32_t'"); return MsgValueError; } auto& port = *maybe__port; // Sentinel = 'port' if ((!(((&(reader__)))->ReadSentinel(73990598)))) { mozilla::ipc::SentinelReadError("Error deserializing 'int32_t'"); return MsgValueError; } auto maybe__type = IPC::ReadParam((&(reader__))); if (!maybe__type) { FatalError("Error deserializing 'uint16_t'"); return MsgValueError; } auto& type = *maybe__type; // Sentinel = 'type' if ((!(((&(reader__)))->ReadSentinel(75760067)))) { mozilla::ipc::SentinelReadError("Error deserializing 'uint16_t'"); return MsgValueError; } auto maybe__originAttributes = IPC::ReadParam((&(reader__))); if (!maybe__originAttributes) { FatalError("Error deserializing 'OriginAttributes'"); return MsgValueError; } auto& originAttributes = *maybe__originAttributes; // Sentinel = 'originAttributes' if ((!(((&(reader__)))->ReadSentinel(947259056)))) { mozilla::ipc::SentinelReadError("Error deserializing 'OriginAttributes'"); return MsgValueError; } auto maybe__flags = IPC::ReadParam((&(reader__))); if (!maybe__flags) { FatalError("Error deserializing 'DNSFlags'"); return MsgValueError; } auto& flags = *maybe__flags; // Sentinel = 'flags' if ((!(((&(reader__)))->ReadSentinel(102171150)))) { mozilla::ipc::SentinelReadError("Error deserializing 'DNSFlags'"); return MsgValueError; } reader__.EndRead(); // Ensure the ID which was sent to us is valid, and reserve a spot // in the table for the new actor before we bother to alloc it. if (!ToplevelProtocol()->TryReserve(actorid__)) { NS_WARNING("Failed to reserve ActorId for constructor"); return MsgValueError; } RefPtr actor = (static_cast<::mozilla::net::SocketProcessChild*>(this))->AllocPDNSRequestChild(hostName, trrServer, port, type, originAttributes, flags); if (!actor) { NS_WARNING("Alloc function returned null"); // Clean up the reservation taken above if this fails, to avoid // leaving zombie entries in the map. ToplevelProtocol()->ClearReservation(actorid__); return MsgValueError; } // NOTE: SetManagerAndRegister unconditionally consumes the // reservation taken by TryReserve, so we don't need to clear it on // failure. if (!actor->SetManagerAndRegister(this, actorid__)) { NS_WARNING("Failed to set manager for constructor"); return MsgValueError; } mozilla::ipc::IPCResult __ok = (static_cast<::mozilla::net::SocketProcessChild*>(this))->RecvPDNSRequestConstructor(actor, std::move(hostName), std::move(trrServer), std::move(port), std::move(type), std::move(originAttributes), std::move(flags)); if ((!(__ok))) { mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!"); // Error handled in mozilla::ipc::IPCResult return MsgProcessingError; } return MsgProcessed; } default: return MsgNotKnown; case SHMEM_CREATED_MESSAGE_TYPE: { if (!ShmemCreated(msg__)) { return MsgPayloadError; } return MsgProcessed; } case SHMEM_DESTROYED_MESSAGE_TYPE: { if (!ShmemDestroyed(msg__)) { return MsgPayloadError; } return MsgProcessed; } } } auto PSocketProcessChild::OnMessageReceived( const Message& msg__, UniquePtr& reply__) -> PSocketProcessChild::Result { if (!CanSend()) { return MsgDropped; } IPC::Message::routeid_t route__ = msg__.routing_id(); if (MSG_ROUTING_CONTROL != route__) { IProtocol* routed__ = Lookup(route__); if (!routed__ || !routed__->GetLifecycleProxy()) { return MsgDropped; } RefPtr proxy__ = routed__->GetLifecycleProxy(); return proxy__->Get()->OnMessageReceived(msg__, reply__); } return MsgNotKnown; } } // namespace net } // namespace mozilla