我正在使用 ejabberd 和 xmpp 协议。需要向ios发送推送通知。我正在使用ejabberd的 mod_apns 模块。
Creating ssl connection with apns
sendpush() ->
Address = "gateway.sandbox.push.apple.com",
Port = 2195,
Cert = "cert.pem",
Key = "key-noenc.pem",
%Options = [{cacertfile, CaCert}, {certfile, Cert}, {keyfile, Key}, {mode, binary}],
Options = [{certfile, Cert}, {keyfile, Key}, {mode, binary}],
Timeout = 1000,
{ok, Socket} = ssl:connect(Address, Port, Options, Timeout),
我收到错误{选项,{模式,二进制}} 有人可以帮我创建apns ssl的连接。