1
1
10101010010001001101001112012-03-02 11:00:24
PHP
1010101001000100110100111, 2012-03-02 11:00:24

Embedded Web Server PHP5.4: How to raise HTTPS?

Built-in Web server appeared in PHP5.4
Very good thing - convenient: you can do without Denver / Apaches.

It starts simply:
php -S 127.0.0.1:80 router.phpfor debugging - what you need!

But, what a bad luck:
I want to raise HTTPS : php -S 127.0.0.1:443 router.phpC:\www>php -S 127.0.0.1:443 router.php
PHP 5.4.0 Development Server started at Fri Mar 02 11:58:59 2012
Listening on 127.0.0.1 :443
Document root is C:\www
Press Ctrl-C to quit.
to start, it starts, but, for any request, it issues:

[Fri Mar 02 11:47:01 2012] 127.0.0.1:51885 Invalid request (Malformed HTTP request)
How to be?
Maybe you need to add some key on the command line?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
I
Ivan, 2012-03-02
@iSage

No way. The built-in server does not support SSL. And why does it need a server designed for development, and not for production?

E
ertaquo, 2012-03-02
@ertaquo

You have just started an HTTP server on a port designated for HTTPS. HTTPS server in 5.4 is not announced.

P
Perkov, 2012-03-02
@Perkov

127.0.0.1:443 works? probably yes. https requires certificates.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question