"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/h460/h460_std17.cxx" between
h323plus-1_27_0.tar.gz and h323plus-1_27_1.tar.gz

About: H.323 Plus offers libraries for voice (VoIP) and videoconferencing using H.323.

h460_std17.cxx  (h323plus-1_27_0):h460_std17.cxx  (h323plus-1_27_1)
skipping to change at line 94 skipping to change at line 94
static PBoolean FindRoutes(const PString & domain, std::vector<std::pair<LookupR ecord, H323TransportSecurity> > & routes, H323TransportSecurity * sec) static PBoolean FindRoutes(const PString & domain, std::vector<std::pair<LookupR ecord, H323TransportSecurity> > & routes, H323TransportSecurity * sec)
{ {
std::vector<LookupRecord> secureRoute; std::vector<LookupRecord> secureRoute;
std::vector<LookupRecord>::iterator r; std::vector<LookupRecord>::iterator r;
if (sec && sec->IsTLSEnabled()) { if (sec && sec->IsTLSEnabled()) {
H323TransportSecurity tls; H323TransportSecurity tls;
tls.EnableTLS(true); tls.EnableTLS(true);
FindSRVRecords(secureRoute, domain, "_h323rs-sec._tcp."); FindSRVRecords(secureRoute, domain, "_h323rs-sec._tcp.");
for (r = secureRoute.begin(); r != secureRoute.end(); ++r) for (r = secureRoute.begin(); r != secureRoute.end(); ++r)
routes.push_back(std::make_pair(*r,tls)); routes.push_back(std::make_pair(*r, tls));
if (!routes.empty()) if (!routes.empty())
return true; return true;
} }
std::vector<LookupRecord> route; std::vector<LookupRecord> route;
H323TransportSecurity unsecure; H323TransportSecurity unsecure;
FindSRVRecords(route, domain, "_h323rs._tcp."); FindSRVRecords(route, domain, "_h323rs._tcp.");
for (r = route.begin(); r != route.end(); ++r) for (r = route.begin(); r != route.end(); ++r)
routes.push_back(std::make_pair(*r,unsecure)); routes.push_back(std::make_pair(*r,unsecure));
skipping to change at line 157 skipping to change at line 157
PBoolean H460_FeatureStd17::Initialise(const PString & remoteAddr, PBoolean srv) PBoolean H460_FeatureStd17::Initialise(const PString & remoteAddr, PBoolean srv)
{ {
return Initialise(NULL, remoteAddr, srv); return Initialise(NULL, remoteAddr, srv);
} }
PBoolean H460_FeatureStd17::Initialise(H323TransportSecurity * sec, const PStrin g & remoteAddr, PBoolean srv) PBoolean H460_FeatureStd17::Initialise(H323TransportSecurity * sec, const PStrin g & remoteAddr, PBoolean srv)
{ {
if (!srv) { // We are not doing SRV lookup if (!srv) { // We are not doing SRV lookup
H323TransportAddress rem(remoteAddr); H323TransportAddress rem(remoteAddr);
if (!InitialiseTunnel(rem,*sec)) { if (!sec || !InitialiseTunnel(rem, *sec)) {
PTRACE(2,"H46017\tTunnel to " << rem << " Failed!"); PTRACE(2,"H46017\tTunnel to " << rem << " Failed!");
return false; return false;
} }
if (!m_handler) if (!m_handler)
return false; return false;
#ifdef H323_H46018 #ifdef H323_H46018
EP->H46018Enable(false); EP->H46018Enable(false);
#endif #endif
isEnabled = true; isEnabled = true;
return (m_handler->RegisterGatekeeper()); return (m_handler->RegisterGatekeeper());
skipping to change at line 181 skipping to change at line 181
type_routes routes; type_routes routes;
if (!FindRoutes(remoteAddr, routes, sec)) { if (!FindRoutes(remoteAddr, routes, sec)) {
PTRACE(2,"H46017\tNo Gatekeeper registration SRV Records found!"); PTRACE(2,"H46017\tNo Gatekeeper registration SRV Records found!");
return false; return false;
} }
type_routes::const_iterator r; type_routes::const_iterator r;
for (r = routes.begin(); r != routes.end(); ++r) { for (r = routes.begin(); r != routes.end(); ++r) {
const LookupRecord & rec = r->first; const LookupRecord & rec = r->first;
H323TransportAddress rem(rec.addr,rec.port); H323TransportAddress rem(rec.addr ,rec.port);
const H323TransportSecurity & sec = r->second; const H323TransportSecurity & sec = r->second;
if (!InitialiseTunnel(rem,sec)) { if (!InitialiseTunnel(rem, sec)) {
PTRACE(2,"H46017\t" << (sec.IsTLSEnabled() ? "TLS " : "") << "Tunnel to " << rem << " Failed!"); PTRACE(2,"H46017\t" << (sec.IsTLSEnabled() ? "TLS " : "") << "Tunnel to " << rem << " Failed!");
continue; continue;
} }
#ifdef H323_H46018 #ifdef H323_H46018
EP->H46018Enable(false); EP->H46018Enable(false);
#endif #endif
isEnabled = true; isEnabled = true;
if (!m_handler->RegisterGatekeeper()) if (!m_handler->RegisterGatekeeper())
continue; continue;
skipping to change at line 283 skipping to change at line 283
PTRACE(3, "H46017\tTransport Closed"); PTRACE(3, "H46017\tTransport Closed");
} }
//////////////////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////////////////// ///////
H46017Transport::H46017Transport(H323EndPoint & endpoint, H46017Transport::H46017Transport(H323EndPoint & endpoint,
PIPSocket::Address binding, PIPSocket::Address binding,
H46017Handler * feat H46017Handler * feat
) )
: H323TransportTCP(endpoint,binding), : H323TransportTCP(endpoint, binding),
ReadTimeOut(PMaxTimeInterval), ReadTimeOut(PMaxTimeInterval),
Feature(feat), remoteShutDown(false), closeTransport(false), m_signalProces s(NULL) Feature(feat), remoteShutDown(false), closeTransport(false), m_signalProces s(NULL)
#ifdef H323_H46026 #ifdef H323_H46026
,m_h46026tunnel(false), m_socketMgr(NULL), m_socketWrite(NULL) ,m_h46026tunnel(false), m_socketMgr(NULL), m_socketWrite(NULL)
#endif #endif
{ {
} }
H46017Transport::~H46017Transport() H46017Transport::~H46017Transport()
skipping to change at line 419 skipping to change at line 419
for (std::list<PBYTEArray>::iterator r = ras.begin(); r != ras.end(); ++r ) { for (std::list<PBYTEArray>::iterator r = ras.begin(); r != ras.end(); ++r ) {
if (!rasTransport->ReceivedPDU(*r)) if (!rasTransport->ReceivedPDU(*r))
return false; return false;
} }
ras.clear(); ras.clear();
return true; return true;
} }
return false; return false;
} }
// Unfortunately we have to put the signalling messages onto a seperate thread // Unfortunately we have to put the signaling messages onto a separate thread
// as the messages may block for several seconds. // as the messages may block for several seconds.
PBoolean H46017Transport::HandleH46017SignalPDU(H323SignalPDU & pdu) PBoolean H46017Transport::HandleH46017SignalPDU(H323SignalPDU & pdu)
{ {
if (!m_signalProcess) { if (!m_signalProcess) {
m_signalProcess = PThread::Create(PCREATE_NOTIFIER(SignalProcess), 0, m_signalProcess = PThread::Create(PCREATE_NOTIFIER(SignalProcess), 0,
PThread::AutoDeleteThread, PThread::AutoDeleteThread,
PThread::NormalPriority, PThread::NormalPriority,
"h46017signal:%x"); "h46017signal:%x");
} }
signalMutex.Wait(); signalMutex.Wait();
 End of changes. 6 change blocks. 
6 lines changed or deleted 6 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)