reSIProcate
SIP stack, Dialog Usage Manager and related libraries
Loading...
Searching...
No Matches
SipXRemoteParticipantDialogSet.hxx
Go to the documentation of this file.
1#if !defined(SipXRemoteParticipantDialogSet_hxx)
2#define SipXRemoteParticipantDialogSet_hxx
3
4#include <map>
5#include <list>
11
14#include "Participant.hxx"
16
17namespace resip
18{
19class DialogUsageManager;
20class SipMessage;
21}
22
23namespace recon
24{
25class ConversationManager;
26class RemoteParticipant;
27class SipXRemoteParticipant;
28class FlowManagerSipXSocket;
29
39{
40public:
44 std::shared_ptr<ConversationProfile> conversationProfile = nullptr);
45
47
49 virtual unsigned int getLocalRTPPort();
50
52
53 virtual void setPeerExpectsSAVPF(bool value) { mPeerExpectsSAVPF = value; }
54 virtual bool peerExpectsSAVPF() { return mPeerExpectsSAVPF; }
55
56 // sipX Media Stuff
57 virtual int getMediaConnectionId() { return mMediaConnectionId; }
58 virtual int getConnectionPortOnBridge();
59 virtual void freeMediaResources();
60
61 void setActiveDestination(const char* address, unsigned short rtpPort, unsigned short rtcpPort);
62 void startDtlsClient(const char* address, unsigned short rtpPort, unsigned short rtcpPort);
63 void setRemoteSDPFingerprint(const resip::Data& hashFunction, const resip::Data& fingerprint);
65
66 // Media Stream Processing
67 virtual void processMediaStreamReadyEvent(std::shared_ptr<MediaStreamReadyEvent::StreamParams> streamParams);
68
70
71 const resip::Data& getLocalSrtpSessionKey() { return mLocalSrtpSessionKey; }
72
73protected:
74 virtual bool isAsyncMediaSetup();
75
76 virtual void fixUpSdp(resip::SdpContents* sdp);
77
78private:
79 unsigned int allocateRTPPort();
80
81 SipXMediaStackAdapter& mSipXMediaStackAdapter;
82 unsigned int mLocalRTPPort;
83 bool mAllocateLocalRTPPortFailed;
84 std::shared_ptr<flowmanager::FlowContext> mFlowContext;
85 bool mPeerExpectsSAVPF;
86
87 // Media Stream stuff
89 flowmanager::MediaStream* mMediaStream;
90 reTurn::StunTuple mRtpTuple;
91 reTurn::StunTuple mRtcpTuple;
92 FlowManagerSipXSocket* mRtpSocket;
93 FlowManagerSipXSocket* mRtcpSocket;
94
95 // Secure Media
96 resip::Data mLocalSrtpSessionKey;
98
99 // sipX media stuff
100 virtual std::shared_ptr<SipXMediaInterface> getMediaInterface();
101 std::shared_ptr<SipXMediaInterface> mMediaInterface;
102 int mMediaConnectionId;
103 int mConnectionPortOnBridge;
104
105 virtual void onMediaStreamReady(const StunTuple& remoteRtpTuple, const StunTuple& remoteRtcpTuple);
106 virtual void onMediaStreamError(unsigned int errorCode);
107};
108
109}
110
111#endif
112
113
114/* ====================================================================
115
116 Copyright (c) 2021-2026, SIP Spectrum, Inc. https://www.sipspectrum.com
117 Copyright (c) 2021, Daniel Pocock https://danielpocock.com
118 Copyright (c) 2007-2008, Plantronics, Inc.
119 All rights reserved.
120
121 Redistribution and use in source and binary forms, with or without
122 modification, are permitted provided that the following conditions are
123 met:
124
125 1. Redistributions of source code must retain the above copyright
126 notice, this list of conditions and the following disclaimer.
127
128 2. Redistributions in binary form must reproduce the above copyright
129 notice, this list of conditions and the following disclaimer in the
130 documentation and/or other materials provided with the distribution.
131
132 3. Neither the name of Plantronics nor the names of its contributors
133 may be used to endorse or promote products derived from this
134 software without specific prior written permission.
135
136 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
137 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
138 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
139 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
140 OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
141 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
142 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
143 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
144 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
145 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
146 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
147
148 ==================================================================== */
This class represents a media stream, that consists of a series of componenets or flows.
This class is one of two main classes of concern to an application using the UserAgent library.
This class is used by Invite DialogSets.
This class is one of two main classes of concern to an application using the UserAgent library.
This class is used by Invite DialogSets.
resip::MediaConstants::SrtpCryptoSuite getSrtpCryptoSuite()
void setRemoteSDPFingerprint(const resip::Data &hashFunction, const resip::Data &fingerprint)
void setActiveDestination(const char *address, unsigned short rtpPort, unsigned short rtcpPort)
virtual resip::AppDialog * createAppDialog(const resip::SipMessage &msg)
bool createSRTPSession(resip::MediaConstants::SrtpCryptoSuite cryptoSuite, const char *remoteKey, size_t remoteKeyLen)
virtual void fixUpSdp(resip::SdpContents *sdp)
virtual void setActiveRemoteParticipantHandle(ParticipantHandle handle)
virtual void processMediaStreamReadyEvent(std::shared_ptr< MediaStreamReadyEvent::StreamParams > streamParams)
void startDtlsClient(const char *address, unsigned short rtpPort, unsigned short rtcpPort)
An alternative to std::string, encapsulates an arbitrary buffer of bytes.
Definition Data.hxx:90
Provides an interface to process and generate SDP bodies (MIME content-type application/sdp).
Represents a SIP message.
unsigned int ParticipantHandle
dcm! – add UnusedChecking(_enum) below;
void list()
Definition userAdmin.cxx:66