D3|\||\|!$ wrote, On 2008-03-03 21:57: > Hi All!!! > > I wrote an SSL server similar to selfserv.c
> SSL_ConfigServerSessionIDCache is reinitializing the > Server_Certificate_Nickname string to "", due to which the application > is not able to find out the certificate or the private key in the > database.. Well, the SSL_ConfigServerSessionIDCache in NSS doesn't have any access to the server certificate nickname, and cannot harm it, so this must be a problem unique to your implementation of that function. > I wrote its equivalent client application working similar to the > tstclnt.c > I tested the application with my own compiled selfserv.c > The PR_Connect function in the client is failing with PR_GetError > throwing up error -5934(PR_IN_PROGRESS_ERROR) The API's description of > it is: "Operation is still in progress (probably a non-blocking > connect)" It sounds to me like you are unfamiliar with the operation of non-blocking sockets. I strongly recommend that you get a book that teaches about sockets programming, including non-blocking sockets, and study it. I might suggest Richard Stevens' multi-volume book entitled "Unix network programming". Don't let the word Unix in the title throw you off. Sockets on Windows are essentially the same as on Unix (especially when used through NSPR). I don't know of any book that focused on Windows that is nearly as complete as Stevens' book. > On the other hand, the PR_Accept on the server side is returning > SUCCESS(!!! :-o). So I cannot figure out what has gone wrong with my > application. selfserv uses blocking sockets. > Earlier I had this same code in C and all the stuff was working > properly but now I've converted it into C++ code and there are > problems popping up... An obvious way to find the problem is to step/trace through both implementations of tstclnt, yours and NSS's, and see how and where in the code they differ in behavior. /Nelson _______________________________________________ dev-tech-crypto mailing list dev-tech-crypto@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-tech-crypto