JLBN – Setup HTTPS SSL on WAMP

Hypertext Transfer Protocol over Secure Socket Layer or HTTPS is a URI scheme used to indicate a secure HTTP connection. It is syntactically identical to the http:// scheme normally used for accessing resources using HTTP. Using an https: URL indicates that HTTP is to be used, but with a different default TCP port (443) and an additional encryption/authentication layer between the HTTP and TCP. This system was designed by Netscape Communications Corporation to provide authentication and encrypted communication and is widely used on the World Wide Web for security-sensitive communication such as payment transactions and corporate information systems.

In this tutor guide for WAMP, we will show you how to create a self-signed HTTPS SSL certificate; then, how to implement this self-signed certificate into WAMP; then, obtain a FREE Trusted HTTPS SSL Certificate to replace the self-signed one.

[Read more…]

309 thoughts on “JLBN – Setup HTTPS SSL on WAMP

  • August 3, 2010 at 4:38 am
    Permalink

    It’s a wildcard cert, so I’ve tried both the server name (i.e. server.domain.com) and the wildcard name (*.domain.com) but neither work.

    • August 3, 2010 at 5:51 pm
      Permalink

      Steve, did you try only domain.com? And make sure you must have both key and cert πŸ˜‰

  • August 2, 2010 at 6:39 am
    Permalink

    Hi,
    Thanks for the guide – it got me 99% of the way there, and it works fine with a self-signed certificate. However I now have a proper, signed certificate and the Apache service just won’t start. No errors in ssl_error.log, it just fails with “Windows could not start the wampapache on Local Computer. For more information, review the System Event Log. If this is a non-Microsoft service, contact the service vendor, and refer to service-specific error code 1.”

    Nothing is recorded in the event logs

    Any ideas?

    The certificate file reads as valid by Windows.

    • August 2, 2010 at 4:28 pm
      Permalink

      Steve, did you modify the name in httpd-ssl.conf to match the name of your real certificate and also put both key file and crt file in the same location?

  • Pingback: WAMP + HTTPS Β« likeacheese

  • July 29, 2010 at 9:10 pm
    Permalink

    men! I can’t believe it! you are so patient! I don’t even remember how many steps I did! but thanks to you it works!!!
    thanks a lot!

    • July 30, 2010 at 6:41 am
      Permalink

      leito, SSL will work worldwide and you need to setup Access, DNS, and VH; Access for permission to connect to your Wamp PC, DNS to tie domain(s) to your Wamp PC, and VH to host multiple domains/websites and even you have only 1 domain/IP, you should use VH to set it up w/ the site you want to show up first on top and localhost on bottom and others in middle if having more than 1 site

      To setup Access, follow this
      http://blog.jlbn.net/?p=21

      To setup VH, follow this
      http://blog.jlbn.net/?p=23

      To setup DNS, follow this
      http://blog.jlbn.net/?p=28

  • July 5, 2010 at 4:58 am
    Permalink

    Thanks for the most comprehensive and above all perfectly working guide on the topic.

    Thanks a lot.

  • June 30, 2010 at 5:09 pm
    Permalink

    please put all the more instructions on one page. it is annoying to keep clicking “next page”. But good work on the instructions themselves. thanks!!

    • June 30, 2010 at 6:07 pm
      Permalink

      The most common error people have on the guides from other websites is they missed some steps and they dont even know what step they missed; thus, on our guides, people will know for sure that there are only 3 or 4 steps per page so they wont missed it πŸ˜‰

  • June 21, 2010 at 10:53 am
    Permalink

    hello,
    I have the same error like MacroDaveW in the replay 14.
    If someone solved it, please can say me how i can.

    Thank a lot.

    • June 21, 2010 at 4:51 pm
      Permalink

      eldiablodeyare, go to our Downloads webpage to download and install WampSSL then try the guide again

  • May 11, 2010 at 9:53 pm
    Permalink

    Nice guide for WAMP, easy to follow (though I wish there were more instructions per page instead of 4 or whatever).

    Other than that, 5/5 stars from me! πŸ™‚

  • May 7, 2010 at 8:32 pm
    Permalink

    FANTASTIC job here and my utmost in appreciation and thanks! Was working on a training project all night till 11 am the next day for over 2 days straight and you pulled me out with this very detailed, accurate, step-by-step guide to getting SSL running on WAMP. I spent tons of hours and examined/followed what seems like hundreds of Web pages and THIS worked and well!
    Thanks again—quality posts like this can make the difference between success & failure.

  • March 12, 2010 at 12:25 am
    Permalink

    Ah – found it !
    You see I had mounted my Q:\ drive at C:\wamp so as to keep it separate for back-up purposes. This works well under Windows XP, but I suspect not under DOS.

    So when something ( ? PHP interpreter ?) is launched from a command line, the C:/wamp/ folder looks empty, while all the GUIs report it fully set up.

    So I unmounted the Q: drive and copied its contents to the real C:/wamp and away it goes. πŸ™‚

  • March 11, 2010 at 9:53 pm
    Permalink

    I used Shields Up to test my port usage from the WAN side – if Apache Service is running then ports 80 and 443 are open and listening, whereas when Apache is not running, the ports are closed. If something else was using Port 80, the port would still be open.

    I am currently on my fifth clean install and default configuration. The icon is white.

    • March 11, 2010 at 10:35 pm
      Permalink

      Dave Kimble, the icon is white and you still have same issue??? btw, if you have IIS, it always occupies port 80; anyway, can you left click on wamp tray icon and select localhost to show wamp homepage?

  • March 11, 2010 at 7:12 pm
    Permalink

    I see from C:/wamp/wampmanager.tpl that the file starts with <?php so the fact that it doesn't produce a menu when clicked might be due to the same reason .php files aren't processed during serving.

    I also see under [php menu] some parameters referring to "${c_installDir}/${logDir}php_error.log" which presumably evaluates to C:/wamp/logs/php_error.log
    but since the php never gets interpreted, it's not surprising to find that there is no php_error.log

    Is there some way of tracing the success/failure of launching the php interpreter ?

    Dave

  • March 11, 2010 at 7:23 am
    Permalink

    I assume “conflict wamp” means already listening on Port 80 – no problem there. I’m in an administrator account. My hosts file has:
    127.0.0.1 localhost
    127.0.0.1 domain
    so I have removed the second line anyway.
    Still the same problems – the tray icon doesn’t produce a menu when clicked, and no .php files get interpreted.

    Incidently, the last dialog of the install has “run Wampserver now” checked, and that launches wampmanager.exe and immediately the tray icon doesn’t work, that is, it fails straight out of the box.
    Why hasn’t anybody else noticed this ?

    Also there is an error in conf/httpd.conf that causes “the path to the TrafficLog is not found”, even though the file has no TrafficLog line. It does have a CustomLog line with a path error on it, and fixing that gets Apache Service going. But how come there are simple errors like this in the latest download of WampServer2.0i.exe ? Isn’t this stuff tested ?

    I have tried uninstalling, searching for “wamp” and “apache” etc in the Windows Registry, and deleted a few harmless-looking mentions. Result is the same.

    Thanks for persevering with me.

    Dave

    • March 11, 2010 at 7:29 pm
      Permalink

      I assume β€œconflict wamp” means already listening on Port 80 – no problem there. I’m in an administrator account.

      how did you resolve this problem? and what is the color of your wamp tray icon?

  • March 10, 2010 at 7:05 pm
    Permalink

    But performance is not an issue, and all the messages on the BBS need to be secure, not just the logins.

    Anyway the problem for now is that it still won’t handle .php files, whether they are in /www/ or /www/ssl/ . So if I follow your phpBB3 guide, I do Step 1 and instead of getting back a page so I can do Step 2, I get that error message (above). Something is not switching on, and the tray icon is still not showing any menus.

    One thing that puzzles me about your wampssl.zip – the files are dated March/April 2009 and yet you want me to replace wamp’s files like ssleay32.dll with yours, but you don’t know what the wamp version of ssleay32.dll has been updated to do in the meantime. Why wouldn’t wamp’s version of these files be the best ?

    • March 10, 2010 at 9:22 pm
      Permalink

      Dave Kimble, we’ve missed the part that you can’t run php file and if so, your wamp does not run and you need to fix that problem first, so make sure no other program conflict wamp such as iis, skype, zonealarm, firewall/antivirus, nod32, eset, any web related program … and you have to log into your pc as admin with full privilege to run a web server, including this wamp or any other web server

      Also, open file hosts in folder C:\WINDOWS\System32\drivers\etc and delete anything in there and have only this line and nothing else

      127.0.0.1 localhost

      BTW, the SSL versions differ from the Apache versions, especially the versions that can run on Windows/Wamp, so if you can use SSL that comes with wamp, you don’t have to donwload our wampssl πŸ˜‰

  • March 9, 2010 at 11:19 pm
    Permalink

    That fail actually reads:
    Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0

    Fatal error: Unknown: Failed opening required ‘C:/wamp/www/ssl/phpBB3/index.php’ (include_path=’.;C:\php5\pear’) in Unknown on line 0

    • March 10, 2010 at 5:24 pm
      Permalink

      Dave Kimble, you should not put the whole phpbb inside ssl since it will affect your server performance but only need to use SSL for the transactions of the sensitive informations such as credit card numbers, membership accounts… as we mentioned in step 35 in SSL guide πŸ˜‰

      to setup phpBB, follow this
      http://blog.jlbn.net/?p=36

  • March 9, 2010 at 11:15 pm
    Permalink

    It seems pretty tame :
    C:/wamp/logs/apache_error.log
    [Wed Mar 10 13:54:54 2010] [warn] pid file C:/wamp/bin/apache/Apache2.2.11/logs/httpd.pid overwritten — Unclean shutdown of previous Apache run?
    [Wed Mar 10 13:54:54 2010] [notice] Apache/2.2.11 (Win32) mod_ssl/2.2.11 OpenSSL/0.9.8k PHP/5.3.0 configured — resuming normal operations
    [Wed Mar 10 13:54:54 2010] [notice] Server built: Dec 10 2008 00:10:06
    [Wed Mar 10 13:54:54 2010] [notice] Parent: Created child process 844
    [Wed Mar 10 13:54:55 2010] [notice] Child 844: Child process is running
    [Wed Mar 10 13:54:55 2010] [notice] Child 844: Acquired the start mutex.
    [Wed Mar 10 13:54:55 2010] [notice] Child 844: Starting 64 worker threads.
    [Wed Mar 10 13:54:55 2010] [notice] Child 844: Starting thread to listen on port 80.
    [Wed Mar 10 13:54:55 2010] [notice] Child 844: Starting thread to listen on port 443.
    [Wed Mar 10 13:55:32 2010] [error] [client 127.0.0.1] File does not exist: C:/wamp/www/favicon.ico

    It is now serving http://localhost/index.htm out of c:/wamp/www/index.htm OK
    and https://localhost/index.htm out of C:/wamp/www/ssl/index.htm OK
    but https://localhost/phpBB3/index.php (or any .php) logs an HTTP 200 response but “Unknown file/directory” which I assume means the PHP interpreter is not running (?)

  • March 9, 2010 at 4:27 am
    Permalink

    I’m running on Win XP, I’ve downloaded wampssl.zip, and I’ve set the environment variable. Everything goes OK up to step 42, when I click on the icon in the tray. There is a tooltip saying “WAMP5 – All services running – server offline” but the click doesn’t bring up any menus, so I can’t start PHP, and although I can GET a file back (sometimes) but I can’t get any .php to work.

    • March 9, 2010 at 7:16 pm
      Permalink

      Dave Kimble, can you post the last 10 lines of error log in folder wamp/logs?

  • February 21, 2010 at 11:32 am
    Permalink

    After having completed all the steps, I could not get the test to work as indicated in the tutorial.
    So I restarted my Apache 5.2.11 and it would not restart.
    The System Event Log indicated that a syntax error had occurred in the CustomLog command line
    generated by step 39.
    I commented out the new line and uncommented the original line and still got a syntax error from
    the original line.
    After commenting out both original and new lines, the server restarted successfully.
    I checked the Apache docs for any clues to the proper syntax for the CustomLog command.
    The best I could find was that the first “\” before the “%t, should not be there.
    So I deleted this character, saved the file (httpd-ssl.conf) and restarted the server.
    The server restarted the successfully. I find this worrisome.
    If this is indeed a syntax error, why has no-one else reported having experienced the same. (that I can find)
    Can someone enlighten me please?

    • February 22, 2010 at 10:23 pm
      Permalink

      scarabaeus, \ symbol is used to cut a long line into 2 lines so make sure there is nothing, even a blank space, after that symbol

Leave a Reply