I found the answer, that is I have to put Socket:connect (host, port) before TLSSocket:connect ()
Le jeu. 04 oct. 2012 11:25:25 ICT, Nguyễn Hồng Quân a écrit :
Hello, I want to create c TCP client, with TLS support, based on nixio. From the API reference, I tried this require "nixio" local s = nixio.socket("inet", "stream") local tls = nixio.tls("client") local ssoc = tls:create(s) print "Connect" local c = ssoc:connect() But I don't know how to specify the address this client connect to, because the TLSSocket:connect () function does not accept arguments. What is the right procedure to create TCP client?
-- Regards, Quân Y!IM: ng_hquan_vn GTalk: ng.hong.quan _______________________________________________ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel