Exemplo n.º 1
0
    def _postAuth(self, ras_msg, auth_success):
        GeneralUpdateRas._postAuth(self, ras_msg, auth_success)

        if auth_success:
            try:
                remote_ip = ras_msg.getReplyPacket()["Framed-IP-Address"][0]
                self.ips[ras_msg["port"]] = remote_ip
            except KeyError:
                pass
Exemplo n.º 2
0
    def _postAuth(self,ras_msg, auth_success):
        GeneralUpdateRas._postAuth(self,ras_msg, auth_success)
	
	if ras_msg.hasAttr("h323_pre_authentication") and auth_success:
	    user_attrs = user_main.getUserPool().getUserByCallerID(ras_msg["caller_id"]).getUserAttrs()

	    username = user_attrs["voip_username"] + user_attrs["voip_password"]
	    ras_msg.getReplyPacket()["Cisco-AVPair"]="h323-ivr-in=%s"%username

	    if user_attrs.hasAttr("voip_preferred_language"):
		self.setH323PreferredLanguage(ras_msg.getReplyPacket(), user_attrs["voip_preferred_language"])

	elif ras_msg.hasAttr("h323_authorization") and auth_success:
	    self.__addToAuthH323IDs(ras_msg["h323_conf_id"])