[noPoll] pelase help, about tls

Francis Brosnan Blázquez francis en aspl.es
Vie Jun 12 19:29:35 CEST 2015


El vie, 12-06-2015 a las 22:23 +0700, sumin en trus.co.id escribió:

> Hello,



Hello Su Min,


> im learning nopoll for my application, i plan to use websocket in 
> android/ios using ionic framework (html5/js), so i use nopoll for 
> websocket server only. if im not using TLS, the server run well, but if 
> i try use TLS, the connection wont established.


Ok,


> i hope this info have some clue:
> 1. i compare packet between my application and websocket.org using 
> wireshark. i think the difference begins at "client hello", wireshark 
> didnt capture any "client hello" from my application
> 2. im using blocking socket nopoll_conn_set_sock_block(listener_sock, 
> nopoll_true), and later i accept with nopoll_conn_accept(ctx, listener).



Ok, I think the problem, with 99% of probability is that you are using a
certificate
that is not valid (signed by a trusted party like Twathe, Geotrust and
so forth...). That
can explain why you are getting a failure with your server noPoll app
and the server
provided by websocket.org

If this is the case, the only solution is to a) review your client TLS
code to disable 
certificate verification before connecting... or b) have a signed
certificate that is recognized
by your mobile app 

Going a) would work for your dev test, but you'll need b) for
production 


> 1. can i have some sample code about server with TLS?


Sure, see full working examples at the regression test code:

https://dolphin.aspl.es/svn/publico/nopoll/trunk/test/nopoll-regression-client.c
https://dolphin.aspl.es/svn/publico/nopoll/trunk/test/nopoll-regression-listener.c



> 2. how to show some log/error code from nopoll, i read everyone show 
> nopoll log/error, but i cant find one?



See http://www.aspl.es/nopoll/html/group__nopoll__log.html

Alternatively, assuming you are running a noPoll listener app in a linux
or similar
you can use:

>> NOPOLL_DEBUG=1 NOPOLL_DEBUG_COLOR=1 ./your-app

Best Regards,



> thanks in advance
> 
> Regards,
> 
> Su Min
> _______________________________________________
> noPoll mailing list
> noPoll en lists.aspl.es
> http://lists.aspl.es/cgi-bin/mailman/listinfo/nopoll


-- 
Francis Brosnan Blázquez <francis en aspl.es>
ASPL
91 134 14 22 - 91 134 14 45 - 91 116 07 57

AVISO LEGAL
 
En virtud de lo dispuesto en la Ley Orgánica 15/1999, de 13 de
diciembre, de Protección de Datos de Carácter Personal, le informamos de
que sus datos de carácter personal, recogidos de fuentes accesibles al
público o datos que usted nos ha facilitado previamente, proceden de
bases de datos propiedad de Advanced Software Production Line, S.L.
(ASPL).
 
ASPL garantiza que los datos serán tratados con la finalidad de mantener
las oportunas relaciones comerciales o promocionales con usted o la
entidad que usted representa. No obstante, usted puede ejercitar sus
derechos de acceso, rectificación, cancelación y oposición dispuestos en
la mencionada Ley Orgánica, notificándolo por escrito a ASPL -
Protección Datos, C/Antonio Suárez 10 A-102, 28802, Alcalá de Henares
(Madrid).



------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: <http://lists.aspl.es/pipermail/nopoll/attachments/20150612/7ad88c70/attachment.html>


Más información sobre la lista de distribución noPoll