ios - PJSIP 中本地帐户的用途是什么?

标签 ios account pjsip

我发现有两个本地帐户,ID 为 0(IPv4 地址)和 ID 为 1(IPv6 地址)。因此,当我注册时,该用户帐户使用 id 2 注册。我想知道这些本地帐户的目的是什么。在我注册之前,用户 id 1 被用作默认帐户。
在 PJSIP 中,他们提到了这一点:

At least one account MUST be created in the application, since any outgoing requests require an account context. If no user association is required, the application can create a userless account by calling Account.create(). A userless account identifies a local endpoint instead of a particular user, and it corresponds to a particular transport ID.


Also one account must be set as the default account, which will be used as the account identity when pjsua fails to match an incoming request with any accounts using the stricter matching rules.


当应用程序终止时,账号id 0 的账号被删除,id 2(我们注册的账号)被删除。将来电与无用户帐户匹配的目的是什么?为什么帐号 id 1 没有被删除? PJSIP 如何将请求匹配到无用户帐户?我对这个概念感到困惑。任何线索都会对我有所帮助。提前致谢。

最佳答案

SIP 协议(protocol)允许直接调用指定的 IP。如果您想允许您的应用程序处理定向到您的设备 IP 地址的调用,那么您可以使用本地帐户。在这种情况下,IPv4 的 SIP URI 可以如下所示:sip:192.168.1.100(而不是 sip:someuser@somelocation),您无需在任何地方注册任何用户,即可处理指向此 URI 的调用。

关于ios - PJSIP 中本地帐户的用途是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/62788419/

相关文章:

php - WooCommerce:将自定义模板添加到客户帐户页面

python - 无法将 PJSUA Python 模块与 PulseAudio 一起使用

ios - 单击点注释 iOS 后显示自定义 View

api - 是否可以使用 PayPal API 连接到不同用户的帐户以向他们支付(贷记)资金?

linux - ulimit -r 返回不同的值

带有 CSipSimple 和 pjsip 的安卓 SIP

android - pjsip android 眩晕超时

ios - 从 plist 加载的注释不显示

ios - 在 UIButton 中垂直显示标题?

ios - 我用3D touch在UITableViewl中按下了一个cell,然后提示错误的cell view