def incoming_media_session(self, session): if session.remote_identity.uri.host not in self.xmpp_manager.domains | self.xmpp_manager.muc_domains: log.msg("Session rejected: From domain is not a local XMPP domain") session.reject(403) return handler = MediaSessionHandler.new_from_sip_session(session) if handler is not None: NotificationCenter().add_observer(self, sender=handler)
def incoming_media_session(self, session): if session.remote_identity.uri.host not in self.xmpp_manager.domains | self.xmpp_manager.muc_domains: log.msg('Session rejected: From domain is not a local XMPP domain') session.reject(403) return handler = MediaSessionHandler.new_from_sip_session(session) if handler is not None: NotificationCenter().add_observer(self, sender=handler)
def _NH_JingleSessionNewIncoming(self, notification): session = notification.sender handler = MediaSessionHandler.new_from_jingle_session(session) if handler is not None: notification.center.add_observer(self, sender=handler)