Secured socket in PHP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
priyank_ldce
Forum Newbie
Posts: 4
Joined: Fri Oct 20, 2006 10:57 am

Secured socket in PHP

Post by priyank_ldce »

Hi, I have some question about SSL and socket functions in PHP. I am new in web development and SSL networking. Actually I was trying to make a PHP MSN client. I am trying to connect with hotmail server to get ticket to login into MSN using socket.
I use function like

Code: Select all

$msnSock = fsockopen("ssl://loginnet.passport.com",443);
. But this function gives me error “no SSL support in this build” even when I am trying to use CURL it gives me error at “Call to undefined function: curl_init()”. What I feel is may be because I don’t have SSL certificate for my server. But I am not sure. Do I need to get SSL certificate? Can I get some help to solve this problem?
Thanks in advance.
User avatar
aaronhall
DevNet Resident
Posts: 1040
Joined: Tue Aug 13, 2002 5:10 pm
Location: Back in Phoenix, missing the microbrews
Contact:

Post by aaronhall »

I think you're maybe thinking of https:// instead of ssl:// -- the curl_init() error indicates that you don't have the curl module installed.
priyank_ldce
Forum Newbie
Posts: 4
Joined: Fri Oct 20, 2006 10:57 am

Post by priyank_ldce »

Thanks for your replay. Actually I want to use this function with same URL "$msnSock = fsockopen("ssl://loginnet.passport.com",443);". Do i need to but SSL certificate for it? because this function gives me error of "no SSL support in this build".
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

Undefined function noticed result from not have the proper extension enabled. As for the other error, you got me on that one.
Post Reply