Jump to content
xisto Community
Sign in to follow this  

Set Up You Own Web Server With Php, Mysql, Asp.net, And Ssl How to set up a full feature web server

Recommended Posts

Ok this is a long one so get relaxed.

Note: the software in this tutorial are mutil-platform tool BUT this tutorial is for windows

Well first you need a server. I will be using Abyss Web server that can be downloaded for free.

Run the installer and make sure all components are checked to be installed.
When prompted about startup config you can pick what right for you.
Note: i don't recommend installing it as a Windows service because there is no GUI when it is running as a service

Then run the server if it is not running.
Once a config file has be created it will tell to access console click OK
You should now be at a page asking you for your lang. Click the one you want ^_^

Now you must make a username and password for your server's config page
Then login with the user/pass you set
Now you can look around and change what setting you wish

Note: If you are unsure about a setting click the the yellow Question make next to it's name to see it's use/impact
Note: SSL/TSL will be covered near the end of this
Note: Navgate your self to http://forums.xisto.com/no_longer_exists/ Set Documents Path to a folder that you can find the folder you set will be the root of your site

To test to see if your site is working goto your site's root then create a file called test.txt the put what ever you want in that file
Then point your browser to http://forums.xisto.com/no_longer_exists/
If you don't see the file look back make sure you followed it.


Ok you got a server that can dish up HTML but what about PHP

Well you can download a PHP 5.2.2 install from here


Now you can configure your own php.
Goto where you installed php (C:\Program Files\PHP5)

then open php.ini in your text editor (note pad)

don't worry the first time i saw a php.ini file i was frecked out

I will go over some options that you should change ( make sure that there is no ; in front of it if you change it's value)

output_handler:this will change if content is Gziped if you are going to run a site off of this server change to ob_gzhandler
safe_mode: must be off for most scripts to run
max_execution_time : is the amount of time a script can take to produce some output before it is stopped ( recommended is 32 )
memory_limit : the amount of memory a script can take. ( reommended is 12M )
post_max_size: the amount of POST data that will be handled by PHP ( 1M is alot)
magic_quotes_gpc: turn on if a script needs it ( it is off due to some security issues)

PHP Extensions can be set in php.ini to enable an Extensions delete the ; in front of it. to disable it put a ; in front of it


Note: if you are going to use this web server then i recommend installing Zend Optimizer and ioncube loader

Perl can be found here

MySQL can be downloaded from http://dev.mysql.com/downloads/

GUI tools are highly recommended

I know it is not safe but run MySQL on the root account
I recommend phpmyadmin for MySQL DB creation

For SSL do the folowing

* Open the console. * Select SSL/TLS Certificates.
* Press Add in the Private Keys table.
* Enter a name of your choice for the new key you'll generate. For example, enter console_key in Name.
* Set Action to Generate.
* Set Type to RSA 2048 bit to have the best level of security.
* Press OK.

Abyss Web Server will spend a few seconds to compute the new key. If your computer is slow or overloaded, generating a key could need up to a minute.
Generating a self-signed certificate

* Press Add in the Certificates table.
* Enter a name of your choice for the new certificate which will be generated. For example, enter test_cert in Name.
* Set Private Key to the key you have just generated.
* Set Type to Self-Signed certificate.
* Enter the name of the site in Host Name (Common Name). For example, if your site is to be accessed using https://www.example.com/, enter http://www.example.com/ and not example.com.
* Fill the other fields with your information: These will be included in the self-signed certificate. Note that the 2-letter code of the United Kingdom is GB. For a detailed list of country codes, please refer to the official ISO 3166-1-alpha-2 codes listing.
* Press OK.
* Press OK one more time to leave the SSL/TLS Certificates dialog.

Assigning the certificate to a host
If you are using Abyss Web Server X1

* Press Configure in the Hosts table.
* Select General.
* Set Protocol to HTTPS.
* Set HTTPS Port to 443 (its default value) or to another value if that port is already used by another application.
* Select the certificate you've just generated in Certificate.
* Press OK.
* Press Restart.

If you are using Abyss Web Server X2

You can add a new host which Protocol is HTTPS or HTTP+HTTPS and which Certificate is set to the certificate you have just created.

Alternatively, you can edit an already declared host, change its Protocol from HTTP to HTTPS or HTTP+HTTPS, and choose the certificate you have just created to be used by it.
Testing the SSL-enabled host

Now try accessing your site using http://forums.xisto.com/no_longer_exists/ instead of http://forums.xisto.com/no_longer_exists/.

The browser will open a warning dialog where it asks you to confirm that you really want to access that URL which has a certificate signed by an unknown authority (which is you in that case).

Confirm that you still want to access and your browser will display the site properly. You will also notice that the page is secured (a padlock will be displayed in the status bar or your address bar color will be altered).
Note about the Protocol field

If Protocol is set to HTTPS, the host will only be accessible using http://forums.xisto.com/no_longer_exists/.

If Protocol is set to HTTP+HTTPS, the host will be accessible using both http://forums.xisto.com/no_longer_exists/ and http://forums.xisto.com/no_longer_exists/. HTTP+HTTPS is only available in the professional edition Abyss Web Server X2.
Note about the security of self-signed certificates

A site using a self-signed certificate offers the same security as a site using a certificate signed by a certification authority since the encryption is private key dependent only. But consider that self-signed certificates cannot be trusted by visitors who do not know you. So use them only for tests or for sites which access is limited and which visitors trust you (for example in an Intranet or for a family Web site).

Now to make you sire visable to the world you must open port 80 is using HTTP or port 443 if using HTTPS

Don't forget to unblock/permit in you firewall
Port forwding for you router can be found here

Thanks for reading pls reply.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.